The Backend Engineering Show with Hussein Nasser cover image

The Backend Engineering Show with Hussein Nasser

The Cost of Memory Fragmentation

Jan 29, 2024
The podcast discusses the concept of memory fragmentation and its impact on performance. It explores the structure of DDR RAM and the cost of accessing different rows. The podcast also delves into the use of virtual memory and the challenges of TLB mess. It highlights the cost of memory fragmentation and retrieval and the differences between hard drive and RAM access.
39:07

Podcast summary created with Snipd AI

Quick takeaways

  • External fragmentation occurs when there are gaps in memory that cannot be easily filled due to their scattered nature, while internal fragmentation is the wasted space within an allocated block of memory.
  • Virtual memory, while solving external fragmentation, introduces new challenges as accessing memory that is physically scattered but appears contiguous in virtual memory incurs a cost associated with retrieving non-contiguous memory locations.

Deep dives

Fragmentation: Exploring Different Types

Fragmentation is a complex topic that can refer to several different aspects. One form of fragmentation is desk fragmentation, which was common in the 90s when hard drives required defragmentation. Another form is fragmentation at layer three in IP packets, where a large packet can be split into smaller fragments by a router. However, the focus of this podcast is fragmentation in memory, which is critical in operating systems. The podcast aims to answer questions about what fragmentation in memory is, the differences between external and internal fragmentation, and the cost of reading non-contiguous memory.

Remember Everything You Learn from Podcasts

Save insights instantly, chat with episodes, and build lasting knowledge - all powered by AI.
App store bannerPlay store banner