Re: [PATCH 1/2] x86/resctrl, Documentation: Keep mbm_assign_mode "default" on boot

From: Babu Moger

Date: Tue Jul 28 2026 - 13:53:08 EST


Hi Reinette,

On 7/27/26 19:29, Reinette Chatre wrote:
Hi Babu,

On 7/27/26 4:29 PM, Moger, Babu wrote:
I still have to get back to few questions(test details etc..) on this thread. Let me get back to on that later tomorrow.
thanks
Don't bother.

I just installed a distro version of pqos utility and modified resctrl to return "Unavailable"
once in a while on an Intel system.

Below is the output on an idle system that confirms the pqos team's analysis that
it perceives counter wraparound when there is none. This is when I run with something like
"pqos -m all:0-143" to show all counts. When I run with "pqos -m all:[0-143]" to provide an
average I see the number repeatedly jump to the large number and back over time.

That is interesting. I am not able to see "large number issue" on any of the machines. I ran it on three different machines with threads upto 255.

Here is the output from one machine. Ran both "pqos -m all:0-191" and "pqos -m all:[0-191]".


CORE IPC MISSES LLC[KB] MBL[MB/s] MBR[MB/s]
0 0.00 1238k 256.0 69.6 0.1
1 0.00 290k 2528.0 162.6 0.1
2 0.00 284k 512.0 162.1 0.1
3 0.00 291k 2688.0 162.3 0.1
4 0.00 286k 2464.0 161.7 0.1
5 0.00 283k 2784.0 162.5 0.1
6 0.00 287k 2496.0 161.4 0.1
7 0.00 280k 2464.0 161.8 0.1
8 0.00 430k 704.0 140.0 0.1
9 0.00 425k 928.0 143.8 0.1
10 0.00 429k 864.0 143.8 0.1
11 0.00 422k 3808.0 143.8 0.1
12 0.00 431k 2976.0 143.7 0.1
13 0.00 429k 3488.0 143.8 0.0
14 0.00 428k 3168.0 143.7 0.1
15 0.00 427k 544.0 143.9 0.1
16 0.00 440k 768.0 141.1 0.1
17 0.00 432k 1152.0 144.4 0.1
18 0.00 425k 1088.0 144.1 0.1
19 0.00 386k 1504.0 144.7 0.1
20 0.00 389k 768.0 144.6 0.1
21 0.00 429k 1536.0 144.1 0.1
22 0.00 382k 4608.0 144.5 0.1
23 0.00 431k 4992.0 144.3 0.1
24 0.01 872k 2432.0 425.8 0.1
25 0.01 889k 2208.0 432.8 0.1
26 0.01 908k 2144.0 432.6 0.1
27 0.01 902k 2432.0 432.7 0.1
28 0.01 863k 608.0 431.3 0.1
29 0.01 1562k 2368.0 434.1 0.1
30 0.01 903k 2368.0 430.5 0.1
31 0.01 878k 2432.0 431.3 0.1
32 0.01 1578k 4256.0 421.1 0.1
33 0.01 872k 1056.0 424.4 0.1
34 0.01 898k 1088.0 423.8 0.1
35 0.01 875k 3904.0 424.0 0.1
36 0.01 1259k 2336.0 424.0 0.1
37 0.01 869k 896.0 423.6 0.0
38 0.01 842k 576.0 422.8 0.1
39 0.01 1535k 1824.0 424.6 0.1
40 0.01 893k 3552.0 425.9 0.1
41 0.01 859k 3584.0 433.1 0.1
42 0.01 915k 3584.0 432.4 0.1
43 0.01 899k 704.0 432.9 0.1
44 0.01 907k 960.0 431.5 0.1
45 0.01 883k 3392.0 431.8 0.2
46 0.01 867k 1088.0 430.1 0.2
47 0.01 884k 736.0 430.9 0.1
48 0.00 200k 800.0 66.3 0.1
49 0.00 197k 1120.0 67.8 0.1
50 0.00 193k 2560.0 67.5 0.1
51 0.00 195k 3744.0 67.7 0.1
52 0.00 188k 1408.0 67.5 0.1
53 0.00 190k 3616.0 67.5 0.1
54 0.00 188k 2432.0 67.2 0.1
55 0.00 189k 960.0 67.3 0.1
56 0.00 201k 1344.0 65.9 0.1
57 0.00 201k 2464.0 67.4 0.1
58 0.00 194k 1184.0 67.8 0.1
59 0.00 196k 1632.0 68.1 0.1
60 0.00 192k 3776.0 67.6 0.1
61 0.00 191k 2432.0 67.8 0.0
62 0.00 190k 1184.0 67.6 0.1
63 0.00 193k 2752.0 67.7 0.1
64 0.00 204k 1184.0 66.5 0.1
65 0.00 197k 2816.0 68.2 0.0
66 0.00 191k 1824.0 67.9 0.1
67 0.00 193k 2016.0 68.1 0.1
68 0.00 191k 2272.0 67.6 0.1
69 0.00 192k 1568.0 67.9 0.1
70 0.00 190k 640.0 67.4 0.1
71 0.00 198k 1440.0 67.4 0.2
72 0.00 208k 2752.0 67.0 0.1
73 0.00 200k 992.0 68.6 0.1
74 0.00 194k 2848.0 68.1 0.1
75 0.00 194k 1376.0 68.3 0.1
76 0.00 193k 1024.0 67.9 0.0
77 0.00 195k 3424.0 68.2 0.1
78 0.00 197k 3680.0 67.9 0.1
79 0.00 195k 2464.0 67.9 0.1
80 0.00 204k 1696.0 66.8 0.1
81 0.00 205k 1376.0 68.5 0.1
82 0.00 196k 2176.0 68.2 0.0
83 0.00 194k 1536.0 68.5 0.1
84 0.00 195k 2656.0 67.9 0.1
85 0.00 197k 1472.0 68.2 0.1
86 0.00 200k 1600.0 67.6 0.1
87 0.00 194k 2208.0 68.0 0.1
88 0.00 198k 2176.0 66.4 0.1
89 0.00 190k 1856.0 68.0 0.1
90 0.00 192k 2720.0 67.7 0.1
91 0.00 187k 1856.0 67.9 0.1
92 0.00 191k 1440.0 67.5 0.1
93 0.00 187k 1600.0 67.7 0.1
94 0.00 192k 992.0 67.3 0.1
95 0.00 192k 1728.0 67.5 0.1
96 0.51 178k 64.0 8.4 1.8
97 0.00 279k 2752.0 162.5 0.1
98 0.00 288k 544.0 162.1 0.1
99 0.00 284k 2464.0 162.4 0.1
100 0.00 286k 2272.0 161.9 0.1
101 0.00 288k 2464.0 162.6 0.1
102 0.00 289k 2848.0 161.5 0.1
103 0.00 286k 2400.0 161.8 0.1
104 0.00 414k 544.0 143.9 0.1
105 0.00 433k 992.0 143.9 0.1
106 0.00 428k 960.0 143.7 0.1
107 0.00 425k 2560.0 143.9 0.1
108 0.00 414k 2368.0 143.9 0.1
109 0.00 426k 3520.0 143.9 0.1
110 0.00 425k 3648.0 143.8 0.1
111 0.00 424k 640.0 143.9 0.1
112 0.00 420k 736.0 144.4 0.1
113 0.00 432k 1088.0 144.5 0.1
114 0.00 433k 1248.0 144.2 0.1
115 0.00 382k 1600.0 144.8 0.1
116 0.00 378k 1568.0 144.5 0.1
117 0.00 434k 1280.0 144.2 0.1
118 0.00 383k 5344.0 144.3 0.1
119 0.00 433k 2880.0 143.9 0.1
120 0.01 855k 2144.0 430.8 0.1
121 0.01 894k 2048.0 432.1 0.0
122 0.01 916k 2336.0 431.4 0.1
123 0.01 894k 2272.0 432.0 0.1
124 0.01 860k 608.0 430.1 0.1
125 0.01 1549k 2592.0 432.9 0.1
126 0.01 914k 2432.0 429.8 0.2
127 0.01 876k 2368.0 430.2 0.1
128 0.01 1590k 5184.0 426.2 0.1
129 0.01 874k 832.0 424.2 0.1
130 0.01 897k 1056.0 423.7 0.1
131 0.01 869k 3776.0 423.8 0.0
132 0.01 1248k 3136.0 423.6 0.0
133 0.01 868k 1120.0 423.5 0.0
134 0.01 839k 576.0 422.7 0.1
135 0.01 1556k 2336.0 424.7 0.1
136 0.01 877k 3232.0 431.7 0.1
137 0.01 858k 3552.0 432.9 0.1
138 0.01 917k 3360.0 432.4 0.2
139 0.01 899k 832.0 432.9 0.1
140 0.01 904k 992.0 431.4 0.0
141 0.01 885k 3232.0 431.7 0.4
142 0.01 884k 768.0 430.2 0.0
143 0.01 896k 992.0 431.3 0.1
144 0.00 189k 1440.0 67.9 0.1
145 0.00 189k 544.0 68.1 0.1
146 0.00 191k 1824.0 67.6 0.1
147 0.00 189k 2944.0 67.9 0.1
148 0.00 192k 896.0 67.4 0.1
149 0.00 193k 2880.0 67.8 0.1
150 0.00 189k 2944.0 67.4 0.1
151 0.00 192k 832.0 67.5 0.1
152 0.00 190k 1088.0 68.2 0.0
153 0.00 200k 1408.0 68.3 0.1
154 0.00 194k 2016.0 67.9 0.1
155 0.00 192k 1632.0 68.1 0.1
156 0.00 192k 1312.0 67.6 0.1
157 0.00 194k 224.0 68.0 0.1
158 0.00 191k 768.0 67.7 0.1
159 0.00 190k 2560.0 67.8 0.1
160 0.00 184k 1568.0 68.1 0.1
161 0.00 191k 640.0 68.3 0.1
162 0.00 196k 672.0 68.0 0.1
163 0.00 192k 3040.0 68.1 0.1
164 0.00 188k 1344.0 67.8 0.1
165 0.00 195k 1376.0 68.0 0.1
166 0.00 191k 2624.0 67.6 0.1
167 0.00 204k 2208.0 67.3 0.1
168 0.00 190k 2656.0 67.4 0.1
169 0.00 198k 1984.0 68.5 0.1
170 0.00 195k 2048.0 68.0 0.1
171 0.00 199k 1696.0 68.6 0.1
172 0.00 201k 1664.0 67.8 0.1
173 0.00 197k 1696.0 68.2 0.1
174 0.00 194k 2176.0 67.9 0.1
175 0.00 194k 2560.0 68.0 0.1
176 0.00 191k 2304.0 68.8 0.1
177 0.00 195k 1056.0 68.9 0.1
178 0.00 194k 2176.0 68.6 0.1
179 0.00 198k 2112.0 68.7 0.0
180 0.00 196k 1632.0 68.3 0.1
181 0.00 193k 1184.0 68.4 0.1
182 0.00 201k 3040.0 67.6 0.1
183 0.00 186k 1920.0 68.6 0.1
184 0.00 185k 1824.0 68.4 0.1
185 0.00 195k 1152.0 68.4 0.1
186 0.00 191k 2208.0 68.1 0.1
187 0.00 195k 1984.0 68.4 0.1
188 0.00 192k 2496.0 68.0 0.1
189 0.00 194k 1888.0 68.3 0.1
190 0.00 191k 2560.0 67.7 0.1
191 0.00 194k 3392.0 68.0 0.1



