micro-programmed control (kontroltermikroprogram) · 2010. 6. 8. · microsoft powerpoint -...

38
Organisasi Komputer II Micro-programmed Control (Kontrol Termikroprogram)

Upload: others

Post on 31-Oct-2020

38 views

Category:

Documents


2 download

TRANSCRIPT

Page 1: Micro-programmed Control (KontrolTermikroprogram) · 2010. 6. 8. · Microsoft PowerPoint - ORKOM-II-8 Author: Ajeng Created Date: 6/8/2010 11:15:16 AM

Organisasi Komputer I I

Micro-programmed Control

(Kontrol Termikroprogram)

Page 2: Micro-programmed Control (KontrolTermikroprogram) · 2010. 6. 8. · Microsoft PowerPoint - ORKOM-II-8 Author: Ajeng Created Date: 6/8/2010 11:15:16 AM

Organisasi Unit Kontrol

Page 3: Micro-programmed Control (KontrolTermikroprogram) · 2010. 6. 8. · Microsoft PowerPoint - ORKOM-II-8 Author: Ajeng Created Date: 6/8/2010 11:15:16 AM

Micro-programmed Control

Use sequences of instructions (see earlier notes) to control complex operationsCalled micro-programming or firmware

Page 4: Micro-programmed Control (KontrolTermikroprogram) · 2010. 6. 8. · Microsoft PowerPoint - ORKOM-II-8 Author: Ajeng Created Date: 6/8/2010 11:15:16 AM

CONTROL UNIT MICROPROGRAMMED

Terbagi 2 yaitu :1. Control Vertikal

Jenis implementasi dimana signal kontrol di kode ke dalam pada bit , kemudian digunakan setelah dikode.

2. Control HorizontalControl dimana setiap bit kontrol mengatur 1 operasi gate ataumesin.

Page 5: Micro-programmed Control (KontrolTermikroprogram) · 2010. 6. 8. · Microsoft PowerPoint - ORKOM-II-8 Author: Ajeng Created Date: 6/8/2010 11:15:16 AM

KOMPONEN-KOMPONEN POKOK CONTROL UNIT

MICROPROGRAMMED

1. Instruction Register Menyimpan instruksi register mesin yang dijalankan.

2. Control Store berisi microprogrammedUntuk semua instruksi mesin.Untuk startup mesin.Untuk memprosesan interupt

3. Address Computing CircuitingMenentukan alamat Control Store dari mikroinstruksiberikutnya yang akan dijalankan.

Page 6: Micro-programmed Control (KontrolTermikroprogram) · 2010. 6. 8. · Microsoft PowerPoint - ORKOM-II-8 Author: Ajeng Created Date: 6/8/2010 11:15:16 AM

4. Microprogrammed CounterMenyimpan alamat dari mikroinstruksi berikutnya.

5. Microinstruction BufferMenyimpan mikroinstruksi tersebut selama dieksekusi.

6. Microinstruction DecoderMenghasilkan dan mengeluarkan mikroorder yang didasarkan pada mikroinstruksi dan opcode instruksiyang akan dijalankan

Page 7: Micro-programmed Control (KontrolTermikroprogram) · 2010. 6. 8. · Microsoft PowerPoint - ORKOM-II-8 Author: Ajeng Created Date: 6/8/2010 11:15:16 AM

Implementat ion (1)

All the control unit does is generate a set of control signalsEach control signal is on or offRepresent each control signal by a bitHave a control word for each micro-operationHave a sequence of control words for each machine code instructionAdd an address to specify the next micro-instruction, depending on conditions

Page 8: Micro-programmed Control (KontrolTermikroprogram) · 2010. 6. 8. · Microsoft PowerPoint - ORKOM-II-8 Author: Ajeng Created Date: 6/8/2010 11:15:16 AM

Implementat ion (2)

Today s large microprocessorMany instructions and associated register-level hardwareMany control points to be manipulated

This results in control memory thatContains a large number of words

co-responding to the number of instructions to be executed

Has a wide word width Due to the large number of control points to be manipulated

Page 9: Micro-programmed Control (KontrolTermikroprogram) · 2010. 6. 8. · Microsoft PowerPoint - ORKOM-II-8 Author: Ajeng Created Date: 6/8/2010 11:15:16 AM

Micro-program Word Length

Based on 3 factorsMaximum number of simultaneous micro-operations supportedThe way control information is represented or encodedThe way in which the next micro-instruction address is specified

Page 10: Micro-programmed Control (KontrolTermikroprogram) · 2010. 6. 8. · Microsoft PowerPoint - ORKOM-II-8 Author: Ajeng Created Date: 6/8/2010 11:15:16 AM

Micro-instruct ion Types

Each micro-instruction specifies single (or few) micro-operations to be performed

(vertical micro-programming)

Each micro-instruction specifies many different micro-operations to be performed in parallel

(horizontal micro-programming)

Page 11: Micro-programmed Control (KontrolTermikroprogram) · 2010. 6. 8. · Microsoft PowerPoint - ORKOM-II-8 Author: Ajeng Created Date: 6/8/2010 11:15:16 AM

