Phase 1: Warm Pool Capacity Increase (16 → 12 with matching threshold)

Key Changes:
- Reduced static capacity from 16 to 12 SuperSlabs per class
- Fixed prefill threshold from hardcoded 4 to match capacity (12)
- Updated environment variable clamping to [1,12]
- This allows warm pool to actually utilize its full capacity

Performance:
- Baseline (post-unified-cache-opt): 4.76M ops/s
- After Phase 1: 4.84M ops/s
- Improvement: +1.6% (expected +15-20%)

Note: Actual improvement lower than expected because the warm pool
bottleneck is only part of the overall allocation path. Unified cache
optimization (+14.9%) already addressed much of the registry scan overhead.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
Moe Charm (CI)
2025-12-05 12:16:39 +09:00
parent a04e3ba0e9
commit 141b121e9c
3 changed files with 9 additions and 8 deletions

View File

@ -24,7 +24,7 @@ extern SuperSlab* superslab_refill(int class_idx);
// Prefill budget: How many additional SuperSlabs to load when pool is empty
// - If pool is empty, load PREFILL_BUDGET extra slabs to build working set
// - This avoids repeated registry scans on rapid cache misses
// - Set to 2 to balance between prefill lock overhead and pool depletion
// - Phase 2: Keep at 2 (increasing to 4 caused contention regression -1.5%)
#define WARM_POOL_PREFILL_BUDGET 2
// ============================================================================