Garden Concordance & Cross-Stream Query
12 dispatches foundin 18ms across 42 garden notes
Syntax filter:type:tech
TECH NOTE #089Evergreen
14 min read • Revised 3d ago

Zero-Cost Abstractions: Memory Profiling in Rust

Examining telemetry overlays and customized jemalloc hooks to diagnose unexpected memory allocation patterns in bare-metal environments. We isolate stack vs. heap allocation boundaries without runtime overhead.

src/allocator/jemalloc_hook.rsL34-L41
// Hooking runtime stats directly from jemalloc arena
unsafe fn profile_heap_extent() -> Result<ArenaStat, AllocErr> {
    let epoch = jemalloc_ctl::epoch::mib()?;
    epoch.advance()?;
    let allocated = jemalloc_ctl::stats::allocated::mib()?.read()?;
    Ok(ArenaStat { bytes_in_use: allocated })
}
#rust#systems#profiling
Full Blueprint
JOURNAL / FIELD NOTESBudding
8 min read • Munich, Nov 2024

Walking the Isar: What Slow Running Taught Me About Debugging

Clearing working memory during long gravel trail runs along the river. When an architectural dead-end consumes your cache, rhythmic, unhurried motion becomes the most reliable garbage collector.

Monochrome 35mm film photograph of the gravel banks of the river Isar in MunichIsar / 48.135° N
“We rarely run out of CPU power while troubleshooting; we run out of mental paging space.”
#cognition#running#craft
Read Entry