Memory Layout of C Programs

Memory Layout of C Programs

from apue 7.6. Memory Layout of a C Program

A typical memory representation of C program consists of following sections.

1. Text segment
2. Initialized data segment
    2.1 initialized read-only area
    2.2 initialized read-write area
3. Uninitialized data segment
4. Heap
5. Stack

Read Memory Layout of C Programs for more details. It's compiled from apue 7.6 with more details and examples.

Other references:

<<Advanced Programming in the UNIX Environment>> 7.6. Memory Layout of a C Program

Memory layout of C process (pdf), download

Data segment

[0x03]. Notes on Assembly - Memory from a process' point of view

Structure of a C-Program in Memory | How Heap,Stack,Data and Code segments are stored in memory?

你可能感兴趣的:(layout)