pa1-sleep.dsk available.


R. Clayton (rclayton@monmouth.edu)
Fri, 6 Oct 2000 21:31:14 -0400 (EDT)


The pa1-sleep.dsk batch disk is available in /export/opt/cs-438-505/devices.

You should get your operating system to work with pa1-nosleep.dsk before you go
on to pa1-sleep.dsk. Once you get to pa1-sleep.dsk, I recommend you get the
sleep system call to work first, then go on to multi-processing.

The following is an example execution from my implementation of the operating
system (called pa1os):

  cl pa1os -d /export/opt/cs-438-505/devices/pa1-sleep.dsk
  At time 0, run process 1.
  At time 50, run process 2.
  At time 121, process 2 sleeps for 100 ticks.
  At time 121, run process 4.
  At time 177, process 4 sleeps for 100 ticks.
  At time 177, run process 6.
  At time 216, process 6 sleeps for 20 ticks.
  At time 216, run process 7.
  At time 221, process 2 wakes up.
  At time 236, process 6 wakes up.
  At time 269, process 7 sleeps for 30 ticks.
  At time 269, run process 6.
  At time 277, process 4 wakes up.
  At time 299, process 7 wakes up.
  At time 307, process 6 exits.
  At time 307, run process 7.
  At time 317, process 7 exits.
  At time 317, run process 5.
  At time 381, process 5 sleeps for 10 ticks.
  At time 381, run process 4.
  At time 391, process 5 wakes up.
  At time 392, process 4 exits.
  At time 392, run process 5.
  At time 442, process 5 exits.
  At time 442, run process 3.
  At time 479, process 3 sleeps for 100 ticks.
  At time 479, run process 2.
  At time 529, process 2 exits.
  At time 529, run process 1.
  At time 579, process 3 wakes up.
  At time 579, run process 3.
  At time 615, process 3 exits.
  At time 615, run process 1.

  The system is halted.
  Total execution time: 615 ticks.

  cl

The "At time" message were printed by pa1os, not the simulator. This version
of pa1os does multiprocessing. Process 1 is the idle process, there are six
program on the pa1-sleep.dsk.

Here's pa1os on the pa1-nosleep.dsk:

  cl pa1os -d /export/opt/cs-438-505/devices/pa1-nosleep.dsk
  At time 0, run process 1.
  At time 50, run process 2.
  At time 168, process 2 exits.
  At time 168, run process 5.
  At time 170, process 5 exits.
  At time 170, run process 4.
  At time 228, process 4 exits.
  At time 228, run process 3.
  At time 298, process 3 exits.
  At time 298, run process 1.

  The system is halted.
  Total execution time: 298 ticks.

  cl

Note that with multiprocessing, pa1os executes the programs on the
pa1-nosleep.dsk in 298 ticks instead of the 352 tick it took without
multiprocessing.

Here's the empty batch disk:

  cl pa1os -d /export/opt/cs-438-505/devices/empty.dsk
  At time 0, run process 1.

  The system is halted.
  Total execution time: 10 ticks.

  cl



This archive was generated by hypermail 2.0b3 on Mon Dec 18 2000 - 13:30:05 EST