Related Articles
GATE | GATE-CS-2014-(Set-1) | Question 65
• Last Updated : 25 Nov, 2019

A machine has a 32-bit architecture, with 1-word long instructions. It has 64 registers, each of which is 32 bits long. It needs to support 45 instructions, which have an immediate operand in addition to two register operands. Assuming that the immediate operand is an unsigned integer, the maximum value of the immediate operand is ____________.
(A) 16383

Explanation:

`1 Word = 32 bits `

Each instruction has 32 bits. To support 45 instructions, opcode must contain 6-bits

Register operand1 requires 6 bits, since the total registers are 64. Register operand 2 also requires 6 bits. So total 18 bits for all 45 instruction and two register operands. So

`32-18 = 14 `

14-bits are left over for immediate Operand Using 14-bits, now

`2^14 - 1 = 16383 `

We can give maximum 16383.

Quiz of this Question

Attention reader! Don’t stop learning now. Learn all GATE CS concepts with Free Live Classes on our youtube channel.

My Personal Notes arrow_drop_up