0 votes 0 votes Assume that there are 251 different opcode and 32 registers in the machine.Every instruction has 3 register as input and 1 register as output[opcode , R1 , R2 , R3 , R4].The number of bits to encode an instruction A_i_$_h asked Sep 15, 2017 A_i_$_h 501 views answer comment Share Follow See all 0 reply Please log in or register to add a comment.
Best answer 2 votes 2 votes Number of different opcodes given = 251 Hence number of bits needed to represent opcode = ceil ( log2251 ) = 8 Number of registers given = 32 Hence number of bits needed to represent register = log232 = 5 Hence number of bits needed for instruction = 8 + 4 * 5 [ Bcoz one opcode field and 4 register fields ] = 28 bits Habibkhan answered Sep 15, 2017 selected Sep 16, 2017 by A_i_$_h Habibkhan comment Share Follow See all 0 reply Please log in or register to add a comment.