I am trying to find a significant memory leak (15 MB at a time, but I do such allocations in several places). I checked the most obvious places and then used AQTime, but I still canβt pinpoint this. Now I see 2 options:
1) Use SetProcessWorkingSetSize: I tried this, but my process happily continues to work when using more than 150 MB:
DWORD MemorySize = 150*1024*1024; SetProcessWorkingSetSize( GetCurrentProcess(), MemorySize/2, MemorySize*2 );
2) Place a breakpoint when allocating more than 1 MB at a time. How to do this, reload the new operator with "if> 1MB" inside?
source share