- Add SmallLearnerStatsV7 type + API to policy box
- Hook ColdIface refill/retire to collect stats (capacity-based)
- Implement C5 route switching: if C5 ratio < 30%, switch to MID_V3
- Version-based TLS cache invalidation for policy updates
- Evaluation interval: every 100 refills
Tested with c6heavy scenario: C5 ratio=12% triggers V7 → MID_V3 switch
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- Remove per-page stats from hot path (alloc_count, free_count, live_current)
- Add ENV-gated global atomic stats (HAKMEM_V7_HOT_STATS)
- Stats now collected only at retire time (cold path)
- Header write kept at alloc time (freelist overlaps block[0])
A/B Result: -4.3% overhead → ±0% (target: legacy ±2%)
v7 OFF avg: 9.26M ops/s, v7 ON avg: 9.27M ops/s (+0.15%)
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>