Thread support may be implemented for extra credit in Labs 4-5. Nachos systems with thread support should define the semantics of Exit in the following way. Exit indicates that the calling thread is finished; if the calling thread is the last thread in the process then it causes the entire process to exit (e.g., wake up joiner if any). The status value reported by the last thread in the process to call Exit shall be deemed the exit status of the process, to be returned as the result from Join .
Creates a new thread of control executing in the calling user process address space. The function argument is a procedure pointer, a user-space virtual address: the new thread will begin executing at this address in the same address space as the thread calling Fork . The new thread must have its own user stack in the user address space, separate from all other threads. It must be able to make system calls and block independently of other threads in the same process.
Called within a user program to yield the CPU. Yield triggers a Thread::Yield within Nachos, allowing some other ready thread to run.