Process Address Space in Operating System (OS)
Process Address Space in OS
Address space is an important concept in the operating system. It is the volume of memory which is allocated for all the potential addresses associated with a computational unit such as a file, a device, a networked computer system, or a server.
Address space may also denote a range of physical or virtual addresses which can be accessed by a processor. These addresses are also reserved for a process. Each address specifies an entity’s location as a unique identifier of single entities. Also, each computer device or the component is assigned an address space which is a part of the address space of the processor.
Components of a Process Address Space
- The total amount of shared memory a system can allocate depends on several factors. The overall space may include sections such as stack space, program size required, memory mapped files, shared libraries, as well as memory allocated from the heap.
- Memory allocation policies and address spaces used by the varied operating systems are complicated. They may also differ from one operating system to another. The figure below gives an overall layout of a generic process address space for a 32-bit operating system.
- Each section in the given address space is dedicated to perform a specific task and is present to perform an explicit task. The most common areas are the Kernel, program and program data, stack value, heap value, and global data including shared libraries, shared memory, or Dynamic Link Libraries.
Learn about swapping here.
- The magnitude of each section in the address space depends on the type and power of the operating system. These sizes also affect the size of allocated segments of the shared memory. In the case of 64-bit operating system, most of the computational limits are theoretical and may change depending on the available hardware.
- Address spaces can be further differentiated as either flat or segmented. In the case of flat address spaces, the addresses are expressed as incremental values which start from zero. In the case of segmented address spaces, the addresses are represented as distinct segments augmented by offsets. Offsets are values that are added to generate secondary addresses.
- These address spaces can be transformed in some systems from one format to another following a process known as Thunking.
- Addresses spaces have also been linked with the IP address spaces. It is said that the developers IPv4 had not initially anticipated the exponential expansion of the internet. For this reason, the IPv4 address spaces were updated with the IPv6 address spaces with higher bandwidth and address storage capacity.
- Memory Management Introduction
- Partition Allocation Method
- Buddy- System Allocator
- Types of Paging
- Mapping Virtual address to Physical Address.
- Virtual Memory
- Demand Paging
- Implementation of Demand paging and page fault
- Page Replacement Algorithms
- Belady’s Anomaly
- Static vs Dynamic Loading
- Static vs Dynamic Linking
- Translational Look Aside Buffer
- Process Address Space
- Difference between Segmentation and Paging