reth icon indicating copy to clipboard operation
reth copied to clipboard

perf: minimum of 32 proof workers for parallel state root computation

Open yongkangc opened this issue 1 week ago • 1 comments
trafficstars

Summary

Changes the default worker count calculation to enforce a minimum of 32 workers instead of a maximum.

Before: min(cpu_count * 2, 32) - capped at 32 maximum After: max(cpu_count * 2, 32) - enforced at 32 minimum

Motivation

payload latency seems to have been caused by

  • state root latency increase due to
  • proof calculation increase ->
  • total storage nodes increase (xen)
  • pending multiproof request increase but active workers remaining the same i.e pending multiproof request increase but active workers remaining the same -> more storage nodes but the proofs request are not being processed

That means that we are lacking in workers to process proofs and thats where the bottleneck is image

Previously testing on base, 32 was a point, and anything less could cause regression. So its a good sweet spot.

Expected Impact This would reduce some back pressure when processing proofs especailly for xen.

In the future we will dynamically increase / decrease workers based on available workers.

yongkangc avatar Nov 13 '25 00:11 yongkangc