 |
Task
model
 |
Task
is modeled as a memory reference string, which is a sequence of (p, d) such
that
 |
p
is a page in the virtual address space of the process |
 |
d
is dirty flag |
|
 |
Virtual
time of a task: the number of completed references to pages for the
task |
|
 |
Operating
system model
 |
A
task is either
 |
in
the active queue, |
 |
in
the ready queue, or |
 |
dormant
(or blocked) |
|
 |
Load
control moves tasks between the ready and the active queue |
 |
Tasks
in the active queue get scheduled according to a scheduling
discipline |
|
 |
Working
Set
 |
Working
set determination: finding pages leaving W is difficult
 |
Needs
to scan all the resident pages of the process, or needs to
maintain the set of pages in W to scan only pages in W |
|
 |
Load
control and replacement
 |
Needs
to maintain a free list of pages which do not belong to any W |
|
 |
Page
Writing and Reclamation
 |
Pages
in the free list should be reclaimed if it is referenced
before being kicked out |
|
|
 |
Global
Clock
 |
Naive
extension of Clock algorithm but with some feedback mechanism (such
as clock hand movement rate) to control multiprogramming level |
|
 |
Comparing
WS and Clock
 |
WS
requires more memory and complex algorithm
 |
WS-scan
procedure |
 |
Space
for LR(p) (Latest Reference time of the page) doubles page table.
Remember that the size of page table does matter |
 |
Algorithm
to maintain free list of pages, including a method to reclaim
pages from the list |
|
 |
Clock
requires a fine tuned adaptive feedback load control mechanism |
 |
In
Clock, a greedy process can monopolize memory |
|
 |
Process
is either in loading phase or running phase
 |
Loading
phase: W has not been loaded yet |
|
 |
Problem
 |
Loading
time (wall-clock-time to bring pages in W in memory) is proportional to the
number of loading processes because all the loading processes
contend for a single auxiliary memory |
 |
Many
loading processes increase the probability that
 |
running processes
finish their
job while loading processes contending each other and |
 |
they
are replaced by even more loading processes |
|
 |
=>
Disk is over committed, but memory is under committed! |
|
 |
Solution
 |
Decrease the loading time
by controlling the number of loading processes at a moment |
|
 |
A
process is in loading phase until
 |
v virtual time
elapsed, or |
 |
the
process issues an I/O request, otherwise I/O bound process can
prevent new task activation undefinitely |
|
 |
LT/RT
can be used to refrain from loading another process
 |
while
some of memory resident processes are still in loading phase, where
 |
the
size of the working set is not known yet! |
|
|