Operating Systems Memory Management
Lecture 9 Michael O’Boyle
1
Operating Systems Memory Management Lecture 9 Michael OBoyle 1 - - PowerPoint PPT Presentation
Operating Systems Memory Management Lecture 9 Michael OBoyle 1 Chapter 8: Memory Management Background Logical/Virtual Address Space vs Physical Address Space Swapping Contiguous Memory Allocation Segmentation
1
3
base memory trap to operating system monitor—addressing error address yes yes no no CPU base limit ≥ <
7
8
21
22
2K 6K 8K 12K physical memory
virtual address
base register
no
raise protection fault limit register
yes
23
24
physical memory
virtual address
base register
limit register
raise protection fault
no yes
– Variable-partition sizes for efficiency (sized to a given process’ needs) – Hole – block of available memory; holes of various size are scattered throughout memory – When a process arrives, allocated memory from a hole large enough to accommodate it – Process exiting frees its partition, adjacent free partitions combined – Operating system maintains information about: a) allocated partitions b) free partitions (hole)
28
29
32
33
segment 0 segment 1 segment 2 segment 3 segment 4
physical memory segment #
virtual address
raise protection fault
no yes
base limit segment table
34