CPU scaling benchmark
workers
8 +1 main
iters total
500M
55555555/stream
elapsed
1152.33 ms
total CPU used
9378.16 ms
speedup
8.14×
vs serial
efficiency
90.4%
of 9× ideal
| stream | spawn ms | spawned@ | work start@ | work end@ | work ms | reap wait ms |
|---|---|---|---|---|---|---|
| 0 (main) | 0 | 15.71 | 15.72 | 1053.54 | 1037.82 | 0 |
| 1 | 2.189 | 2.21 | 25.82 | 1127.92 | 1102.1 | 76.29 |
| 2 | 1.682 | 3.91 | 29.46 | 953.01 | 923.55 | 0.12 |
| 3 | 1.651 | 5.58 | 31.34 | 1088.27 | 1056.93 | 40.36 |
| 4 | 1.704 | 7.3 | 36.7 | 1027.55 | 990.85 | 0.17 |
| 5 | 1.599 | 8.92 | 36.78 | 1149.25 | 1112.47 | 95.83 |
| 6 | 1.721 | 10.66 | 37.24 | 1109.07 | 1071.83 | 60.82 |
| 7 | 1.639 | 12.31 | 57.27 | 1079.23 | 1021.96 | 28.71 |
| 8 | 3.361 | 15.69 | 63.61 | 1124.26 | 1060.65 | 70.85 |
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.