Uploaded by Muhammad Zeeshan Haider Ali

Control unit and microprograming

advertisement
Computer Architecture and
Organization (CS-507)
Lecture 12
Control Unit and Instruction Set
ARM And SRC Machines
Important Points
The execution of an instruction involves the execution of a sequence
of substeps, generally called cycles. For example, an execution may
consist of fetch, indirect, execute, and interrupt cycles.
Each cycle is in turn made up of a sequence of more fundamental
operations, called micro-operations.
A single micro-operation generally involves a transfer between
registers, a transfer between a register and an external bus, or a
simple ALU operation.
The control unit of a processor performs two tasks: (1) It causes the
processor to step through a series of micro-operations in the proper
sequence, based on the program being executed, and (2) it
generates the control signals that cause each micro-operation to be
executed.
Continue…
The control signals generated by the control unit cause the
opening and closing of logic gates, resulting in the transfer of
data to and from registers and the operation of the ALU.
Two techniques for implementing a control unit are referred to
as hardwired control unit and microprogrammed control unit
Hardwired implementation, in which the control unit is a
combinatorial circuit. Its input logic signals, governed by the
current machine instruction, are transferred into a set of output
control signals.
Important Terminologies
Microprogram
Program stored in memory that generates all the control
signals required to execute the instruction set correctly
Consists of microinstructions
Microinstruction
Contains a control word and a sequencing word
Control Word - All the control information required for one
clock cycle
Sequencing Word - Information needed to decide the next
microinstruction address
Vocabulary to write a microprogram
Continue…
Control Memory(Control Storage: CS)
Storage in the microprogrammed control unit to store
the microprogram
Writeable Control Memory(Writeable Control Storage:WCS)
CS whose contents can be modified
Allows the microprogram can be changed
Instruction set can be changed or modified
Micro Operation:
Micro-operations are the functional, or atomic, operations of a
processor. The execution of each subcycle involves one or more
shorter operations, that is, micro-operations.
Continue…
Dynamic Microprogramming
Computer system whose control unit is implemented with a
microprogram. Microprogram can be changed by a systems
programmer or a user
Functional elements of the processor
ALU, Registers, Internal data paths, External data paths, Control unit
The ALU is the functional essence of the computer. Registers are used to
store data internal to the processor. Some registers contain status
information needed to manage instruction sequencing (e.g., a program
status word). Others contain data that go to or come from the ALU,
memory, and I/O modules.
Internal data paths are used to move data between registers and between
register and ALU.
External data paths link registers to memory and I/O modules, often by
means of a system bus.
The control unit performs two basic tasks:
Sequencing: The control unit causes the processor to step through a
series of micro-operations in the proper sequence, based on the program
being executed.
Execution: The control unit causes each micro-operation to be
performed.
Controller Function
Fetch and instruction sequencing (fetch cycle)-Generates
control signal to fetch instruction from memory and the
sequence of operations involved in processing an instruction
Instruction interpretation and execution (execution cycle)Tasks involved are
 Interpreting
the operand addressing mode implied in the
operation code and fetching the operands
 Sequencing
the successive micro operations on the data
path to execute the operation code specified in the
instruction
Continue…
Interrupt processing (interrupt cycle)-Process interrupt.
Tasks are
 Suspend
 Save
 Set
execution of current program
context
PC to start address of interrupt handler routine
 Process
interrupt
 Restore
context and continue interrupted program
Block Diagram of the Control Unit
Continue…
The inputs are
Clock: This is how the control unit “keeps time.” The control unit causes one
micro-operation (or a set of simultaneous micro-operations) to be performed for
each clock pulse. This is sometimes referred to as the processor cycle time, or
the clock cycle time.
Instruction register: The opcode and addressing mode of the current instruction
are used to determine which micro-operations to perform during the execute
cycle.
Flags: These are needed by the control unit to determine the status of the
processor and the outcome of previous ALU operations. For example, for the
increment-and-skip-if-zero (ISZ) instruction, the control unit will increment the PC
if the zero flag is set.
Control signals from control bus: The control bus portion of the system bus
provides signals to the control unit.
Continue…
The outputs are as follows:
Control signals within the processor: These are two types: those
that cause data to be moved from one register to another, and those
that activate specific ALU functions.
Control signals to control bus: These are also of two types: control
signals to memory, and control signals to the I/O modules.
Embedded Systems
ARM
• ARM evolved from RISC design
• Used mainly in embedded systems
•
•
•
•
Used within product
Not general purpose computer
Dedicated function
E.g. Anti-lock brakes in car
Embedded Systems Requirements
• Different sizes
• Different constraints, optimization, reuse
• Different requirements
•
•
•
•
•
•
•
Safety, reliability, real-time, flexibility, legislation
Lifespan
Environmental conditions
Static v dynamic loads
Slow to fast speeds
Computation v I/O intensive
Descrete event v continuous dynamics
Possible Organization of an Embedded System
ARM Evolution
• Designed by ARM Inc., Cambridge, England
• Licensed to manufacturers
• High speed, small die, low power consumption
• PDAs, hand held games, phones
• E.g. iPod, iPhone
• Acorn produced ARM1 & ARM2 in 1985 and ARM3 in 1989
• Acorn, VLSI and Apple Computer founded ARM Ltd.
ARM Systems Categories
• Embedded real time
• Application platform
• Linux, Palm OS, Symbian OS, Windows mobile
• Secure applications
Simple Risc Computers
SRC.
• SRC Computers, designs and manufactures general-purpose reconfigurable
computing systems. It offers data center solutions, scalable systems and
servers, rack mountable computing products, airborne/portable/ground
station processing solutions, GPIOX cards and test boards, workstations, and
embedded systems. The company’s systems are used by business leaders,
researchers, and innovators in the areas of business intelligence, data
analytics, defense, communications, signal processing, scientific research,
molecular dynamics, biometrics, quantitative finance, real-time sensor
processing, synthetic aperture radar processing, Web infrastructure, high
speed textual search, energy exploration and development, seismic
processing, intelligence, bio-informatics, image processing, medical research,
and geospatial mapping. It serves financial services, energy, unmanned aerial
vehicles,
defense,
aerospace,
intelligence,
homeland
security,
healthcare/medical imaging, and commercial and enterprise markets, as well
as universities and scientific research institutions.
Download