process address space
- On IA-32 systems with 2^32 = 4GiB, the address space is usually split in 3:1 ratio. The kernel is assied 1GiB, while 3GiB is available to each userspace process.
- The contents of kernel address space are always same regardless of which user process is active.
Layout of the Process Address Space
- text segment: binary code of the code currently running.
- code for dynamic libraries.
- heap where global variables and dynamically generated data are stored.
- stack used to store local variables and to implement function calls.
- Sections with environment variables and command-line arguments.
- Memory mappings that map the contents of files into the virtual address space.
Each process has mm_struct instance that can be accessed by task structure.
Source