Tag

Buddy System

0 views collected around this technical thread.

Deepin Linux
Deepin Linux
Dec 13, 2024 · Fundamentals

Understanding the Linux Kernel Buddy Memory Allocation Algorithm

This article explains the Linux kernel buddy system, detailing its data structures, initialization, allocation and free processes, and discusses its advantages and drawbacks in managing physical memory and reducing fragmentation.

Buddy SystemFree AreaKernel
0 likes · 22 min read
Understanding the Linux Kernel Buddy Memory Allocation Algorithm
OPPO Kernel Craftsman
OPPO Kernel Craftsman
Mar 10, 2023 · Fundamentals

CMA (Contiguous Memory Allocator) Technical Principle Analysis and Source Code Interpretation

Linux’s Contiguous Memory Allocator (CMA) reserves and manages large physical memory blocks for devices by integrating with the Buddy system, using structures like struct cma, bitmap allocation, and APIs such as cma_init_reserved_mem and cma_alloc, while handling page migration, LRU and per‑CPU PCP caches to ensure efficient allocation and release.

Buddy SystemCMAContiguous Memory
0 likes · 15 min read
CMA (Contiguous Memory Allocator) Technical Principle Analysis and Source Code Interpretation
Refining Core Development Skills
Refining Core Development Skills
Jan 25, 2021 · Fundamentals

Understanding Linux Memory Management: Nodes, Zones, Buddy System, and SLAB Allocator

This article explains the Linux kernel memory management hierarchy—including NUMA nodes, memory zones, the buddy system for free pages, and the SLAB allocator—providing command‑line examples, code snippets, and visual diagrams to illustrate how the kernel efficiently allocates and reclaims memory.

Buddy SystemMemory ManagementNUMA
0 likes · 11 min read
Understanding Linux Memory Management: Nodes, Zones, Buddy System, and SLAB Allocator
OPPO Kernel Craftsman
OPPO Kernel Craftsman
Jul 3, 2020 · Fundamentals

Overview of Linux Physical Memory Fragmentation and Management

Linux uses a buddy‑system allocator organized into nodes and zones to manage physical memory, distinguishing internal fragmentation (unused space within allocated blocks) from external fragmentation (insufficient contiguous free blocks), and mitigates the latter through memory compaction, the kcompactd daemon, and various allocation‑policy optimizations.

Buddy SystemMemory CompactionMemory Management
0 likes · 12 min read
Overview of Linux Physical Memory Fragmentation and Management