Operating SystemComputer Science & Information Technology

What is Logical (virtual) vs Physical Address Space?

The concept of a logical address space that is bound to a separate physical address space is central to proper memory management.

  • Logical address: Generated by the CPU; also referred to as virtual address.
  • Physical address: Address seen by the memory unit, i.e., the address loaded into MAR (memory address register).

Logical and physical addresses are the same in compile-time and load-time address-binding schemes; logical (virtual) and physical addresses differ in execution-time address-binding scheme.

physical-address-space

WHAT IS MEMORY ALLOCATION TECHNIQUES?

Main memory is divided into a set of non-overlapping memory regions called partitions. Memory can be allocated in contiguous or non-contiguous partitions.

Contiguous Partition

Contiguous Partition categorized into two ways.

  1. Single Partitioning (Single User, Single process)
  2. Multiple Partitioning (Fixed/Static and Variable/Dynamic)

1. Fixed Partitions/Static Partitioning

Memory is divided into fixed-sized partitions (fixed means number of partition are fixed and not size). All partitions either equal (same) size or unequal size partitions. One partition is allocated to each active process in the multiprogramming set.

2. Variable/Dynamic Partitioning

The partitions are created dynamically. When a process arrives, it allocates memory from a hole large enough to accommodate it. Operating system maintains information about allocated partitions and free partitions.

Memory is allocated contiguously to processes until there is no available block of memory large enough.

Leave a Reply

Your email address will not be published. Required fields are marked *