5 Flashcards
Protection
-process can only access addresses in its address space
-using a pair of base and limit registers
modes for our cpu
user mode, kernal mode
address protection
cpu must check every memory access generator in user mode to ensure its between base and limit for that user
-instructions to load base and limit registers privileged
Address Binding
Program on disk ready to be brought into memory to execute form an input queue
-source code adresses symbolic
-compiled code bind to relocatable addresses
-each binding step maps one address space to another
Logical address
generated by the CPU, aka virtual address, address space is set of all logical addresses generated by a program
physical address
address seen by memory unit, address space is set of all physical address space generated by a program
Fragmentation - external
External - total memory space may exist to satisfy a request, not contagious. approaches like compaction - shuffle memory contents to put free memory next to each other
Fragmentation - Internal
allocated memory may be larger than requested memory, size difference is memory internal to a partition, but not being used - both internal and external wasteful - paging better
Paging
Physical address space of a process can be noncontiguous, process allocated physical memory where available
- avoids extermal fragmentation
- avoids problem of varying sized memory chunks
whats pages divided into
fixed size blocks called frames, size is power of 2 between 512 bytes and 16Mb
To run a program of N pages how many frames we need
N
address translation scheme
divided into page number - index into page table which contains base address of each page in physical memory
page offset - combined with base address to define physical memory
where is page table
kept in main memory
-PTBR Page-table base register points to the page table
PTLR Page table length register indicates size of page table
Translation Look-Aside Buffer
Store adress-space identifers in each TLB entry, these uniquely identify each process to provide address-space protection
effective access time
Hit ratio - percentage of times page number found in TLB