Operating System (MM) I

Ignore how a memory address is generated by program. Interesting in only the sequence of memory addresses generated by the running program

  • Addressing Binding

    The process must be executed in the memory, so memory manager is needed by every process

    Input Queue: The collection of processes on the disk that is waiting to be brought into memory for execution forms the input queue

    The normal procedure is to select one of the processes in the input-queue and to load that process into memory

    Most system allow a user process to reside in any part of the physical memory. Address may be represented in different ways.

    • Source code: symbolic address
    • Complie: bind these symbolic address to relocatable addresses
    • Linking or Loading: bind these relocatable addresses to absolute address

    Each binding is a mapping from one address space to another

    • Compile Time:

      The literal text contained with address is defined in programming lanuage. The complie know this address. The absolute code can be generated. The code is recompiled when it is changed.

    • Load Time:

      In this step, the address already had been generated by the compiler. This address is called relocatable code. The binding is delayed until load time. The code only need be reloaded to incorporate the change value.

    • Execution Time:

      The binding address must be delayed until run time. Special hardware must be available for this scheme to work

  • Logical Address space vs. Physical Address Space

    The memory can be understaned as address and the space started in this address. The memory’s manipulation is also operating that space.

    Logical-Address Space: an address generated by the CPU
    Physical-Address Space: an address loaded into the memory-address register

    • Compile-time, load-time:

      address-binding methods generate identical logical and physical address.

    • execution-time:

      result in differing logical and physical address. logical address = virtual address

      The set of all logical address generated by a program is a logical-address space.

      The set of all physical address corresponding to these logical address is a physical-address space

    MMU: The run-time mapping from virtual to physical addresses is done by a hardware device called the memory-management unit (MMU)

    The user program never sees the real physical address. The user program supplies logical address; these logical address must be mapped to physical addresses before they are used.