CORE IPC MISSES LLC[KB] MBL[MB/s] MBR[MB/s]
0-191 0.72 641k 8832.0 3.6 0.0

CORE IPC MISSES LLC[KB] MBL[MB/s] MBR[MB/s]
0-191 0.72 800k 10496.0 4.0 0.1



In summary I see:
- pqos utility does not support all scenarios of memory bandwidth measurement
on AMD systems without ABMC active. pqos may intermittently report very large
and incorrect bandwidth numbers.
- pqos utility reports 0MB/s when there are unassigned counters on AMD systems
that support ABMC (and it is enabled).

As I mused earlier (https://lore.kernel.org/lkml/119188c4-1127-4155-9a05-dff47e25be85@xxxxxxxxx/),
I do not know (and can thus only speculate) why the issue with "Unavailable" handling has not
been reported before.

I don't know. I cannot reproduce it on my systems.


If you are expecting more pqos usage on AMD systems then users may encounter output like
below more and more until the fix is created and propagated to users. (sidenote: You may
want to participate in the fix since it may involve exposing the text state, including
"Unassigned", to users where currently it is 0.)

Considering this, could you please confirm that you consider default mode the best
choice? After all, "it will make things keep working as it used to", which sometimes
will look something like:

With ABMC enabled the output look something like this all the time.

CORE IPC MISSES LLC[KB] MBL[MB/s] MBR[MB/s]
0 0.00 1259k 288.0 0.0 0.0
1 0.00 240k 3360.0 0.0 0.0
2 0.00 299k 576.0 0.0 0.0
3 0.00 297k 3040.0 0.0 0.0
4 0.00 296k 736.0 0.0 0.0
5 0.00 241k 3328.0 0.0 0.0
6 0.00 302k 928.0 0.0 0.0
7 0.00 298k 3424.0 0.0 0.0
8 0.00 434k 608.0 0.0 0.0
9 0.00 430k 864.0 0.0 0.0
10 0.00 432k 832.0 0.0 0.0
11 0.00 428k 4320.0 0.0 0.0
12 0.00 437k 3232.0 0.0 0.0
13 0.00 394k 1440.0 0.0 0.0
14 0.00 428k 4320.0 0.0 0.0
15 0.00 428k 992.0 0.0 0.0
16 0.00 443k 864.0 0.0 0.0
17 0.00 432k 1280.0 0.0 0.0
18 0.00 438k 1056.0 0.0 0.0
19 0.00 443k 1760.0 0.0 0.0
20 0.00 385k 1248.0 0.0 0.0
21 0.00 394k 5440.0 0.0 0.0
22 0.00 393k 2336.0 0.0 0.0
23 0.00 438k 4320.0 0.0 0.0
24 0.01 927k 480.0 0.0 0.0
25 0.01 937k 800.0 0.0 0.0
26 0.01 909k 2464.0 0.0 0.0
27 0.01 923k 2304.0 0.0 0.0
28 0.01 918k 2400.0 0.0 0.0
29 0.01 1589k 2784.0 0.0 0.0
30 0.01 885k 2432.0 0.0 0.0


I will leave it you maintainers to decide. I believe all the relevant information has been shared at this point. Let me know if you need any more information.
Thanks
Babu