0% found this document useful (0 votes)
6 views

7 Control Unit and ALU (1)-1

The document discusses two types of control organization in digital computers: hardwired control and microprogrammed control. Hardwired control uses physical circuits for fast operation but is difficult to modify, while microprogrammed control utilizes stored programs for flexibility and easier updates. Additionally, it outlines the functions of the control unit and the arithmetic and logic unit (ALU) in executing operations and managing data flow within the computer system.

Uploaded by

mikezeh468
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
6 views

7 Control Unit and ALU (1)-1

The document discusses two types of control organization in digital computers: hardwired control and microprogrammed control. Hardwired control uses physical circuits for fast operation but is difficult to modify, while microprogrammed control utilizes stored programs for flexibility and easier updates. Additionally, it outlines the functions of the control unit and the arithmetic and logic unit (ALU) in executing operations and managing data flow within the computer system.

Uploaded by

mikezeh468
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 5

Control Unit

There are two major types of control organization: hardwired control and microprogrammed
control. In hardwired organization, the control logic is implemented with gates, flip-flops,
decoders, and other digital circuits. It has the advantage that it can be optimized to produce a
fast mode of operation.
In microprogrammed organization, the control information is stored in a control memory. The
control memory is programmed to initiate the required sequence of micro-operations. A
hardwired control, as the name implies, requires changes in the wiring among the various
components if the design has to be modified or change. In microprogrammed control, any
required changes or modifications can be done by updating the microprogram in control
memory.
The function of control unit in a digital computer is to initiate sequences of micro-operations.
Micro-operations are series of sequential steps initiates by control unit. The number of different
types of micro-operations that are available in a given system is infinite. The complexity of
the digital system is derived from the number of sequences of micro-operations that are
performed. When the control signals are generated by hardware using conventional logic design
techniques, the control unit is said to be hardwired. Micro-programming is the second
alternatives for designing the control unit of a digital computer. The principle of
microprogramming is an elegant and systematic method for controlling the micro-operation
sequences in a digital computer.

The control function / variable that specifies a micro-operation is a binary variable. When it is
in “1” binary state, the corresponding micro-operation is executed. The active state of a control
variable may be either “1” state or “0” state depending on the application. In a bus organized
system, the control signals that specify micro-operations are groups of bits that select the paths in
multiplexers, decoders, and arithmetic logic units.

The control variable at any given time can be represented by a string of 1’s and 0’s called a
control word. As such, control words can be programmed to perform various operations on the
components of the system.

Hardwired Control: Hardwired Control is implemented as logic circuits (gates, flip-flops,


decoders etc) in the hardware. The organization is very complicated if we have a large control
unit. In this organization, if the design has to be modified or changed, requires changes in the
wiring among the various components. Thus, the modification of all the combinational circuits
may be very difficult.
DIAGRAM

}
}

}
Figure 1: Hardwired Control Organization

Advantages
i. Hardwired Control Unit is very fast because control signals are generated by
combinational circuits.
ii. The delay in generation of control signals depend upon the number of gates.
iii. Hardwired control units are known to be more power efficient than counterparts
making them an ideal choice for processors in mobile devices.

Disadvantages
i. The more is the control signals require by CPU, the more complex the design of
the control unit.
ii. Modifications of control signal are very difficult, that means it requires
rearranging of all wires in the hardware circuit.
iii. It is difficult to correct mistake in original design or adding new features in the
existing design of control unit

Micro-programmed Control: Micro-programmed Control unit is implemented using


programming approach. A sequence of micro-operation is carried out by executing a program
consisting of micro-instructions. Micro-program consisting of micro-instructions is stored in the
control memory of the control unit. Execution of a micro-instruction is responsible for generation
of a set of control signals. These programs are called micro-programs.
A control unit whose binary control variables are stored in the memory is called a
microprogrammed control unit. Each word in a control memory contains within is a micro-
instruction. The microinstruction specifies one or more micro-operations for the system. A
sequence of micro-instructions constitutes a microprogram. Since alterations of the
microprogram are not needed once the control unit is in operation, the memory can be read-
only memory (ROM). The content of the words in ROM are fixed are cannot be altered by
simple programming since no writing capability is available in the ROM. ROM words are made
permanent during hardware production of the unit. The use of a microprogram involves placing
all control variables in words of ROM for use by the control unit through successive operations.
The content of the word in ROM at a given address specifies a micro-instruction.

