Main Memory Part 1 Flashcards
CPU is capable of directly accessing only CPU ______, _____ memory, and ________ memory
caches, main, persistent
Programs must be loaded to ______ memory for execution
main
Systems in the early days had _________ memory systems
physical
In early days, the OS starts a physical address ____
zero
In early days, application programs used the memory space not used by the ___
OS
In early days, systems could only run _____ user program at a time
one
Systems in the early days were _________ because of low _______ utilization
inefficient, resource
In multi-programming, there needs to be ________ and ________ between processes
protection, isolation
_______ ______can be used to protect and isolate processes in multi-programming
address space
What is address space?
Easy-to-use abstraction of physical memory
Address space provides an _______ that each process uses the whole memory space
illusion
Address space _______ uses memory space
efficiently
Each process has its own ______ _______ that starts from 0 and ends at max memory possible. This is called ______ ______
address space, virtual address
Describe the 4 sections of the memory space from top to bottom.
Stack: Local vars and return addresses
Heap: Dynamically allocated
Data: Global vars
Text: Program code
A ____ and a ______ register define the logical address space
base, limit
Physical address = ______ + _________ _______
base, virtual address
What is a base in the logical address schema?
Starting address in physical memory
What is the virtual address in the logical address schema?
Offset into the address space
The base and limit registers are supported by the __________ ___________ unit
memory management
Modifying the base and limit registers requires __________ instructions
privileged
_______ address space cannot be larger than _______ address space
logical, physical
Logical address space must be stored __________
contiguously
Logical address space may waste space between the ____ and ______
heap, stack
A better alternative to logical address space would be __________
segmentation
Segmentation generalizes _____ and_______
base, limit
In a programmer’s view of memory, a program is a collection of _______
segments
In a prgorammer’s view of memory, a segment is a logical unit such as…
- Main program
- Functions, procedures
- Method
- Object
- Local variables, global variables
- Stack
- Symbol tables
- Arrays
In segmentation, we have a base + limit pair per logical _______
segment
In a segmentation architecture, what is the form of the logical address?
(segment-number, offset)
A ______ table maps logical address to physical address
segment
Each entry in the segment table has a ______, which is the starting physical address of segment, and a ______, which is the length of segment
base, limit
One issue of segmentation is that the OS needs to _____ and __________ segment registers upon context switch
save, restore
One issue of segmentation is managing _____ ______. The OS needs to find free space in memory for new address space
free spaces
What is external fragmentation?
When physical memory becomes full of small holes of free spaces, making it harder to allocate new segments or grow existing ones.
To fix the issues in segmentation, we use _____ _______ ___________ schemes
free space management