a1sp06solutions - CS 414 Assignment 1 Solutions February 2...

Info icon This preview shows pages 1–2. Sign up to view the full content.

View Full Document Right Arrow Icon
CS 414 Assignment 1 Solutions February 2, 2006 Include your netid on every page of the submitted file. Name the file with the right extension. 1. Hardware interrupts support a concept of priority: an integer between 0 and 7. The rule is that when the CPU is running code at priority k (zero is the default), an interrupt of level l¿k can occur. When the CPU is at level l or above, the interrupt must wait until the handler has finished and the priority drops again. (a) Thinking about the devices connected to a typical PC (other than the processor clock), give an example of two devices where it would be best from a system performance perspective for one to inter- rupt at a higher priority and the other at a lower priority, and explain your reasoning. Solution Disk (I/O) should have higher priority than printer/mouse, notification on completion of disk reads is more critical for pro- gram execution. Comments Many people placed user I/O above system I/O, on the belief that the user would notice degraded quality. This was a very common mistake, and is wrong. (b) Usually, the system clock is the highest priority device: it inter- rupts at priority level 6 and no other device uses priority 6 or 7. Explain why this makes a lot of sense Solution System clock is used for recovering from infinite loops, if some devices have higher interrupt priority level, the device drivers can cause infinite loops.
Image of page 1

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

View Full Document Right Arrow Icon
Image of page 2
This is the end of the preview. Sign up to access the rest of the document.

{[ snackBarMessage ]}

What students are saying

  • Left Quote Icon

    As a current student on this bumpy collegiate pathway, I stumbled upon Course Hero, where I can find study resources for nearly all my courses, get online help from tutors 24/7, and even share my old projects, papers, and lecture notes with other students.

    Student Picture

    Kiran Temple University Fox School of Business ‘17, Course Hero Intern

  • Left Quote Icon

    I cannot even describe how much Course Hero helped me this summer. It’s truly become something I can always rely on and help me. In the end, I was not only able to survive summer classes, but I was able to thrive thanks to Course Hero.

    Student Picture

    Dana University of Pennsylvania ‘17, Course Hero Intern

  • Left Quote Icon

    The ability to access any university’s resources through Course Hero proved invaluable in my case. I was behind on Tulane coursework and actually used UCLA’s materials to help me move forward and get everything together on time.

    Student Picture

    Jill Tulane University ‘16, Course Hero Intern