CPU scaling benchmark
workers
8 +1 main
iters total
500M
55555555/stream
elapsed
1206.64 ms
total CPU used
8970.83 ms
speedup
7.43×
vs serial
efficiency
82.6%
of 9× ideal
| stream | spawn ms | spawned@ | work start@ | work end@ | work ms | reap wait ms |
|---|---|---|---|---|---|---|
| 0 (main) | 0 | 20.97 | 20.99 | 982.6 | 961.61 | 0 |
| 1 | 2.042 | 2.06 | 20.63 | 664.58 | 643.95 | 0.13 |
| 2 | 1.498 | 3.58 | 21.93 | 1203.93 | 1182 | 221.46 |
| 3 | 1.43 | 5.03 | 23.36 | 920.8 | 897.44 | 0.19 |
| 4 | 5.239 | 10.29 | 43.96 | 1033.83 | 989.87 | 51.33 |
| 5 | 1.649 | 11.95 | 57.94 | 1070.63 | 1012.69 | 88.13 |
| 6 | 1.378 | 13.35 | 60.51 | 1157.97 | 1097.46 | 177.88 |
| 7 | 1.381 | 14.74 | 50.62 | 1159.27 | 1108.65 | 180.68 |
| 8 | 6.197 | 20.96 | 46.73 | 1123.89 | 1077.16 | 141.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.