I would like to do some simple measurements of allocations. Basically create a collection of size N for various data structures, then measure the number of temporary and persistent allocations.
Ideally I would love to have something like criterion, but for memory. But since that does not seem to exist, something where I can just write a small test program that dumps a CSV for gnuplot would do as well.
There used to be a crate https://crates.io/crates/heapsize that at least allowed you to measure the total size of an object. But it is no longer supported and does not work with the current default allocator in any case.
Any recommendations how to accomplish this in current rust?