File tree Expand file tree Collapse file tree 1 file changed +5
-3
lines changed Expand file tree Collapse file tree 1 file changed +5
-3
lines changed Original file line number Diff line number Diff line change @@ -260,20 +260,22 @@ loop:
260
260
inc %[i0];
261
261
inc %[i1];
262
262
inc %[i2];
263
+ ...
264
+ inc %[i_n];
263
265
cmp %[max], %[i0];
264
266
jb loop;
265
267
``
266
268
with different numbers of inc instructions.
267
269
268
- \Image[https://raw.githubusercontent.com/cirosantilli/media/refs/heads/master/c/inc_loop_asm_n .png]
270
+ \Image[https://raw.githubusercontent.com/cirosantilli/media/refs/heads/master/c/inc_loop_asm_n_manual .png]
269
271
{title=<c/inc_loop_asm_n.sh>{file} results for a few CPUs}
270
272
{description=
271
- Data from multiple CPUs manually collated and plotted manually with \a[c/inc_loop_asm_n_manual.sh].
272
-
273
273
Quite clearly:
274
274
* <AMD 7840U> can run INC on 4 functional units
275
275
* <Intel i7-7820HQ> can run INC on 2 functional units
276
276
and both have low instruction count effects that destroy performance, AMD at 3 and Intel at 3 and 5. TODO it would be cool to understand those better.
277
+
278
+ Data from multiple CPUs manually collated and plotted manually with \a[c/inc_loop_asm_n_manual.sh].
277
279
}
278
280
{height=480}
279
281
You can’t perform that action at this time.
0 commit comments