Tutorial Week 3

Questions

MIPS R3000 Questions

Q1: What is a branch delay?

Q2: What is the EPC register? What is it used for?

Q3: The R3000 divided the address space into 4 regions. Which regions are accessible in what mode? Why is kuseg accessible to the kernel? Why is the cache bypassed when accessing kseg1?

Q4: What happens to the KUc and IEc bits in the STATUS register when an exception occurs? Why? How are they restored?

General Questions


Q5: A computer has a pipeline with 4 stages. Each stage takes the same time to do its work, namely, 1 nsec. How many instructions per second can this machine execute?

System Calls

Q6: How does the 'C' function calling convention relate to the system call interface between the application and the kernel? At minimum, what additional information is required beyond that passed to the system-call wrapper function?

Q7: In the example given in lectures, the library procedure read invoked the read system call. Is it essential that both have the same name? If not, which name is important?

Q8: To a programmer, a system call looks like any other call to a library procedure. Is it important that a programmer know which library procedures result in system calls? Under what circumstances and why?