The Objective Of This Assignment Is To Implement A Multitasking Tiny Unix On The Sap 2904985

The objective of this assignment is to implement a multitasking Tiny-UNIX on the SAPC. The students are asked to expand the Tiny-UNIX kernel in hw2 to multitask three programs, each of which will only make writes (to TTY0 or TTY1) and exit system calls.
In this assignment, the console output port (COM2) is the resource shared among the three programs. As in hw2, the output is interrupt-driven. This is a producer-consumer situation, with 3 producers filling the output buffer of COM2 and one consumer, the transmit interrupt handler, outputs the characters. When the output buffer is full, the processes will block in the “write” operation, giving up the CPU for other processes to use. This eliminates spin loops in the kernel.
The students will make use of the provided CPU context switching program (asmswtch.s) in writing a non-preemptive scheduler (one which never grabs the CPU away from a process which can be run) to control the running of the processes. Process switching will only occur when a process blocks (for output) or exits. After a process exits, it is a “zombie” in UNIX parlance: all that is really left of it is its exit value, waiting to be picked up by its parent. Since there is no parent process, the students will simply print out the exit values with the shutdown message of the kernel, after the completion of all three processes.
Document Preview:

HW3: Multitasking Tiny-UNIX on the SAPC Assigned: 26 March 2019Due: class time 16 April 2019 1. Introduction The objective of this assignment is to implement a multitasking Tiny-UNIX on the SAPC. The students are asked to expand the Tiny-UNIX kernel in hw2 to multitask three programs, each of which will only make writes (to TTY0 or TTY1) and exit system calls. In this assignment, the console output port (COM2) is the resource shared among the three programs. As in hw2, the output is interrupt-driven. This is a producer-consumer situation, with 3 producers filling the output buffer of COM2 and one consumer, the transmit interrupt handler, outputs the characters. When the output buffer is full, the processes will block in the “write” operation, giving up the CPU for other processes to use. This eliminates spin loops in the kernel. The students will make use of the provided CPU context switching program (asmswtch.s) in writing a non-preemptive scheduler (one which never grabs the CPU away from a process which can be run) to control the running of the processes. Process switching will only occur when a process blocks (for output) or exits. After a process exits, it is a “zombie” in UNIX parlance: all that is really left of it is its exit value, waiting to be picked up by its parent. Since there is no parent process, the students will simply print out the exit values with the shutdown message of the kernel, after the completion of all three processes. 2. Discussions The user program (here a bundle of 3 user programs) to be run on the SAPC has to be built in the same way as in hw2, downloaded and run. As in hw2, the user process is running in supervisor mode, sharing a common stack area between user and kernel for each process. There will be separate stacks for each of the three processes. The program begins with startup0, then startup1. Then it calls the kernel initialization, which sets up the three processes’ initial data. We will follow UNIX in…

Attachments:

hw3.doc

Prof. Angela

4.6/5

Calculate Price


Price (USD)
$
Open chat