CameraIcon
CameraIcon
SearchIcon
MyQuestionIcon
MyQuestionIcon
1
You visited us 1 times! Enjoying our articles? Unlock Full Access!
Question

The data path shown in the figure computes the number of 1s in the 32-bit input word corresponding to an unsigned even integer stored in the shift register. The unsigned counter, initially zero, is incremented if the most significant bit of the shift register is 1.


The microprogram for the control is shown in the table below with missing control words for microinstructions I1,I2,.....,In

Micro- instruction reset_counter shift_left load_output
BEGIN 1 0 0
I1 ? ? ?
: : : :
In ? ? ?
END 0 0 1


The counter width (k), the number of missing microinstructions (n), and the control word for microinstructions I1,I2,.....,In are, respectively.

A
5, 31, 010
Right on! Give the BNAT exam to get a 100% scholarship for BYJUS courses
B
5, 32, 010
No worries! We‘ve got your back. Try BYJU‘S free classes today!
C
32, 5, 010
No worries! We‘ve got your back. Try BYJU‘S free classes today!
D
5, 31, 011
No worries! We‘ve got your back. Try BYJU‘S free classes today!
Open in App
Solution

The correct option is A 5, 31, 010
Since the number is even number i.e. LSB bit must be 0, so maximum 31 1's presents, so loop will be runs for 31 times i.e. number of missing instruction are 31.

The input word is of 32 bits long, so width of counter = log(32) = 5 bits.

To count number of 1's, reset counter will be reset i.e, 0. Shift left = 1 i.e., decrease number of 1's by 1 in each iteration and load output is 0 for all instructions except "END".

flag
Suggest Corrections
thumbs-up
0
Join BYJU'S Learning Program
similar_icon
Related Videos
thumbnail
lock
HISTORY
Watch in App
Join BYJU'S Learning Program
CrossIcon