diff options
| author | Gabriel Schneider <[email protected]> | 2026-09-24 13:12:45 -0300 |
|---|---|---|
| committer | Gabriel Schneider <[email protected]> | 2026-10-01 00:12:14 -0300 |
| commit | c3688203847b66870c83c3c0b4d26c51c58e34c3 (patch) | |
| tree | 82d4684ada6225505c6a03093ca21f1292437e12 /src/config.zig | |
| parent | a4f5e5b8fc5aed894f13ffe2b96cbd9c5a11770d (diff) | |
| download | pardes-c3688203847b66870c83c3c0b4d26c51c58e34c3.tar.gz pardes-c3688203847b66870c83c3c0b4d26c51c58e34c3.zip | |
Check each subsystem's memory under one DebugAllocator, not two
In a Debug build memory.zig put each subsystem allocator (core, frame, lsp,
tree-sitter, image, PDF) under a DebugAllocator of its own, which is what
reports that subsystem's leaks and makes memory.deinit panic on one. Beneath
it, past the fixed buffer, was the allocator the shell passed in: init.gpa,
which std.process.Init already makes a DebugAllocator in Debug. Every block
that spilled out of a fixed buffer was tracked, checked and given stack
traces twice, and in a test both layers sat on std.testing.allocator.
A Debug build now puts the page allocator beneath the subsystem
DebugAllocators, so each allocation passes through exactly one. The shells'
own gpa is still std.process.Init's DebugAllocator for everything else, and
a release build is unchanged: the subsystems sit on the gpa, no
DebugAllocator anywhere.
Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
Diffstat (limited to 'src/config.zig')
0 files changed, 0 insertions, 0 deletions
