Linux Process Memory Management
We’ve all learned that a process’s memory consists of the heap and the stack. But this model is still too abstract — it conceals many operating system details. So here’s a brief rundown of process memory management. Heap Growth libc provides the malloc function for heap memory allocation. Under the hood, it relies on the brk system call. From the kernel’s perspective, the heap is a simple structure. It consists of a fixed heap base (the end symbol) and a movable heap top (called the program break)....