Continue with your mobile number
Memory compaction is a process used in memory management to address fragmentation by consolidating free memory spaces into a single, larger contiguous block. Over time, as processes are loaded and unloaded, memory can become fragmented with small free spaces scattered throughout. Compaction reorganizes the memory, moving allocated blocks together and combining the free spaces into a larger chunk. This process helps in efficiently allocating memory to new processes and reduces the likelihood of fragmentation, which can lead to inefficient use of memory and allocation failures. The main goal is to ensure that sufficient contiguous memory is available for processes that require large blocks of memory.