Chapter Eight Microprogrammed Control: Computer Architecture
Chapter Eight Microprogrammed Control: Computer Architecture
Chapter Eight Microprogrammed Control: Computer Architecture
CHAPTER EIGHT
MICROPROGRAMMED CONTROL
8.1. Introduction
In any digital computer, the function of the control unit is to initiate
sequences of microoperations. The number of different types of
microoperations that are available in a given system is finite.
External Control
input Next Control Control Control word
address address memory data
generator Register (ROM) Register
Next-address information
Figure 8.1
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 the
microoperations specified by the control word simultaneously with the
generation of the next microinstruction. This configuration requires a
two-phase clock, one clock applied to the address register and the
other to the data register.
The system can operate without the control data register by applying a
single-phase clock to the address register. The control word and next-
address information are taken directly from the control memory.
It must be realized that a ROM operates as a combinational circuit, with
the address value as the input and the corresponding word as the
output. The content of the specified word in ROM remains in the output
wires as long as its address value remains in the address register. No
read signal is needed as in a random-access memory. Each clock pulse
will execute the microoperations specified by the control word also
transfer a new address to the control address register.
In the example that follows we assume a single-phase clock and
therefore we do not use a control data register, in this way the address
register is the only component in the control system that receives clock
pulses. The other two components: the sequencer and the control
memory are combinational circuits and do not need a clock.
When the computer is turned on, an initial address is loaded into the
control address register. This address usually presents the first address
of the microinstruction that activates the instruction fetch routine. The
fetch routine may be sequenced by incrementing the control address
register through the rest of its microinstructions. At the end of the fetch
routine, the instruction is loaded in the instruction register.
The next step is to determine the effective address of the operand. The
effective address computation routine in control memory can be
reached through a branch microinstruction, which is conditioned on the
status of the mode bits of the instruction. When the effective address
computation routine is completed, the address of the operand is
available in the memory address register.
Figure 8.2
The diagram shows four different paths from which the control
address register (CAR) receives the address of the next
instruction.
Conditional Branching
The branch logic of Fig. 8.2 provides decision-making capabilities in
the control unit.
In every digital system, the status conditions are special bits that
provide parameter information such as:
The simplest way to implement the branch logic hardware is to test the
specified condition and branch to the indicated address if the
condition is met; otherwise, the address register is incremented.
Mapping of Instruction
A special type of branch exists when a microinstruction specifies a
branch to the first word in control memory where a microprogram
routine for an instruction is located. The status bits for this type of branch
are the bits in the operation code part of the instruction.
Figure 8.3
One simple mapping process that converts the 4-bit operation code to
a 7-bit address for control memory is shown in Fig. 8.3. This mapping
consists of placing a 0 in the most significant bit of the address,
transferring the four-operation code bits, and cleaning the two least
significant bits of the control address register.
Subroutines
Subroutines are programs that are used by other routine to
accomplish a particular task.
A subroutine can be called from any point within the main body of
the microprogram.
Computer Configuration
To explain the microprogramming process, we present a simple
digital computer similar but not identical to the basic computer
introduced in chapter 6.
Figure 8.4
Instruction Format
Figure 8.5 presents the instruction format for the assumed computer.
Figure 8.5