How do you track memory allocations ? I have a big legacy code, which doesnt have memory leaks (checked by FastMM), but allocated memory constantly grows during work. How do you track which objects are over-produced and accumulated, or its just memory fragmentation issue.

Comments

  1. If it doesn't leak - it can be one of two:
    1. You are keeping data you no longer need
    2. Fragmentation - but this is rarely a problem, unless you have very large allocations per object, or a truly large number of allocations.

    For our inhouse classes, I have (in debug mode) the option to not only count objects instances per class - I also have shadow list that tracks objects per class - so I can go in and inspect the list of allocated objects if I need it.

    ReplyDelete
  2. Do you use your own "hand-made" class for that purpose or use 3rd party solution ?

    ReplyDelete
  3. Im trying to not reinvent the bycicle :)

    ReplyDelete

Post a Comment