GATE Computer ScienceHardGATE CS (PYQ pattern)
A pipeline (ideal CPI 1) can predict branches not-taken (a taken branch costs 3 cycles, a not-taken one 0) or predict taken (a taken branch costs 1 cycle, a not-taken one 3). Branches are 20% of instructions. Above what fraction of taken branches is predict-taken better, and what is the better CPI when 65% of branches are taken?
- A. 50%; CPI 1.34
- B. 60%; CPI 1.39
- C. 75%; CPI 1.34
- D. 60%; CPI 1.34
Correct answer: D. 60%; CPI 1.34
Per branch: not-taken scheme 3t, taken scheme t + 3(1 − t) = 3 − 2t. Equal at 3t = 3 − 2t → t = 0.6. At t = 0.65: predict-taken 1 + 0.2 × (0.65 + 1.05) = 1.34, versus 1 + 0.2 × 1.95 = 1.39 for predict-not-taken.
Practise more Computer Organization and Architecture questionsComputer Organization and Architecture: notes and key points
More Computer Organization and Architecture questions
- A direct-mapped cache with 32-byte blocks and 32-bit addresses stores, for every line, only a tag and a valid bit as metadata. The total…
- A loop computes y[i] += A[i][j] × x[j] for a 64×64 matrix of 4-byte floats (A in row-major order at address 0, x at 16384, y at 17024)…
- A 2²²-word memory uses a coincident (2-D) decoding scheme with a square cell array: one decoder selects the row, another the column. How…
- The IEEE 754 half-precision word 0xC4D0 (1 sign bit, 5 exponent bits with bias 15, 10 fraction bits) represents which value?
- A 16 KB, 4-way set-associative cache with 16-byte blocks uses 32-bit addresses. Its block size is doubled to 32 bytes and, at the same…
- A processor's logic takes 60 ns per instruction unpipelined. Split into k stages, the cycle time is 60/k + L ns (L = latch overhead) and…