开发者

Which memory profiler will tell me what is collected in each generation?

开发者 https://www.devze.com 2023-03-10 18:06 出处:网络
I\'ve recently become curious about exactly which objects are collected in which generation. It\'s been a while since I last used a profiler, which I think was SciTech. I don\'t recall it showing a br

I've recently become curious about exactly which objects are collected in which generation. It's been a while since I last used a profiler, which I think was SciTech. I don't recall it showing a breakdown of collections sorted by generation number, but I may be wrong.

Before I go and install a whole bunch of profilers, d开发者_如何转开发oes anyone have a recommendation?


JetBrains dotTrace is equally good as ANTS. Just in case You wanted to have more choice.


You can use WinDbg. There's an extension called SOSex (SOSEX) which extends the basic commands provided by the standard SOS.DLL debugger extension.

Specifically, it has a command, !dumpgen, that dumps the contents of the specified generation.

Also, with SOS !FindRoots you can set a breakpoint when the GC is about to collect a generation.


ANTS Performance Profiler 6.2 .NET code profiler: Speed up the performance of your .NET applications


I use ANTS - it's made up of 2 separate profilers, a performance one and a memory one. You'd need to use ANTS Memory Profiler to look at object collection. That definitely lets you examine different generations separately.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号