
Can this be done by doing this, unsigned n = mymap.bucket_count(); float m = mymap.max_load_factor(); if (m > 1.0) { return (n * m) * (sizeof(value_type stored)); } else { return n * (sizeof(value_type stored)); } to get an approimate size? I got this idea from this question's answer - https://stackoverflow.com/questions/25375202/how-to-measure-memory-usage-of-... Thanks! On Fri, Oct 6, 2017 at 3:46 PM, Ram <sourceopen@gmail.com> wrote:
Hi,
I need help in determining the amount of memory used by boost::unordered_multimap and boost::unordered_multimap. We have a large code base and we have some optimizations done using boost::unordered_multimap and boost::unordered_multimap. The speed it really good, but we want to measure the amount of space it is occupying.
Can somebody please help with that?
I would not be able to change to use a custom new/delete.
Thanks