Vert ical Micro-programming

Width is narrown control signals encoded into log2 n bitsLimited ability to express parallelismConsiderable encoding of control information requires external memory word decoder to identify the exact control line being manipulated

Page 12: Micro-programmed Control (KontrolTermikroprogram) · 2010. 6. 8. · Microsoft PowerPoint - ORKOM-II-8 Author: Ajeng Created Date: 6/8/2010 11:15:16 AM

Horizontal Micro-programming

Wide memory wordHigh degree of parallel operations possibleLittle encoding of control information

Page 13: Micro-programmed Control (KontrolTermikroprogram) · 2010. 6. 8. · Microsoft PowerPoint - ORKOM-II-8 Author: Ajeng Created Date: 6/8/2010 11:15:16 AM

Typical Microinstruct ion Formats

Page 14: Micro-programmed Control (KontrolTermikroprogram) · 2010. 6. 8. · Microsoft PowerPoint - ORKOM-II-8 Author: Ajeng Created Date: 6/8/2010 11:15:16 AM

Compromise

Divide control signals into disjoint groupsImplement each group as separate field in memory wordSupports reasonable levels of parallelism without too much complexity

Page 15: Micro-programmed Control (KontrolTermikroprogram) · 2010. 6. 8. · Microsoft PowerPoint - ORKOM-II-8 Author: Ajeng Created Date: 6/8/2010 11:15:16 AM

Organizat ion ofControl Memory

Page 16: Micro-programmed Control (KontrolTermikroprogram) · 2010. 6. 8. · Microsoft PowerPoint - ORKOM-II-8 Author: Ajeng Created Date: 6/8/2010 11:15:16 AM

Control Unit

Page 17: Micro-programmed Control (KontrolTermikroprogram) · 2010. 6. 8. · Microsoft PowerPoint - ORKOM-II-8 Author: Ajeng Created Date: 6/8/2010 11:15:16 AM

Control Unit Funct ion

Sequence login unit issues read commandWord specified in control address register is read into control buffer registerControl buffer register contents generates control signals and next address informationSequence login loads new address into control buffer register based on next address information from control buffer register and ALU flags

Page 18: Micro-programmed Control (KontrolTermikroprogram) · 2010. 6. 8. · Microsoft PowerPoint - ORKOM-II-8 Author: Ajeng Created Date: 6/8/2010 11:15:16 AM

Next Address Decision

Depending on ALU flags and control buffer register

Get next instructionAdd 1 to control address register

Jump to new routine based on jump microinstructionLoad address field of control buffer register into control address register

Jump to machine instruction routineLoad control address register based on opcode in IR

Page 19: Micro-programmed Control (KontrolTermikroprogram) · 2010. 6. 8. · Microsoft PowerPoint - ORKOM-II-8 Author: Ajeng Created Date: 6/8/2010 11:15:16 AM

Functioning of MicroprogrammedControl Unit

Page 20: Micro-programmed Control (KontrolTermikroprogram) · 2010. 6. 8. · Microsoft PowerPoint - ORKOM-II-8 Author: Ajeng Created Date: 6/8/2010 11:15:16 AM

Wilkes Control

1951Matrix partially filled with diodesDuring cycle, one row activated

Generates signals where diode presentFirst part of row generates controlSecond generates address for next cycle

Page 21: Micro-programmed Control (KontrolTermikroprogram) · 2010. 6. 8. · Microsoft PowerPoint - ORKOM-II-8 Author: Ajeng Created Date: 6/8/2010 11:15:16 AM

Wilkes's Microprogrammed Control Unit

Page 22: Micro-programmed Control (KontrolTermikroprogram) · 2010. 6. 8. · Microsoft PowerPoint - ORKOM-II-8 Author: Ajeng Created Date: 6/8/2010 11:15:16 AM

Advantages and Disadvantages of Microprogramming

Simplifies design of control unitCheaperLess error-prone

Slower

Page 23: Micro-programmed Control (KontrolTermikroprogram) · 2010. 6. 8. · Microsoft PowerPoint - ORKOM-II-8 Author: Ajeng Created Date: 6/8/2010 11:15:16 AM

Tasks Done By MicroprogrammedControl Unit

Microinstruction sequencingMicroinstruction executionMust consider both together

Page 24: Micro-programmed Control (KontrolTermikroprogram) · 2010. 6. 8. · Microsoft PowerPoint - ORKOM-II-8 Author: Ajeng Created Date: 6/8/2010 11:15:16 AM

Design Considerat ions

Size of microinstructionsAddress generation time

Determined by instruction registerOnce per cycle, after instruction is fetched

Next sequential addressCommon in most designed

BranchesBoth conditional and unconditional

Page 25: Micro-programmed Control (KontrolTermikroprogram) · 2010. 6. 8. · Microsoft PowerPoint - ORKOM-II-8 Author: Ajeng Created Date: 6/8/2010 11:15:16 AM

