Garbage Collector in .NET 3.5

06/12/2009

New GC Modes:
GCSettings.LatencyMode
Batch: ConcurrentGC off
Interactive: Concurrent GC on
LowLatency: stops Gen2 collections when the app can’t tolerate pauses caused by GC collections
New GC.Collect method:
GC.Collect(<generation>,GCCollectionMode)
Forced: equivalent to the old Collect methods, the collection is done at the time of the call
Optimized: leave the GC to decide if a collection is productive
Default: uses the default, right now it is Forced.

Note:

2.0 (GCcon on/off), GC0/1 usually pretty fast. Config file (client single proc – Interactive), All proc’s doing collection at same time – Batch). Now offered thru API or Config file).

GC.Collect – Forced (sync. Collection same as 2.0), Optimized (new) Now is a good time (hint) but GC ultimately decides, Default (in this version it is Forced, but in the future it may be some other default).

Posted in: C# and .NET| Tags: NET New GC Barbage Collector collector gcsettings modes garbage latencymode collect concurrentgc batch

Hot Posts

Latest posts

Tags

Others

Sponsors

asp.net interview questions