mirror of
https://github.com/storytold/photocraft.git
synced 2026-10-17 12:49:31 +02:00
memory-stats reads /proc/self/smaps by default on Linux: every sample formats and parses one block per mapping while holding the mmap lock. The benches' RssSampler polls it every 2 ms, so on a profile of bevel_bench --size 4000x3000 the rss-sampler thread was ~22% of all samples (smaps_account 14.7%, smaps_pte_entry 6.3%), contending with the measured threads. Enable the crate's always_use_statm feature: one short read of the kernel's RSS counters, the same number VmRSS reports. The measured code is unchanged; only the harness overhead goes. |
||
|---|---|---|
| .. | ||
| src | ||
| Cargo.toml | ||