How reliable is windows task manager for determining memory usage of programs?

TaskMgr is an extremely crude tool, but it is useful nonetheless. If you have memory leaks in the one megabyte range, then it is probably good enough to tell that you have them. But, eventually, you'll be looking for leaks in the 10 kilobyte and under ranges, and TaskMgr is useless for those.

The TaskMgr is way too crude for this purpose. Especially if you have a lot of dynamic allocations and deallocations which will lead to a highly fragmented heap memory, in which case, it is hard to differentiate between leaks and natural growth of the heap due to fragmentation. You should use win32 API calls to inspect the total amount of memory allocated by your application.

Some years ago, when I used to still have problems with memory leaks (don't have those anymore thanks to RAII), I used to put at the start of the main() a little piece of code that queried for the total amount of memory blocks allocated on the heap, and then query it again at the very end of the main() function, if the two values didn't match, I would report a "memory leak of X bytes" error at that point.

I cant really gove you an answer,but what I can give you is a way to a solution, that is you have to find the anglde that you relate to or peaks your interest. A good paper is one that people get drawn into because it reaches them ln some way.As for me WW11 to me, I think of the holocaust and the effect it had on the survivors, their families and those who stood by and did nothing until it was too late.

Related Questions