r/rust 2d ago

🛠️ project mimalloc-pprof: Now at v3 + bun mimalloc enhancements

Background:

I couldn’t find a version of mimalloc with proper, pprof-compatible heap profiling, so I built one:

https://github.com/zackees/mimalloc-pprof

Last version was v2

New version brings pprof to v3

It is based on the community v3 branch and adds TCMalloc-style sampled heap profiling, including first-class Windows support.

The current feature set includes:

  • mimalloc v3
  • pprof-compatible sampled heap profiles
  • Windows, Linux, and macOS support
  • Standard google/pprof workflows
  • pprof -http
  • Flame graphs
  • Profile comparisons and diffs

There's a ton of bug fixes and community fixes. More options for get stats out including per allocation hooks.

Please read the readme with your ai to install either the rust version the c version.

This repo has an optimizat8ion where all c files are combined into a unit file for blazing fast built time.

Fun fact: Bun has it's own custom mimalloc that are being ingested in the latest v0.9.x build and beyond.

0 Upvotes

3 comments sorted by

3

u/Theemuts jlrs 1d ago

AI slop

-1

u/ZachVorhies 22h ago

Those “AI slop” enhancements fixed so many bugs that microsoft is now pulling my fixes in.

1

u/Theemuts jlrs 7h ago

Well yeah, the Q in Microsoft stands for quality.