+1 vote
67 views
In a $32$-bit computer instruction format, the size of address field is $9$-bits. The computer uses expanding opcode technique and has $28$ three-address instructions, $2040$ two-address instructions, $4040$ one-address instructions. The number of zero-address instructions it can support is ________
edited | 67 views

The number of free bit patterns after removing 3-address instructions= 32-28=4. Thus total possible 2-address instructions= $4*2^9=2048$.
The number of free bit patterns after removing 2-address instructions: $2048-2040=8$
The number of possible 1-address instructions: $8*2^9=4096$
The free bit patterns after removing 1-address instructions: $4096-4040=56$.
Thus number of possible zero address instructions:$56*2^9=28672$
+1 vote
Total encodings are $2^{32}$

Number of encodings used in $three$ address instruction$=28*2^9*2^9*2^9$

Number of encodings used in $two$ address instruction$=2040*2^9*2^9$

Number of encodings used in $one$ address instruction$=4040*2^9$

Remaining encodings can be used for zero address instruction$=2^{32}-(28*2^9*2^9*2^9+2040*2^9*2^9+4040*2^9)=28672$

1