Introduction to Memory Management

1  Introduction to Memory Management

1.1  What is Memory & Why Manage It?

1.2  Process Compilation & Memory Locations

Figs/mem_layout.gif

1.3  Bare Machine

Figs/mem_bare.gif

1.4  Operating System in ROM - Resident Monitor

Figs/mem_rom.gif

1.5  Partitions

Figs/mem_partitions.gif

1.6  Allocating & Placing Partitions in Memory

Figs/mem_part_holes.gif

2  Pages

2.1  Problems with Partitions

2.2  Pages

Figs/page_map.gif

2.3  An Example Page Entry

Figs/intel_pentry.gif

2.4  Pages vs. Paging

2.5  Huge Logical Memory Maps

Figs/page_big.gif

2.6  Problems of Paged Memory Management

2.7  Sharing Pages

2.8  Copy-on-Write

Figs/page_cow.gif

2.9  Operating System Use of Page Entry Protections

Memory Area Hardware Protection OS Protection Reason
Page 0 Invalid Invalid Catches NULL pointer use
Code/Constants Read-only Read-only Unchanging memory, may be shared
Global Data Read-write Read-write Normal variable use
Read-only Copy-on-write Allows untouched pages to be shared
The Heap Read-write Read-write Normal variable use
Read-only Copy-on-write Allows untouched pages to be shared
Invalid Invalid Invalid Pages above heap
Memory Mapped Read-only Read-only Read-only file
File Read-write Read-write Read-write file
Read-only Locked region Record locking on file region
Read-only Copy-on-write Allows unaltered sections to be shared
Shared Memory Read-only Read-only Another process has r-w
Region Read-write Read-write Area is shared read-write
Read-only Locked region Record locking on memory region
Read-only Copy-on-write Allows unaltered sections to be shared
Invalid Invalid Fill-on-use Pages below stack
The Stack Read-write Read-write Normal variable use
Read-only Copy-on-write Allows untouched pages to be shared
Shared Libraries Read-only Read-only Unchanging memory, may be shared
OS Code/Constants Kernel read-only Read-only
OS Global Data Kernel read-write Read-write
Invalid Invalid Invalid
OS Stack Kernel read-write Read-write
Device Pages Kernel read-write Read-write



File translated from TEX by TTH, version 3.85.
On 8 Dec 2010, 08:43.