2 // To do this test well, I think you need to move the int aX = 0...
3 // lines down as far as possible. That way, the lifespan of the variables
4 // is short, and they can go into registers.
10 for (int r
= 0; r
< 50; r
++) {
11 int a0
= 0, b0
= 0, c0
= 0, d0
= 0;
12 int a1
= 0, b1
= 0, c1
= 0, d1
= 0;
13 int a2
= 0, b2
= 0, c2
= 0, d2
= 0;
14 int a3
= 0, b3
= 0, c3
= 0, d3
= 0;
15 int a4
= 0, b4
= 0, c4
= 0, d4
= 0;
19 for (int i
= 0; i
< 400000; i
++) a0
++;
20 for (int i
= 0; i
< 400000; i
++) b0
++;
21 for (int i
= 0; i
< 400000; i
++) c0
++;
22 for (int i
= 0; i
< 400000; i
++) d0
++;
23 x ^
= a0 ^ b0 ^ c0 ^ d0
;
25 for (int i
= 0; i
< 400000; i
++) a1
++;
26 for (int i
= 0; i
< 400000; i
++) b1
++;
27 for (int i
= 0; i
< 400000; i
++) c1
++;
28 for (int i
= 0; i
< 400000; i
++) d1
++;
29 x ^
= a1 ^ b1 ^ c1 ^ d1
;
31 for (int i
= 0; i
< 400000; i
++) a2
++;
32 for (int i
= 0; i
< 400000; i
++) b2
++;
33 for (int i
= 0; i
< 400000; i
++) c2
++;
34 for (int i
= 0; i
< 400000; i
++) d2
++;
35 x ^
= a2 ^ b2 ^ c2 ^ d2
;
37 for (int i
= 0; i
< 400000; i
++) a3
++;
38 for (int i
= 0; i
< 400000; i
++) b3
++;
39 for (int i
= 0; i
< 400000; i
++) c3
++;
40 for (int i
= 0; i
< 400000; i
++) d3
++;
41 x ^
= a3 ^ b3 ^ c3 ^ d3
;
43 for (int i
= 0; i
< 400000; i
++) a4
++;
44 for (int i
= 0; i
< 400000; i
++) b4
++;
45 for (int i
= 0; i
< 400000; i
++) c4
++;
46 for (int i
= 0; i
< 400000; i
++) d4
++;
47 x ^
= a4 ^ b4 ^ c4 ^ d4
;