Steven Giesel 6/3/2022

The garbage collector in .NET - Part 2: Compacting

Read Original

This technical article details the compacting phase of the .NET Garbage Collector (GC). It explains why the GC compacts memory after deletion to prevent fragmentation, improve CPU cache performance, and avoid OutOfMemoryExceptions. It also covers the Large Object Heap (LOH), the 85KB threshold, and when developers need to consider these low-level details.

The garbage collector in .NET - Part 2: Compacting

Comments

No comments yet

Be the first to share your thoughts!

Browser Extension

Get instant access to AllDevBlogs from your browser

Top of the Week