• Shuffle
    Toggle On
    Toggle Off
  • Alphabetize
    Toggle On
    Toggle Off
  • Front First
    Toggle On
    Toggle Off
  • Both Sides
    Toggle On
    Toggle Off
  • Read
    Toggle On
    Toggle Off
Reading...
Front

Card Range To Study

through

image

Play button

image

Play button

image

Progress

1/9

Click to flip

Use LEFT and RIGHT arrow keys to navigate between flashcards;

Use UP and DOWN arrow keys to flip the card;

H to show hint;

A reads text to speech;

9 Cards in this Set

  • Front
  • Back

Memory Allocation Schemes

1. Single-User systems




2. Fixed partitions




3. Dynamic partitions




4. Relocatable dynamic partitions

Single-User Contiguous Scheme

Whole job/program loaded into memory.




Allocated as much contiguous space in memory it needs.




Jobs/programs processed sequentially.




Finite memory, if too large, execution moves to next process. Program may be modified to fit by making it smaller.




Multiprogramming is unsupported.

Fixed Partitions

Contiguous loading of entire program




1. Supports multiprogramming




2. Protects each job's memory space




3. Memory space allocated to jobs based on info. in a table




4. Allocation method: Loaded into first available partition big enough




Small partitions have long turnaround times while large ones waste memory.




Internal fragmentation: less-than-complete use of memory space in a fixed partition. Unused memory space in the partition remains idle.




Partitions allocated to one job at a time.




5. To work well: Alljobs have similar size and memory size is known ahead of time

Dynamic Partitions

1. Memory allocated in one contiguous block. Jobs given memory as needed when loaded for processing.




2. As new jobs enter after the first few, they are allocated space based on first-come, first-served: loaded into first available partition.




3. Free memory between partitions of allocated memory of allocated memory: external fragmentation.




4. Memory requirements less than size of previous jobs.

Free Space Allocation Methods

Best Fit (best use of memory space)


First Fit (faster)




OS maintains list of memory locations, tracking which ones are free or busy.




Combo yields best system performance.

Best-Fit

Free/Busy lists ordered by size (small to large)




Job/Program assigned to smallest memory block it fits.




Least wasted space.

First-Fit

Organized by memory locations:


low to high-order-memory




Job/Program assigned to first memory block it fits.



Deallocation

Release allocated memory space




FP: reset status to free w/ codes


DP: combines free areas of memory




Depending on position of block to be deallocated:




1. UB Isolated from other free blocks


2. UB Between two free blocks


3. UB Adjacent to another free block



Relocatable Dynamic Partitions

Relocates programs.


1. Contiguous


2. Address/reference to address adjusted to account for new location in memory


3. OS flags addresses so they can be adjusted if/when a program is relocated.




Empty blocks compacted to make one large enough for some or all waiting jobs.