Nikhil Gupta
PhD student, Texas A&M university
Welcome to the TA page for CPSC 410
MP2 Posted
The handout , source code and presentation for the second machine problem are available now.
MP1 Posted
The handout , source code and presentation for the first machine problem are available now.
MP1 Grading Policy
Following is the grading policy for MP1.
Analysis |
: |
30% |
Amount of WFS functionality (mentioned in the handout) implemented |
: |
40% |
The correctness of your implementation |
: |
30% |
If your project doesn't compile, you get a deduction of |
: |
20% |
Help on MP1
To be able to work with the source code for the project you will need to save the zip file for the code to your H drive. Then ssh into sun.cs.tamu.edu using a terminal emulator (e.g. Putty). Now navigate to your H drive on the sun and to unzip the zip file, use the command :
% unzip MP1.zip
This will give you the MP1 directory with the copy1 and copy2 directories under it.
To compile the project used the command :
% make
To run the emulator use :
% gxemul -E testmips schedtest
To redirect the output of the emulator to a log file use the following sequence:
% gxemul -E testmips schedtest | tee log
CTRL-C
quit
Tips on the output produced by the Round Robin scheduler
1)
EXCEPTION DISPATCHER: xcp_code = 0
IDisp::handle_exc : int_stat = 128
TIMER DISPATCHER::HANDLE_EXCEPTION
icount = 0
NOW: Time: 0sec/ 33msec/ 951musec/ 190nsec curr thread = CPB7
UN-MASKING INTRPT <7>
PUTTING CPB9 ON READY QUEUE
TimerDisp: DONE
The above output shows the Timer dispatcher waking up. It wakes up every
2msec in the current code, which is set at line 255 in schedtest.C (TimeVal
timer_update_interval(0, 2000000)). The timer dispatcher checks for events
that need to be processed and finally prints DONE. In the example above we see
"PUTTING CPB9 ON READY QUEUE", an event was processed out of the dispatcher
event queue. Since this is a low level interrupt the above block of text gets
printed out every 2msec and may disrupt the normal flow of output.
2)
new thread = T <Web2/p=10>
This is printed whenever a new thread is picked up in first_ready.
3)
setting timer to TIMER SET (Time: 0sec/ 10msec/ 0musec/ 0nsec)
This is printed whenever a timer is set. In this particular example the timer
is being set for the RRScheduler time quantum.
Introduction to the environment we will be working in
We have a barebones operating system up for you, which you are supposed to improve/add functionalities to.
The OS is meant to be run on a processor with the MIPS architecture. So, we will be actually running our OS on
an emulator called gxemul. To be able to produce code which
runs on a MIPS machine, we would need a cross compiler toolchain. Both gxemul and the cross-compiler are already setup on sun.cs.tamu.edu
Each machine problem will consist of two components, the code part and the analysis part. Each part would contain its separate
turnin page on CSNET.
Some tips to make your life easier while doing your assignments:
1) To find out more about any command in the linux environment just do a "man command",(e.g. "man ls"). This will show you a description of the command with all the possible options.
2) Use ctags to browse through the source code: Get ctags installed on the computer you are working on. Now inside your code directory(e.g. KMem_Source) do a "ctags -R *". This browses through all the source code and creates a file called tags which can be used by vim to find the definition of keywords. Now, whenever you are browsing through the source code, if you encounter a keyword for which you want to know where/how it is defined, just point your cursor on the keyword and do an CTRL-](In escape mode, press the CTRL and ] keys simultaneously). Vim will take you to the definition of the keyword(even if it is in another file!!). To return to where you were, do a CTRL-t.
To find out more about ctags do a "man ctags"
I may be adding more tips later, so check this webpage for updates.
latest news
02/18/2007
Office Hours: MW 2:00 - 3:00 PM;
F 4:00 - 5:00 PM. @ 219/210 HRBB.
02/15/2008
The late policy is to deduct 20% per day late.
02/15/2008
The grades for the assignments would be sent to your email id listed on csnet.
Please verify that a valid id is listed there.