Sequencing Techniques

Based on current microinstruction, condition flags, contents of IR, control memory address must be generatedBased on format of address information

Two address fieldsSingle address fieldVariable format

Page 26: Micro-programmed Control (KontrolTermikroprogram) · 2010. 6. 8. · Microsoft PowerPoint - ORKOM-II-8 Author: Ajeng Created Date: 6/8/2010 11:15:16 AM

Branch Control Logic: Tw o Address Fields

Page 27: Micro-programmed Control (KontrolTermikroprogram) · 2010. 6. 8. · Microsoft PowerPoint - ORKOM-II-8 Author: Ajeng Created Date: 6/8/2010 11:15:16 AM

Branch ControlLogic: Single Address Field

Page 28: Micro-programmed Control (KontrolTermikroprogram) · 2010. 6. 8. · Microsoft PowerPoint - ORKOM-II-8 Author: Ajeng Created Date: 6/8/2010 11:15:16 AM

Branch Control Logic: Variable Format

Page 29: Micro-programmed Control (KontrolTermikroprogram) · 2010. 6. 8. · Microsoft PowerPoint - ORKOM-II-8 Author: Ajeng Created Date: 6/8/2010 11:15:16 AM

Address Generat ion

Residual controlConditional branch

AdditionUnconditional Branch

MappingTwo-field

ImplicitExplicit

Page 30: Micro-programmed Control (KontrolTermikroprogram) · 2010. 6. 8. · Microsoft PowerPoint - ORKOM-II-8 Author: Ajeng Created Date: 6/8/2010 11:15:16 AM

Execution

The cycle is the basic eventEach cycle is made up of two events

FetchDetermined by generation of microinstruction address

Execute

Page 31: Micro-programmed Control (KontrolTermikroprogram) · 2010. 6. 8. · Microsoft PowerPoint - ORKOM-II-8 Author: Ajeng Created Date: 6/8/2010 11:15:16 AM

Execute

Effect is to generate control signalsSome control points internal to processorRest go to external control bus or other interface

Page 32: Micro-programmed Control (KontrolTermikroprogram) · 2010. 6. 8. · Microsoft PowerPoint - ORKOM-II-8 Author: Ajeng Created Date: 6/8/2010 11:15:16 AM

Control Unit Organizat ion

Page 33: Micro-programmed Control (KontrolTermikroprogram) · 2010. 6. 8. · Microsoft PowerPoint - ORKOM-II-8 Author: Ajeng Created Date: 6/8/2010 11:15:16 AM

A Taxonomy of Microinstruct ions

Vertical/horizontalPacked/unpackedHard/soft microprogrammingDirect/indirect encoding

Page 34: Micro-programmed Control (KontrolTermikroprogram) · 2010. 6. 8. · Microsoft PowerPoint - ORKOM-II-8 Author: Ajeng Created Date: 6/8/2010 11:15:16 AM

Improvements over Wilkes

Wilkes had each bit directly produced a control signal or directly produced one bit of next addressMore complex address sequencing schemes,using fewer microinstruction bits, are possibleRequire more complex sequencing logic moduleControl word bits can be saved by encoding and subsequently decoding control information

Page 35: Micro-programmed Control (KontrolTermikroprogram) · 2010. 6. 8. · Microsoft PowerPoint - ORKOM-II-8 Author: Ajeng Created Date: 6/8/2010 11:15:16 AM

How to EncodeK different internal and external control signals Wilkes s:

K bits dedicated 2K control signals during any instruction cycle

Not all usedTwo sources cannot be gated to same destinationRegister cannot be source and destinationOnly one pattern presented to ALU at a timeOnly one pattern presented to external control bus at a time

Require Q < 2K which can be encoded with log2Q < K bitsNot done

As difficult to program as pure decoded (Wilkes) schemeRequires complex slow control logic module

CompromisesMore bits than necessary usedSome combinations that are physically allowable are not possible to encode

Page 36: Micro-programmed Control (KontrolTermikroprogram) · 2010. 6. 8. · Microsoft PowerPoint - ORKOM-II-8 Author: Ajeng Created Date: 6/8/2010 11:15:16 AM

Specific Encoding Techniques

Microinstruction organized as set of fieldsEach field contains codeActivates one or more control signalsOrganize format into independent fields

Field depicts set of actions (pattern of control signals) Actions from different fields can occur simultaneously

Alternative actions that can be specified by a field are mutually exclusive

Only one action specified for field could occur at a time

Page 37: Micro-programmed Control (KontrolTermikroprogram) · 2010. 6. 8. · Microsoft PowerPoint - ORKOM-II-8 Author: Ajeng Created Date: 6/8/2010 11:15:16 AM

Microinstruct ion EncodingDirect Encoding

Page 38: Micro-programmed Control (KontrolTermikroprogram) · 2010. 6. 8. · Microsoft PowerPoint - ORKOM-II-8 Author: Ajeng Created Date: 6/8/2010 11:15:16 AM

Microinstruct ion EncodingIndirect Encoding