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
Three small bench corrections:
- Decode RSS sampling: `rust_window.finish()` now runs while `target`
and `decoder` are still alive. Previously they sat in an inner block
that dropped them before `finish` took its final on-thread sample —
on sub-poll-interval payloads (small inputs decoding faster than the
250 µs sampler), the background poller can miss the spike entirely
and the post-drop final sample underreports actual decode footprint.
- `FfiMemTracker::current` updates with plain `+=` / `-=` instead of
saturating arithmetic. A single-CCtx measurement bench cannot reach
`usize::MAX` of live state under any realistic libzstd workload; if
the counter ever did over/underflow that's a real bug (alloc/free
imbalance or mis-routed opaque pointer) and a panic surfaces it
instead of silently freezing at the saturation bound.
- Code comments at the FFI-peak read sites document the intentional
asymmetry: the FFI tracker observes ONLY libzstd's customMem
requests, NOT the Rust-owned output/chunk/target buffers the FFI
helpers also allocate. Both sides allocate output via the system
allocator and the metric is the libzstd-internal cost on top, so
wrapping the whole FFI call in an RSS window would inflate the
comparison with bookkeeping the Rust path also pays.
0 commit comments