GATE Computer ScienceVery hardGATE CS (PYQ pattern)
A processor services interrupts with nested priorities: a higher-priority interrupt (larger number) preempts a running lower-priority handler immediately, and a pending handler runs only when no higher-priority handler is active. Handlers (P: priority 1, arrives at t = 0 µs, needs 12 µs; Q: priority 2, arrives at t = 3 µs, needs 6 µs; R: priority 4, arrives at t = 5 µs, needs 3 µs; S: priority 3, arrives at t = 7 µs, needs 4 µs) have no overhead. At what time (µs) does handler P finish?
- A. 25
- B. 27
- C. 28
- D. 22
Correct answer: A. 25
Total work is 25 µs, but P finishes only after every higher-priority handler that arrives before it completes. Simulating µs by µs gives completion times {'R': 8, 'S': 12, 'Q': 16, 'P': 25}.
Practise more Computer Organization and Architecture questionsComputer Organization and Architecture: notes and key points
More Computer Organization and Architecture questions
- Radix-4 Booth recoding of the 8-bit two's-complement multiplier 01101110 (value 110) produces four digits in {−2, −1, 0, +1, +2}. Which…
- Three interrupt handlers have no overhead: A (priority 1, arrives at 0 µs, runs 10 µs), B (priority 3, arrives at 4 µs, runs 5 µs) and C…
- A cache access takes 2 ns on a hit; a miss takes 22 ns in total (hierarchical model). The average access time is 5 ns. What is the miss…
- In an n-bit two's-complement adder, which pair (carry into the MSB, carry out of the MSB) signals signed overflow?
- The logic of a processor takes 48 ns per instruction unpipelined. Pipelining into k stages gives a cycle time of 48/k + 3 ns (latch…
- A branch target buffer (BTB) lets the fetch unit predict taken branches with no bubble when it hits and predicts correctly. Branches are…