CPU scaling benchmark
workers
8 +1 main
iters total
500M
55555555/stream
elapsed
1176.23 ms
total CPU used
8933.43 ms
speedup
7.59×
vs serial
efficiency
84.3%
of 9× ideal
| stream | spawn ms | spawned@ | work start@ | work end@ | work ms | reap wait ms |
|---|---|---|---|---|---|---|
| 0 (main) | 0 | 20.08 | 20.09 | 847.74 | 827.65 | 0 |
| 1 | 2.14 | 2.16 | 21.02 | 1157.69 | 1136.67 | 310.08 |
| 2 | 1.923 | 4.1 | 25.76 | 1043.84 | 1018.08 | 199.21 |
| 3 | 1.817 | 5.94 | 26.32 | 965.68 | 939.36 | 121.04 |
| 4 | 1.745 | 7.7 | 35.99 | 977.76 | 941.77 | 130.12 |
| 5 | 1.621 | 9.34 | 52.78 | 1172.9 | 1120.12 | 325.29 |
| 6 | 1.638 | 11 | 43.63 | 1015.04 | 971.41 | 167.41 |
| 7 | 4.338 | 15.35 | 53.63 | 951.65 | 898.02 | 105.78 |
| 8 | 4.695 | 20.07 | 63.66 | 1144.01 | 1080.35 | 296.41 |
main
w1
w2
w3
w4
w5
w6
w7
w8
fork+handshake
CPU work
parent reap wait
what this measures
Each stream runs a tight integer LCG loop — working set is one CPU register, no memory access,
no shared data. Speedup = sum(stream CPU time) / wall-clock elapsed. Efficiency = speedup / (workers+1).
100% efficiency means perfect linear scaling; less than 100% is the cost of serial fork setup,
reap tail, SMT/core contention.