Garbage Collection does not reduce current memory usage - in release mode. Why?

前端 未结 10 990
渐次进展
渐次进展 2020-12-06 14:18

I built a quick program that needed to loop through an enormous log file (a couple of million records) and find various bits and pieces from inside. Because the volume of da

10条回答
  •  误落风尘
    2020-12-06 15:07

    It is possible that your objects are still rooted somehow. You could try using a memory profiler to see if this is the case. I usually recommend SciTech's .NET Memory Profiler to do this but Red-Gate also has a decent memory profiler. Both SciTech and Red-Gate have trial versions available. It is also possible using WinDBG with SOS.

    There is a somewhat out of date list of all profilers here.

提交回复
热议问题