Nachos - MODULE TITLE Operating systems Tutor Name: P rof...

Info iconThis preview shows pages 1–5. Sign up to view the full content.

View Full Document Right Arrow Icon
MODULE TITLE Operating systems Tutor Name: Prof Marcos Rodrigues Assignment:-NACHOS REPORT Assignment Submitted By: Student Name: VIJAYA PAVAN REDDY NARASAREDDYGARI Student ID: 18032246
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Nachos Overview Not Another Completely Heuristic Operating System or NACHOS is instrumental software which is developed at Berkley by Tom Anderson and his students. NACHOS is mainly used for educational purpose, which is used demonstrate the operating system concepts such as Thread management Multi processing File system Virtual memory Networking etc…. Directory structure of NACHOS Explanation for NACHOS directory structure
Background image of page 2
Bin : bin contains source code of coff2noff which is used for converting data into nachos object file format which are used by user programs of nachos Filesys : File system in nachos comes with two version “real” and “stub”. The stub system uses UNIX system file system operations where NACHOS is running. The real system is built on disk simulator which is simulated using UNIX file system. Lib : Nachos uses utilities here Machine : this is used for simulation. Network : supporting files for networking are given here for NACHOS which is implemented in post office format. Test : Tests directory contains files of user test programs to run on simulatation machine. It contains its own makefile .the test programs are written in c. Threads : nachos is multi threaded system .the files required for performing of thread operations are present here Userprog : files used for supporting of user programs are present here such as loading of user program, running of test programs on simulated machine. It also contains exception.cc for handling of exceptions. Multi threading Normally many operating systems use concept of threads which are also called light weight processes .Normally a process will contain several threads and these threads use the same addresses space .Threads are some way similar to that of processes. Threads can be in different states such as Ready Running: blocked just created Nacho is provided with set of thread package which is provided in … /nachos/threads directory. This package allows us to create threads, switch control among threads, terminate threads etc… Threads perform different operation such as fork, yield, sleep, finish, begin…. The operation of are given below Fork : Fork is used for creating a new thread by forking a thread object. Implementation of for can be taken place in steps as Stack allocation, stack implementation and placing the thread on ready queue The piece of code given below is used for forking procedure void
Background image of page 3

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Thread::Fork(VoidFunctionPtr func, void *arg) { Interrupt *interrupt = kernel->interrupt; Scheduler *scheduler = kernel->scheduler; IntStatus oldLevel; DEBUG(dbgThread, "Forking thread: " << name << " f(a): " << ( int ) func << " " << arg); StackAllocate(func, arg); oldLevel = interrupt->SetLevel(IntOff); scheduler->ReadyToRun( this ); ( void ) interrupt->SetLevel(oldLevel);
Background image of page 4
Image of page 5
This is the end of the preview. Sign up to access the rest of the document.

This note was uploaded on 02/22/2011 for the course CS 541 taught by Professor Dr.marcosrodrigues during the Spring '09 term at SUNY Buffalo.

Page1 / 14

Nachos - MODULE TITLE Operating systems Tutor Name: P rof...

This preview shows document pages 1 - 5. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online