I'm a bit confused about the differences between these two tools. In BenchmarkDotNet, when I benchmark an application while using the MemoryDiagnoser attribute, it indicates 200mb total was allocated on the managed heap after running.
When I run the same program's .exe through dotMemory, the peak of the graph is only 40mb.
Why is BenchmarkDotNet's "Allocated" column showing 5x what dotMemory's "Total Used" column does, in terms of allocated memory? Which is more accurate if I want to know what the peak memory used at any given time was vs how much memory was allocated in total?
I did not understand the answers in a related post, How to interpret the results from BenchmarkDotNet and dotMemory?
Perhaps BenchmarkDotNet is showing the "total amount allocated", while dotMemory is showing the "total memory being used at any given time"?