A computer that employs a micro-programmed control unit will have two separate memories: a
main memory and control memory. The main memory is available to the user for storing the
programs. The contents of the main memory may alter when the data are manipulated and every
time the program is changed. The users’ program in main memory consists of machine
instructions and data. In contrast, the control memory holds a fixed microprogram hat cannot be
altered by the occasional user.
The general configuration of a microprogrammed control unit is demonstrated in the block
diagram of fig. 2. The control memory is assumed to be a ROM, within which control
information is permanently stored.

DIAGRAM

Figure 2: Architecture of a Micro-programmed control

The control memory address specifies the address of the microinstruction, and the control data
register holds the microinstruction read from memory. The microinstruction contains a control
word hat specifies one or more micro-operations for the data processor. Once these operations
are executed, the control must determine the next address. The location of the next micro-
instruction may be the next in sequence, or it may be located somewhere else in the control
memory. The next address may also be a function of external input conditions. While the micro-
operations are being executed, the next address is computed in the next address generator circuit
and then transferred into the control address register to read the next microinstruction. Thus a
microinstruction contains bits for initiating micro-operations in the data processor part and bits
that determine the address sequence for the control memory.
The next address generator is sometimes called a microprogram sequencer, as it determines the
address sequence that is read from control memory. The control data register holds the present
microinstruction while the next address is computed and read from memory. The data register is
sometimes called a pipeline register. It allows the execution of micro-operations specified by the
control word simultaneously with the generation of the next microinstruction.

Advantages
i. The design of micro-program control unit is less complex because micro-
programs are implemented using software routines.
ii. The micro-program control unit is more flexible because design modification,
correction and enhancement are easily possible.
iii. The new or modified instruction set of CPU can be easily implemented by simply
rewriting or modifying the contents of control memory.
iv. The faults can be easily diagnosed in the micro-program control unit using
diagnostics tools by maintaining the contents of flags, registers and counters.

Disadvantages
i. The Micro-programmed Control unit is slower than hardwired control unit which
means that to execute an instruction in micro-program control unit requires more
time.
ii. The Micro-programmed Control unit is expensive than hardwire control unit in
case of limited hardware resources.
iii. The design duration of Micro-programmed Control unit is more than hardwired
control unit for smaller CPU.

Arithmetic and Logic Unit


The arithmetic and logic unit perform arithmetic and logic operations in any computer system.
The instructions such as addition, subtraction, increment, and decrement are executed by
arithmetic while the logical unit performs various logical operations with the content of the
accumulator

The arithmetic operations are:


i. Addition: Any 8-bit number, or the contents of a register or the contents of a
memory location can be added to the contents of the accumulator and the sum is
stored in the accumulator.

ii. Subtraction: Any 8-bit number, or the contents of a register or the contents of a
memory location can be subtracted from the contents of the accumulator and the
results stored in the accumulator. The subtraction is performed in 2’s compliment
and the results if negative are expressed in 2’s compliment.

iii. Increment / Decrement: The 8-bit contents of a register or memory location can
be incremented or decremented by 1. Similarly, the 16-bit contents of a register
pair (such as BC) can be incremented of decremented by 1. These incremented /
decremented operations differ from addition and subtraction in an important way
that is, they can be performed in any one of the registers or in a memory location.

The Logical Operation are:


i. AND, OR, Exclusive-OR: Any 8-bit number, or the contents of a register, or of
a number location can be logically ANDed, Ored, or Exlusive-ORed with the
contents of the accumulator. The results are stored in the accumulator.

ii. Rotate: Each bit in the accumulator can be shifted either left or right to the next

iii. Compare: Any 8-bit number or the contents of a register, or a memory location
can be compared for quality, greater than. Or less than, with the contents of the
accumulator.

iv. Complement: the contents of the accumulator can be complemented. All 0’s are
replaced by 1’s and all 1’s are replaced by 0’s.

Functions of control unit


i. Decode the binary machine word in the IR (Instruction Register) and issue appropriate
control signals for its execution.
ii. Generate relevant timing and control signals to all operations in the computer.
iii. Controls the flow of data between the processor and memory and peripheral.
iv. Direct the entire computer system to carry out stored program instructions
v. Communicate with both the arithmetic logic unit (ALU) and main memory
vi. Instruct the arithmetic logic unit that which logical or arithmetic operation is to be
performed
vii. Co-ordinate the activities of the other two units as well as all peripherals and auxiliary
storage devices linked to the computer

NB; Read about Microcontroller and 8085 microprocessor, draw the IC, take note of the
functions of the pins, the relevant features and applications

You might also like