GATE Computer ScienceHardGATE CS (PYQ pattern)
A branch behaves T, T, N, N repeatedly for 32 executions. A 2-bit saturating counter starts at state 0 and predicts taken in states 2 and 3. How many of the 32 predictions are wrong?
- A. 16
- B. 20
- C. 24
- D. 23
Correct answer: C. 24
Per period from state 0: T (predict N, wrong) →1, T (predict N, wrong) →2, N (predict T, wrong) →1, N (predict N, right) →0. Three misses a period, 8 periods = 24, so the pattern is as bad as random for this predictor.
Practise more Computer Organization and Architecture questionsComputer Organization and Architecture: notes and key points
More Computer Organization and Architecture questions
- A 32-bit machine uses a 2-level page table with 4 KB pages and 4-byte entries (10 + 10 + 12 bit split). A process uses exactly 4 MB + 8 KB…
- Which of the following statements about performance are correct? I. A lower CPI always means a faster machine. II. Execution time =…
- A DMA controller in burst mode moves 4-byte words at one word per 40 ns bus cycle from a device producing 10 MB/s (1 MB = 10⁶ B). The CPU…
- A 256 KB, 8-way set-associative write-back cache has 64-byte blocks and 36-bit physical addresses. Each line stores its data, tag, a valid…
- A system has 44-bit virtual addresses, 4 KB pages and 8-byte page-table entries. Every level of its multi-level page table except the top…
- A classic 5-stage pipeline (IF, ID, EX, MEM, WB) has full forwarding (EX/MEM and MEM/WB to the ALU inputs), so only a load followed…