Major changes:
MEMORY_PROFILER_TRACK_CHILD_PROCESSES environment variable (disabled by default)mmap/munmap calls are now gathered by default (you can disable this with MEMORY_PROFILER_GATHER_MAPS)/proc/self/smapsPR_SET_VMA_ANON_NAME (Linux 5.17 or newer; on older kernels this is emulated in user space)__mmap and __munmap are now hooked intoAllocationList::only_alive_atAllocationList::only_from_mapsGraph::start_atGraph::end_atGraph::show_address_spaceGraph::show_rssMapListMapAllocationList::only_not_deallocated_after_at_leastAllocationList::only_not_deallocated_until_at_mostGraph::truncate_untilGraph::extend_untilonly_not_deallocated_in_current_range, only_deallocated_in_current_rangealigned_allocmemalignMajor changes:
MEMORY_PROFILER_GRAB_BACKTRACES_ON_FREE environment variable to turn this offAllocationList::only_matching_deallocation_backtracesAllocationList::only_not_matching_deallocation_backtracesAllocationList::only_position_in_chain_at_leastAllocationList::only_position_in_chain_at_mostAllocationList::only_chain_leakedserver subcommand of the CLI should now use less memory when loading large data filesmalloc_usable_size when called with a NULL argument now matches glibcMajor changes:
MEMORY_PROFILER_BACKTRACE_CACHE_SIZE environment variable knob was replaced with MEMORY_PROFILER_BACKTRACE_CACHE_SIZE_LEVEL_1 and MEMORY_PROFILER_BACKTRACE_CACHE_SIZE_LEVEL_2 to control the size of the per-thread caches and the global cache respectivelyMEMORY_PROFILER_PRECISE_TIMESTAMPS environment variable knob was removed (always gathering precise timestamps is fast enough on amd64)MEMORY_PROFILER_TEMPORARY_ALLOCATION_PENDING_THRESHOLD is now unset, which means that the allocations will be buffered indefinitely until they're either culled or until they'll live long enough to not be eligible for culling (might increase memory usage in certain cases)Graph::show_memory_usageGraph::show_live_allocationsGraph::show_new_allocationsGraph::show_deallocationsAllocationList::only_group_max_total_usage_first_seen_at_leastAllocationList::only_jemallocextract (will unpack all of the files embedded into a given data file)strip subcommand will now not buffer allocations indefinitely when using the --threshold option, which results in a significantly lower memory usage when stripping huge data files from long profiling runsmalloc_usable_size now works properly when compiled with the jemalloc featurereallocarray doesn't segfault anymoreMajor changes:
memory-profiler to bytehoundjemallocator crate only)script subcommandsqueeze subcommand was renamed to stripstrip subcommand to strip away only a subset of temporary allocationsmmap calls are now always gathered in order (if you have enabled their gathering)Major changes:
MEMORY_PROFILER_CULL_TEMPORARY_ALLOCATIONS set to 1.reallocarray.__register_frame.mmap calls are now not gathered by default.Major changes:
perf_event_open is unavailable (e.g. unpatched MIPS64 systems, docker containers, etc.) are now supported.longjmp/setjmp are now partially supported when using shadow stack based unwinding.dlopen are now properly handled.backtrace on certain architectures while using shadow stack based unwinding would crash the program.jemalloc feature to use jemalloc instead of the system allocator.memory_profiler_start and memory_profiler_stop functions exported by libmemory_profiler.so. Those are equivalent to controlling the profiler through signals.Major changes:
MEMORY_PROFILER_DISABLE_BY_DEFAULT the profiler will not initialize itself nor create an output file.MEMORY_PROFILER_REGISTER_SIGUSR1 and MEMORY_PROFILER_REGISTER_SIGUSR2.MEMORY_PROFILER_ENABLE_SERVER environment variable.MEMORY_PROILER_BASE_SERVER_PORT environment variable.MEMORY_PROFILER_OUTPUT now supports an %n placeholder.Major changes:
libstdc++ when a C++ exception is thrown.Major changes:
MEMORY_PROFILER_PRECISE_TIMESTAMPS to 1 at the cost of extra CPU time.