previous
 next 
CS 3733 Operating Systems Notes: Memory Introduction
(change semester)

Logical versus Physical Address Space

Problem:
Terminology:
Memory Introduction 1


Partitions for Memory Management
  1. Fixed Partitions:
    1. Divide up the memory into fixed pieces called partitions (not necessarily equal).
    2. Each partition contains at most one process.
    3. All logical addresses start at 0.
    4. A base register and a limit register are used to relocate and protect.
    5. physical address = logical address + base register (relocation).
    6. MMU checks that physical address is between the base register and the limit register (protection).
    7. When a job is scheduled it is put into a particular partition.
    8. If the job is a lot shorter than its partition, that space is wasted for duration of job (internal fragmentation).
    9. If a partition is too small for any of the current jobs, that partition sits idle (external fragmentation).
    10. If job is larger than any partitions, you are out of luck.
  2. Variable Partitions
    1. Like fixed partitions but:
    2. Partition sizes are determined dynamically to match the current job sizes.
    3. The operating system keeps a table of current partitions.
    4. When a job finishes, it leaves a hole.
    5. Eventually there are holes everywhere which must be consolidated (fixes external fragmentation). This is called compaction.
Memory Introduction 2

Swapping

Swapping refers to temporarily moving a process out of memory to a backing store, usually a disk, and then bringing it back into memory to continue its execution.

Swapping can be used to free up memory for additional procsess.

This takes too much time to be used often.
Next Notes

Back to CS 3733 Notes Table of Contents