You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
scheduling, workercache: add microbenchmarks for Schedule and Workers #4001
Nothing measures scheduling.Schedule or workercache.Cache.Workers on its own.
The ate.scheduler.assignment.duration histogram wraps Schedule together with the Postgres BindActorToWorker transaction, so millisecond store round-trips hide microsecond changes in scheduler filtering and cache copying.
Proposal
Add Go benchmarks (testing.B with -benchmem) to measure placement CPU and allocations in isolation:
BenchmarkSchedule (cmd/ateapi/internal/scheduling): Times one placement per assignWorkerAttempt call across 100, 1,000, and 10,000 workers on a deterministic gVisor-shaped fleet (64-digit cpu_features, RuntimeOverhead, selectors, and existing allocations) covering five scenarios:
cold-boot
memory-hit
memory-fallback
memory-mixed
pinned
Include TestBenchScenarios to verify each scenario lands on the expected worker type.
BenchmarkWorkers (cmd/ateapi/internal/workercache): Times Cache.Workers() across 100, 1,000, and 10,000 workers separately, so cache copy cost and scheduler filter cost can be read apart.
Activity
shrutiyam-glitch commentedon Nov 23, 2026
cc: Chenyi Wang (@chw120)
scheduling, workercache: add placement benchmarks (agent-substrate#4000)