The address space is the range of memory addresses a process can use. It defines the process’s view of memory.
It provides isolation. It is needed to that one process cannot accidentally overwrite another’s memory. It also simplifies programming by giving each process the illusion of contiguous memory.
The idea of address space becomes important when we have multiple programs in memory at the same time. This is clearly crucial to achieve effective multi programming but there needs to be a way to prevent programs interfering with one another.
While this mechanism has to be in the hardware, it is controlled by the operating system.
Address spaces are managed by a page table which acts as a translation map to take the virtual address space and turns into a physical address space. The simple idea of translation gives us quite a bit of protection.
Naive Implementations
Early systems gave processes direct access to physical memory. This caused fragmentation and security issues.
Then, we had basic hardware control built in which bounded the addresses a process can access. Before accessing any location in physical memory, the memory address will be checked to ensure it lands within the bounds. This ensures confinement of memory space.
Improvements
The issue with the basic idea behind address space is that sometimes a process might need more address space that the physical main memory of the computer. This is where the technique of virtual memory comes in.
Virtual memory maps logical addresses to physical memory using page tables. This enables memory protection, swapping, and demand paging.
Beyond Address Space
Connects to paging vs. segmentation, TLBs (Translation Lookaside Buffers), and memory management policies.