45.4k views
4 votes
I wish to have a computer whose machine-level instructions are all 32 bits each. If I want to have all instructions of the form mov R1, R2 where R1 and R2 are registers. What is the maximum number of instructions that my machine can have, if my computer needs to have at least 1000 different registers referenced in the instructions?

1 Answer

4 votes

Answer:

Maximum number that can be represented by 13 bits is 8192 Instructions

Step-by-step explanation:

number of instructions = 1000

number of bits = log(1000) x number of register

= 6 bits

Since the complete instruction must have 32 bits, then

remaining number of bits = 32 - 6 = 236

number of registers in instruction = 2

number of bits per register = 26/2 = 13

Maximum number that can be represented by 13 bits =
2^(n)

= 2¹³ = 8192

User Douglas Ribeiro
by
5.8k points