Jump to content
  • Advertisement
Sign in to follow this  
Tape_Worm

[.net] Generation 0 Garbage Collection

This topic is 4836 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I'm working on a DirectX application and I checked into the garbage collector just for kicks and giggles and optimizations... Anyway, I noticed that sometimes (not always) every few seconds there was a Gen0 garbage collection. I know that Gen0 collections are used to rapid & small collections usually, but every few seconds? I checked into the "% Time in GC" percentage and it was steady at 0.00 - 0.02%, but almost always at 0.01%. Only once during each run did it ever promote to Gen1. I also ensured my code wasn't allocating anything during its render loop and ran for various lengths of time. So, is this a normal situation? And if not, any ideas what could be done about it?

Share this post


Link to post
Share on other sites
Advertisement
This is entirely normal. If your interested in cutting down GC in further, then google for "CLR Profiler". It's an app which will tell you lots about how/when your application allocates memory.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!