CPU scaling benchmark
workers
1 +1 main
iters total
500M
250000000/stream
elapsed
2192.96 ms
total CPU used
4333.05 ms
speedup
1.98×
vs serial
efficiency
99%
of 2× ideal
| stream | spawn ms | spawned@ | work start@ | work end@ | work ms | reap wait ms |
|---|---|---|---|---|---|---|
| 0 (main) | 0 | 2.21 | 2.21 | 2165.86 | 2163.65 | 0 |
| 1 | 2.139 | 2.17 | 20.25 | 2189.65 | 2169.4 | 23.94 |
main
w1
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.