Nachos Instructional OS. CS 270, Tao Yang, Spring 2011. What is Nachos OS?. Allow students to examine, modify and execute operating system software. A skeletal OS that supports kernel threads user-level processes Simulates MIPS instruction execution.
Nachos Instructional OS
CS 270, Tao Yang, Spring 2011
Nachos kernel threads
Nachos OS modules
(Threads mgm, File System, Code execution/memory mapping,
Simulated MIPS Machine
(CPU, Memory, Disk, Console)
Base Operating System (Linux for our class)
Objectives of next 2 weeks
Thread *t1 = new Thread("forked thread1");
Thread *t2 = new Thread("forked thread2");
printf(“Hello %d\n”, i);
Create 2 new threads.
Start to fork and execute a function in each child thread.
Parent also executes the same function
Function executed by threads
When running in user mode, the thread executes within the machine simulator. HW 2 covers this.
In HW 1 we are only concerned with the states in this box.
Make thread ready to run and place it on the ready list.
After you type ``nachos'' under threads subdirectory:
All files are in threads directory.
func() such as
threadToBeDestroyed = currentThread;
Other related files.
e.g. Not well documented, not fully tested. Possibly awkward design.