Microprogrammed-Control-Unit
Question 1 |
Consider a CPU where all the instructions require 7 clock cycles to complete execution. There are 140 instructions in the instruction set. It is found that 125 control signals are needed to be generated by the control unit. While designing the horizontal microprogrammed control unit, single address field format is used for branch control logic. What is the minimum size of the control word and control address register?
125, 7 | |
125, 10 | |
135, 7 | |
135, 10 |
Question 1 Explanation:
Each instruction takes 7 cycles,
i.e., 140 instruction takes = 140 * 7 =980 cycles.
So, size of control address register = ⌈log2 980⌉
= 10 bit
Since horizontal microprogramming is used, so 125 control signals will require 125 bits.
Hence, size of control word = 125 + 10 = 135 bits
i.e., 140 instruction takes = 140 * 7 =980 cycles.
So, size of control address register = ⌈log2 980⌉
= 10 bit
Since horizontal microprogramming is used, so 125 control signals will require 125 bits.
Hence, size of control word = 125 + 10 = 135 bits
Question 2 |
A microprogrammed control unit
Is faster than a hard-wired control unit. | |
Facilitates easy implementation of new instruction. | |
Is useful when very small programs are to be run. | |
Usually refers to the control unit of a microprocessor. |
Question 2 Explanation:
In micro-programmed control unit we can add new instruction by changing the content of control memory.
Question 3 |
Consider a control unit generating the control signals. These control signals are divided into five mutually exclusive groups as shown below:
How many bits are saved using the Vertical Microprogrammed instead of Horizontal Microprogrammed control unit?
How many bits are saved using the Vertical Microprogrammed instead of Horizontal Microprogrammed control unit?
14 | |
34 | |
20 | |
None |
Question 3 Explanation:
In horizontal microprogramming we need 1 bit for every control word, therefore total bits in horizontal microprogramming
= 3 + 7 + 10 + 12 + 2
= 34
Now lets consider vertical microprogramming. In vertical microprogramming no. of bits required to activate 1 signal in group of N signals, is ⌈log2 N⌉. And in the question 5 groups contains mutually exclusive signals,
group 1 = ⌈log2 3⌉ = 2
group 2 = ⌈log2 7⌉ = 3
group 3 = ⌈log2 10⌉ = 4
group 4 = ⌈log2 12⌉ = 4
group 5 = ⌈log2 2⌉ = 1
Total bits required in vertical microprogramming
= 2+ 3 + 4 + 4+ 1
= 14
So, number of bits saved is
= 34 - 14
= 20
= 3 + 7 + 10 + 12 + 2
= 34
Now lets consider vertical microprogramming. In vertical microprogramming no. of bits required to activate 1 signal in group of N signals, is ⌈log2 N⌉. And in the question 5 groups contains mutually exclusive signals,
group 1 = ⌈log2 3⌉ = 2
group 2 = ⌈log2 7⌉ = 3
group 3 = ⌈log2 10⌉ = 4
group 4 = ⌈log2 12⌉ = 4
group 5 = ⌈log2 2⌉ = 1
Total bits required in vertical microprogramming
= 2+ 3 + 4 + 4+ 1
= 14
So, number of bits saved is
= 34 - 14
= 20
There are 3 questions to complete.
