Profiling and containing memory per system

Posted by chadb on Game Development See other posts from Game Development or by chadb
Published on 2012-03-15T01:43:08Z Indexed on 2012/09/02 9:51 UTC
Read the original article Hit count: 201

I have been interesting in profiling and keeping a managed memory pool for each subsystem, so I could get statistic on how much memory was being used in something such as sounds or graphics. However, what is the best design for doing this? I was thinking of using multiple allocators and just using one per subsystem, however, that would result in global variables for my allocators (or so it would seem to me). Another approach I have seen/been suggested is to just overload new and pass in an allocator for a parameter.

I had a similar question over on stackoverflow here with a bounty, however, it seems as if perhaps I was too vague or just there is not enough people with knowledge in the subject.

© Game Development or respective owner

Related posts about c++

Related posts about engine