Our Debug builds burn ~80% of compile time capturing a 6-frame stack trace on every alloc (the leak-checking DebugAllocator, on macOS arm64), this is what's timing out the JSON CLI tests here.
If we set stack_trace_frames = 0, we get:
JsonStringEscapes 57s→3.6s
JsonEncodeRoundTrip 89s+→11s
snapshot tool (minici) 70s→16s
(leaks are still detected)
I propose we add a flag -Ddebug-gpa-traces (default off) to build_options, point every first-party DebugAllocator at it, and when a leak fires in a traceless build we print a hint to rebuild with the flag for alloc-site traces. We can automate this in CI if desired.
agreed!
Great idea
I've started on the implementation by the way, I'm curious for the CI speedup :eyes:
56->45 min on minici ubuntu 24 and 1h16->1h7 on macos :)
PR#10136
nice!
Last updated: Jul 23 2026 at 13:15 UTC