Header Ads Widget

Horizontal and Vertical Microprogramming

Basically, control unit (CU) is the engine that runs the entire functions of a computer with the help of control signals in the proper sequence. In the micro-programmed control unit approach, the control signals that are associated with the operations are stored in special memory units. It is convenient to think of sets of control signals that cause specific micro-operations to occur as being “microinstructions”. The sequences of microinstructions could be stored in an internal “control” memory.

Micro-programmed control unit can be classified into two types based on the type of Control Word stored in the Control Memory, viz., Horizontal micro-programmed control unit and Vertical micro-programmed control unit.

  • In Horizontal micro-programmed control unit, the control signals are represented in the decoded binary format, i.e., 1 bit/CS. Here ‘n’ control signals require n bit encoding. On the other hand.
  • In Vertical micro-programmed control unit, the control signals are represented in the encoded binary format. Here ‘n’ control signals require log2n bit encoding.

Comparison between Horizontal micro-programmed control unit and Vertical micro-programmed control unit:

Horizontal µ-programmed CU

Vertical µ-programmed CU

It supports longer control word.

It supports shorter control word.

It allows higher degree of parallelism. If degree is n, then n Control Signals are enabled at a time.

It allows low degree of parallelism i.e., degree of parallelism is either 0 or 1.

No additional hardware is required.

Additional hardware in the form of decoders are required to generate control signals.

It is faster than Vertical micro-programmed control unit.

it is slower than Horizontal micro-programmed control unit.

It is less flexible than Vertical micro-programmed control unit.

It is more flexible than Horizontal micro-programmed control unit.

Horizontal micro-programmed control unit uses horizontal microinstruction, where every bit in the control field attaches to a control line.

Vertical micro-programmed control unit uses vertical microinstruction, where a code is used for each action to be performedand thedecoder translates this code into individual control signals.

Horizontal micro-programmed control unit makes less use of ROM encoding than vertical micro-programmed control unit.

Vertical micro-programmed control unit makes more use of ROM encoding to reduce the length of the control word.

Example: Consider a hypothetical Control Unit which supports 4 k words. The Hardware contains 64 control signals and 16 Flags. What is the size of control word used in bits and control memory in byte using:

a) Horizontal Programming
b) Vertical programming

Solution:


a)For Horizontal 

64 bits for 64 signals
Control Word Size = 4 + 64 + 12 = 80 bits

Control Memory = 4 kW = ( (4* 80) / 8 ) = 40 kByte


a)For Vertical
6 bits for 64 signals i.e log264

Control Word Size = 4 + 6 + 12 = 22 bits

Control Memory = 4 kW = ( (4* 22) / 8 ) = 11 kByte


Ques 27 Briefly define the following terms:

1.    Micro-operation

2.    Micro-instruction

3.    Micro-program

4.    Micro-code

5.    Control Memory

AKTU 2015-16,Marks 10

Answer:

1.Micro-operation:

The operations executed on data stored in registers are called micro-operations. A micro-operation is an elementary operation performed on the information stored in one or more registers.

Example: Shift, count, clear and load.

2.Micro-instruction:

A computer instruction that activates the circuits necessary to perform a single machine operation usually as part of the execution of a machine-language instruction.

 

3.Micro-program:

A computer program that consists only of basic elemental commands which directly control the operation of each functional element in a microprocessor.

 

4.Micro-code:

Microcode is a computer hardware technique that interposes a layer of organisation between the CPU hardware and the programmer-visible instruction set architecture of the computer.It also facilitates the building of complex multi-step instructions, while reducing the complexity of computer circuits.

 

5.Control Memory:

Control memory is a type of RAM (Random Access Memory) which contains addressable storage registers.Data is temporarily stored in control memory. Control memory can be accessed quicker than main memory which speeds up CPU (Central Processing Unit) operations. 

 

Ques. Write an assembly level program for the following pseudo code:

SUM=0

SUM=SUM+A+B

DIF=DIF - C

SUM=SUM+DIF

AKTU 2016-17,Marks 10

Answer:

 

 

Ques. Explain 4-bit incrementer with a necessary diagram

AKTU 2016-17,Marks 15

Answer:

4-bit incrementer:

1.    A logic-1 is applied to one of the inputs of least significant half-adder, and the other input is connected to the least significant bit of the number to be incremented.

2.    The output carry from one half-adder is connected to one of the inputs of the next-higher-order half-adder.

3.    The binary incrementer circuit receives the four bits from A0 through A3, adds one to it, and generates the incremented output in S0 through S3.

4.    The output carry C4 will be 1 only after incrementing binary 1111.

 

 

Ques. Write a program loop using a pointer and a counter to clear the contents of hex locations 500 to 5FF with 0.

AKTU 2016-17,Marks 15

Answer:

 

 

 

Ques. Demonstrate the process of second pass of assembler using a suitable diagram.

Answer:

Second Pass of assembler:

During the second pass, the assembler examines the operands for symbolic references to storage locations and resolves these symbolic references using information in the symbol table.

On the second pass, the assembler:

●     Examines the operands for symbolic references to storage locations and resolves these symbolic references using information in the symbol table.

●     Ensures that no instructions contain an invalid instruction form.

●     Translates source statements into machine code and constants, thus filling the allocated space with object code.

●     Produces a file containing error messages, if any have occurred.

At the beginning of the second pass, the assembler scans each source statement a second time. As the assembler translates each instruction, it increments the value contained in the location counter.



Post a Comment

0 Comments