Professional Documents
Culture Documents
Strategy Selection Os
Strategy Selection Os
Operating Systems
Daniel Merkle
Application software
Performs specific tasks for users
System software
Provides infrastructure for application software
Consists of operating system and utility
software
Show http://www.it.uom.gr/teaching/opsysanimation/animations/PROCESS.SWF
DM526 Operating Systems
Process Administration
P1 P2 P3
0 24 27 30
Waiting time for P1 = 0; P2 = 24; P3 = 27
Average waiting time: (0 + 24 + 27)/3 = 17
0 3 6 30
0 3 9 16 24
P1 P2 P3 P1 P1 P1 P1 P1
0 4 7 10 14 18 22 26 30
Show Solaris
DM526 Operating Systems
Excursus: Virtual Machines
static int s = 0;
Thread 1 Thread 2
A= 3 5 f (x) = x2
static int s = 0;
Thread 1 Thread 2
.
compute f([A[i]) and put in reg0 9 compute f([A[i]) and put in reg0 25
reg1 = s 0 reg1 = s 0
reg1 = reg1 + reg0 9 reg1 = reg1 + reg0 25
s = reg1 9 s = reg1 25
Thread 1 Thread 2
local_s1= 0 local_s2 = 0
for i = 0, n/2-1 for i = n/2, n-1
local_s1 = local_s1 + f(A[i]) local_s2= local_s2 + f(A[i])
lock(lk); lock(lk);
s = s + local_s1 s = s +local_s2
unlock(lk); unlock(lk);