CPU scaling benchmark
workers
8 +1 main
iters total
500M
55555555/stream
elapsed
1164.16 ms
total CPU used
8914.82 ms
speedup
7.66×
vs serial
efficiency
85.1%
of 9× ideal
| stream | spawn ms | spawned@ | work start@ | work end@ | work ms | reap wait ms |
|---|---|---|---|---|---|---|
| 0 (main) | 0 | 18.36 | 18.38 | 1154.47 | 1136.09 | 0 |
| 1 | 2.235 | 2.25 | 19.35 | 1051.73 | 1032.38 | 0.15 |
| 2 | 1.636 | 3.92 | 20.18 | 931.69 | 911.51 | 0.21 |
| 3 | 1.622 | 5.56 | 23.88 | 866.29 | 842.41 | 0.22 |
| 4 | 5.207 | 10.79 | 49.67 | 1161.2 | 1111.53 | 6.85 |
| 5 | 1.869 | 12.68 | 56.58 | 1145.94 | 1089.36 | 0.24 |
| 6 | 1.586 | 14.29 | 46.55 | 1002.6 | 956.05 | 0.27 |
| 7 | 1.599 | 15.9 | 56.64 | 1073.15 | 1016.51 | 0.28 |
| 8 | 2.433 | 18.35 | 62.68 | 881.66 | 818.98 | 0.3 |
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.