Control Unit Implementation

Size: px
Start display at page:

Download "Control Unit Implementation"

Transcription

1 Control Unit Implementation

2 Moore Machine Implementation Reset RES PC IF PC MAR, PC + PC Note capture of MBR in these states IF Wait/ IF2 Wait/ Wait/ MAR Mem, Read/Write, Request, Mem MBR Wait/ IF3 Wait/ MBR IR ID Wait/ LD LD Wait/ Wait/ = = IR MAR ST IR MAR, AC MBR MAR Mem, Wait/ MAR Mem, Read/Write, ST Read/Write, Request, Request, Mem MBR Wait/ MBR Mem = AD AD Wait/ Wait/ = IR MAR MAR Mem, Read/Write, Request, Mem MBR BR = BR = IR PC LD2 MBR AC AD2 MBR + AC AC

3 Moore Machine Implementation Memory-Register Interface Timing IF IF2 IF2 IF2 IF3 CLK WAIT Mem Bus Data Valid Latch MBR Invalid Data Latched Invalid Data Latched Valid Data Latched Valid data latched on IF2 to IF3 transition because data must be valid before Wait can go low

4 Moore Machine Implementation Reset Wait IR<5> IR<4> AC<5> Next State Logic 6 states, 4 bit state register Next State Logic: 9 Inputs, 4 Outputs Output Logic: 4 Inputs, 7 Outputs Clock State Output Logic These can be implemented via ROM or PAL/PLA Next State: 52 x 4 bit ROM Output: 6 x 7 bit ROM Read/Write Request PC PC + PC PC ABUS IR ABUS ABUS MAR ABUS PC MAR Memory Address Bus Memory Data Bus MBR MBR Memory Data Bus MBUS IR RBUS AC RBUS MBR ALU ADD ALU PASS A ALU PASS B

5 Moore Machine Implementation Next State Table Reset Wait IR<5> IR<4> AC<5> Current State Next State X X X X X RES () Register Transfer Ops X X X X RES () IF () > PC X X X X IF () IF () X X X IF () IF () X X X IF () IF2 () X X X IF2 () IF2 () X X X IF2 () IF3 () X X X IF3 () IF3 () X X X IF3 () OD () X X OD () LD () X X OD () ST () X X OD () AD () X X OD () BR () PC > MAR, PC + > PC MAR > Mem,, Read, Request, Mem > MBR MBR > IR

6 Moore Machine Implementation Reset Wait IR<5> IR<4> AC<5> Current State Next State Register Transfer Ops X X X X LD () LD () X X X LD () LD () X X X LD () LD2 () X X X X LD2 () IF () X X X X ST () ST () X X X ST () ST () X X X ST () IF () X X X X AD () AD () X X X AD () AD () X X X AD () AD2 () X X X X AD2 () IF () IR > MAR MAR > Mem,, Read, Request, Mem > MBR MBR > AC IR > MAR, AC > MBR MAR > Mem,, Write, Request, MBR > Mem IR > MAR MAR > Mem,, Read, Request, Mem > MBR MBR + AC > AC X X X BR () IF () X X X BR () BR () X X X X BR () IF () IR > PC

7 Moore Machine Implementation State Table Observations: Extensive use of Don't Cares ROM-based implementations cannot take advantage of don't cares However, ROM-based implementation can skip state assignment step Inputs used only in a small number of states e.g., AC<5> examined only in BR state IR<5:4> examined only in ID state Some outputs always asserted in a group

8 Synchronous Mealy Machine Implementation Standard Mealy Machine has asynchronous outputs These change in response to input changes, independent of clock Revise Mealy Machine design so outputs change only on clock edges Synchronizer Circuitry at at Inputs Inputs and and Outputs A D Q A' ƒ D Q ƒ' Output Logic STATE A STATE A STATE A' ƒ D Q Output Logic ƒ D Q ƒ' Output Logic

9 Synchronous Mealy Machine Implementation Case I: Synchronizers at Inputs and Outputs CLK A A' cycle cycle cycle 2 S S A/ƒ ƒ ƒ' S2 A asserted in Cycle, f f becomes asserted after 2 cycle delay! This is clearly overkill!

10 Synchronous Mealy Machine Implementation Case II: Synchronizers on Inputs CLK cycle cycle cycle 2 S A/ƒ S A S S A' A'/ƒ ƒ A asserted in Cycle, f follows in next cycle Same as using delayed signal (A') in Cycle!

11 Synchronous Mealy Machine Implementation Case III: Synchronized Outputs CLK A ƒ cycle cycle cycle 2 S S A/ƒ ƒ' A asserted during Cycle, f f asserted in next cycle Effect of A delayed one cycle

12 Microprogrammed Control Unit present input present output z z2 present state s s s2 s3 s s s s s2 s3 s s x z z2 2-way 2-bit MUX select 2 s s s2 s3 x present input 2 present state 2 possible next state z z2 present output

13 Branch Sequencers Concept Microprogrammed Control Unit Implement Next State Logic via ROM Address ROM with current state and inputs Problem: ROM doubles in size for each additional input Branch Sequencer: Next State stored in ROM Each state limited to small number of next states Always a power of 2 Observe: only a small set of inputs are examined in any state

14 Microprogrammed Control Unit 4 Way Branch Sequencer I n p u t s... Mux Mux β α a a a2 a3 a4 a5 64 Word ROM. C S x Z o i x Y n g x X t n x W r a o l. l s N α β α β α β α β W X Y Z state... Current State selects two inputs to form part of ROM address These select one of four possible next states (and output sets) Every state has exactly four possible next states

15 Microprogrammed Control Unit Alternative Horizontal Implementation α and β MUX Control α β α β α β α β A A A2 A3 n- n- n- n- Datapath Control Signals I N P U T S M U X M U X α β bit n : MUX bit n bit state register 2 3 4: MUX bit Input MUX controlled by encoded signals, not state Much fewer inputs than unique states! In this example, input MUX can be 2:! Adding length to ROM word saves on bits vs.. doubling words Vertical format: (7 + 4) x 64 = 344 ROM bits Horizontal format: (7 + 4 x 4 + 2) x 6 = 56 ROM bits

16 Microprogramming Microprogrammed Control Unit Implement control signals by storing 's and 's in a ROM Horizontal vs.. vertical microprogramming Horizontal: ROM output for each control signal Vertical: encoded control signals in ROM, decoded externally some mutually exclusive signals can be combined helps reduce ROM length Register Transfer/Microoperations 4 Register Transfer operations become 7 Microoperations: PC > ABUS IR > ABUS RBUS > AC ALU ADD ALU PASS A ALU PASS B MAR > Address Bus MBR > Data Bus ABUS > IR > IR ABUS > MAR Data Bus > MBR RBUS > MBR > PC PC + > PC ABUS > PC Read/Write Request

17 Horizontal Branch Sequencer Horizontal Branch Sequencer α, β Mux bits 4 x 4 Next State bits 7 Control operation bits 35 bits total RBUS MBR PC PC + PC ABUS PC Read/Write Next States α mux β mux PC ABUS IR ABUS RBUS AC ALU ADD ALU PASS A ALU PASS B MAR Address Bus MBR Data Bus ABUS IR ABUS MAR Data Bus MBR Request Microprogrammed Control Unit Horizontal Microprogramming A A A2 A3

18 Microprogrammed Control Unit Alpha inputs: = Wait, = IR<5> Beta inputs: = AC<5>, = IR<4> current state (address) α mux β mux next states A A A2 A3 PC ABUS IR ABUS RBUS AC ALU ADD ALU PASS A ALU PASS B MAR Address Bus MBR Data Bus MBUS IR ABUS MAR Data Bus MBR RBUS MBR PC PC + PC ABUS PC Read/Write Request RES () IF () IF () IF2 () IF3 () ID () LD () LD () LD2 () ST () ST () AD () AD () AD2 () BR () BR ()

19 Microprogrammed Control Unit Horizontal Microprogramming Advantages: complete parallel access to datapath control points Disadvantages: very long control words -- + bits for real processors NOTE: Not all microoperation combinations make sense! Output Encodings: Group mutually exclusive signals Use external logic to decode Example: > PC, PC + > PC, ABUS > PC mutually exclusive Save ROM bit with external 2:4 Decoder

20 Microprogrammed Control Unit Partially Encoded Control Outputs C O N T R O L R O M ALU ADD ALU PASS B MAR Address Bus MBR Data Bus ABUS MAR Read/Write Request MBUS IR RBUS AC 2 2:4 DEC RBUS MBR ALU PASS A PC PC + PC ABUS PC 2 2:4 DEC PC ABUS IR ABUS Data Bus MBR

21 Microprogrammed Control Unit Vertical Microprogramming More extensive encoding to reduce ROM word length Typically use multiple microword formats: horizontal microcode -- next state + control bits in same word separate formats for control outputs and "branch jumps" may require several microwords in a sequence to implement same function as single horizontal word in the extreme, very much like assembly language programming

22 Microprogrammed Control Unit Branch Jump Compare indicated signal to or Branch Jump Format Type Condition Select Condition Compare 2 6 Next Address = Wait = AC<5> = IR<5> = IR<4> Register Transfer Source, Destination, Operation Register Transfer Format Source Destination Operation ROM Bits : NO OP : PC ABUS : IR ABUS : MAR M : NO OP : RBUS AC : MBUS IR : ABUS MAR : M MBR : RBUS MBR : ABUS PC : MBR M : NO OP : ALU ADD : ALU PASS A : ALU PASS B : PC : PC + PC : Read,Request : Write,Request

23 Microprogrammed Control Unit ROM Contents ROM ADDRESS RES RT IF IF IF2 RT BJ RT BJ IF3 RT BJ ID BJ BJ LD LD RT RT BJ LD2 RT BJ BJ SYMBOLIC CONTENTS PC > ABUS Wait= MAR > M M > MBR Wait= Wait= IR<5>= IR<4>= IR > ABUS MAR > M M > MBR Wait= Wait= Wait= BINARY CONTENTS PC ABUS MAR PC + > PC IF Read IF2 MBUS IR IF3 ID ST ABUS MAR Read LD RBUS AC ALU PASS B IF IF

24 Microprogrammed Control Unit ROM ADDRESS ST SYMBOLIC CONTENTS RT RT ST RT BJ BJ BJ ID BJ AD RT AD RT BJ AD2 RT BJ BJ BJ BR BJ RT BJ IR > ABUS RBUS > MBR BINARY CONTENTS ABUS MAR ALU PASS A MAR > M MBR > M Write Wait= Wait= Wait= IR<4>= IR > ABUS MAR > M M > MBR Wait= Wait= Wait= Wait= AC<5>= IR > ABUS AC<5>= ST IF IF BR ABUS MAR Read AD RBUS AC ALU ADD AD2 IF IF IF ABUS PC IF 32 words x ROM bits = 32 bits total versus 6 x 35 = 56 bits horizontal

25 Control Unit Block Diagram Microprogrammed Control Unit Address ROM T SRC DST OP 3-bit register Enb 3-bit register Enb 3-bit register Enb 3:8 DEC 3:8 DEC 3:8 DEC ALU ADD ALU PASS A ALU PASS B PC PC + PC Read Write RBUS AC MBUS IR ABUS MAR M MBR RBUS MBR ABUS PC MBR M PC ABUS IR ABUS MAR M Read/Write Request Wait AC<5> IR<5> IR<4> Cond Logic LD CNT µpc CLR Reset Clk

26 Microprogrammed Control Unit Condition Logic Microinstruction Type Condition Selector Condition Comparator LD Wait AC<5> IR<5> IR<4> 4: MUX CNT

EECS150. Implement of Processor FSMs

EECS150. Implement of Processor FSMs EECS5 Section Controller Implementations Fall Implement of Processor FSMs Classical Finite State Machine Design Divide and Conquer Approach: Time-State Method Partition FSM into multiple communicating

More information

Controller Implementation--Part II

Controller Implementation--Part II Controller Implementation--Part II Alternative controller FSM implementation approaches based on: Classical Moore and Mealy machines Time-State: Divide and Conquer Jump counters Microprogramming (ROM)

More information

Moore EECS150. Implement of Processor FSMs. Memory-Register Interface Timing. Processor / Memory Interface. Processor Signal FLow

Moore EECS150. Implement of Processor FSMs. Memory-Register Interface Timing. Processor / Memory Interface. Processor Signal FLow Moore RES PC EECS5 IF PC MR, PC + PC Section Controller Implementations Fall Note capture of MBR in these states IF IF IF3 O MR Mem,,, Mem MBR MBR IR = = = IR MR, L IR MR ST C MBR MR Mem, MR Mem, L, ST,,,

More information

Alternative controller FSM implementation approaches based on:

Alternative controller FSM implementation approaches based on: Overview lternative controller FSM implementation approaches based on: classical Moore and Mealy machines jump counters microprogramming (ROM) based approaches branch sequencers horizontal microcode vertical

More information

Alternative Ways to Implement Processor FSMs. Outline. Moore Machine State Diagram. Random Logic. Moore Machine Diagram

Alternative Ways to Implement Processor FSMs. Outline. Moore Machine State Diagram. Random Logic. Moore Machine Diagram Outline lternative controller FSM implementation approaches based on: Classical Moore and Mealy machines Time state: ivide and Counter Jump counters Microprogramming (ROM) based approaches» branch sequencers»

More information

Controller Implementation--Part I. Cascading Edge-triggered Flip-Flops. Clock Skew. Cascading Edge-triggered Flip-Flops. Why Gating of Clocks is Bad!

Controller Implementation--Part I. Cascading Edge-triggered Flip-Flops. Clock Skew. Cascading Edge-triggered Flip-Flops. Why Gating of Clocks is Bad! Controller Implementation--Part I lternative controller FSM implementation approaches based on: Classical Moore and Mealy machines Time state: ivide and Jump counters Microprogramming (ROM) based approaches»

More information

Microprogramming is a technique to implement the control system of a CPU using a control store to hold the microoperations.

Microprogramming is a technique to implement the control system of a CPU using a control store to hold the microoperations. CS 320 Ch. 21 Microprogrammed Control Microprogramming is a technique to implement the control system of a CPU using a control store to hold the microoperations. Microprogramming was invented by Maurice

More information

Digital System Design Using Verilog. - Processing Unit Design

Digital System Design Using Verilog. - Processing Unit Design Digital System Design Using Verilog - Processing Unit Design 1.1 CPU BASICS A typical CPU has three major components: (1) Register set, (2) Arithmetic logic unit (ALU), and (3) Control unit (CU) The register

More information

Basic Processing Unit: Some Fundamental Concepts, Execution of a. Complete Instruction, Multiple Bus Organization, Hard-wired Control,

Basic Processing Unit: Some Fundamental Concepts, Execution of a. Complete Instruction, Multiple Bus Organization, Hard-wired Control, UNIT - 7 Basic Processing Unit: Some Fundamental Concepts, Execution of a Complete Instruction, Multiple Bus Organization, Hard-wired Control, Microprogrammed Control Page 178 UNIT - 7 BASIC PROCESSING

More information

Lecture1: introduction. Outline: History overview Central processing unite Register set Special purpose address registers Datapath Control unit

Lecture1: introduction. Outline: History overview Central processing unite Register set Special purpose address registers Datapath Control unit Lecture1: introduction Outline: History overview Central processing unite Register set Special purpose address registers Datapath Control unit 1 1. History overview Computer systems have conventionally

More information

Materials: 1. Projectable Version of Diagrams 2. MIPS Simulation 3. Code for Lab 5 - part 1 to demonstrate using microprogramming

Materials: 1. Projectable Version of Diagrams 2. MIPS Simulation 3. Code for Lab 5 - part 1 to demonstrate using microprogramming CS311 Lecture: CPU Control: Hardwired control and Microprogrammed Control Last revised October 18, 2007 Objectives: 1. To explain the concept of a control word 2. To show how control words can be generated

More information

The Processor: Datapath & Control

The Processor: Datapath & Control Chapter Five 1 The Processor: Datapath & Control We're ready to look at an implementation of the MIPS Simplified to contain only: memory-reference instructions: lw, sw arithmetic-logical instructions:

More information

Computer Architecture Programming the Basic Computer

Computer Architecture Programming the Basic Computer 4. The Execution of the EXCHANGE Instruction The EXCHANGE routine reads the operand from the effective address and places it in DR. The contents of DR and AC are interchanged in the third microinstruction.

More information

Micro-programmed Control Ch 15

Micro-programmed Control Ch 15 Micro-programmed Control Ch 15 Micro-instructions Micro-programmed Control Unit Sequencing Execution Characteristics 1 Hardwired Control (4) Complex Fast Difficult to design Difficult to modify Lots of

More information

Machine Instructions vs. Micro-instructions. Micro-programmed Control Ch 15. Machine Instructions vs. Micro-instructions (2) Hardwired Control (4)

Machine Instructions vs. Micro-instructions. Micro-programmed Control Ch 15. Machine Instructions vs. Micro-instructions (2) Hardwired Control (4) Micro-programmed Control Ch 15 Micro-instructions Micro-programmed Control Unit Sequencing Execution Characteristics 1 Machine Instructions vs. Micro-instructions Memory execution unit CPU control memory

More information

William Stallings Computer Organization and Architecture 8 th Edition. Chapter 16 Micro-programmed Control

William Stallings Computer Organization and Architecture 8 th Edition. Chapter 16 Micro-programmed Control William Stallings Computer Organization and Architecture 8 th Edition Chapter 16 Micro-programmed Control Control Unit Organization Micro-programmed Control Use sequences of instructions (see earlier notes)

More information

Micro-Operations. execution of a sequence of steps, i.e., cycles

Micro-Operations. execution of a sequence of steps, i.e., cycles Micro-Operations Instruction execution execution of a sequence of steps, i.e., cycles Fetch, Indirect, Execute & Interrupt cycles Cycle - a sequence of micro-operations Micro-operations data transfer between

More information

Materials: 1. Projectable Version of Diagrams 2. MIPS Simulation 3. Code for Lab 5 - part 1 to demonstrate using microprogramming

Materials: 1. Projectable Version of Diagrams 2. MIPS Simulation 3. Code for Lab 5 - part 1 to demonstrate using microprogramming CPS311 Lecture: CPU Control: Hardwired control and Microprogrammed Control Last revised October 23, 2015 Objectives: 1. To explain the concept of a control word 2. To show how control words can be generated

More information

Micro-programmed Control Ch 15

Micro-programmed Control Ch 15 Micro-programmed Control Ch 15 Micro-instructions Micro-programmed Control Unit Sequencing Execution Characteristics 1 Hardwired Control (4) Complex Fast Difficult to design Difficult to modify Lots of

More information

CONTROL UNIT CONTROL UNIT. CONTROL vs DATA PATH. Instruction Sequencing. Two main operations of Control Unit can be identified:

CONTROL UNIT CONTROL UNIT. CONTROL vs DATA PATH. Instruction Sequencing. Two main operations of Control Unit can be identified: CONTROL UNIT CONTROL UNIT of the Microprocessor Two main operations of Control Unit can be identified: Instruction sequencing - the methods by which instructions are selected for execution or, the manner

More information

Module 5 - CPU Design

Module 5 - CPU Design Module 5 - CPU Design Lecture 1 - Introduction to CPU The operation or task that must perform by CPU is: Fetch Instruction: The CPU reads an instruction from memory. Interpret Instruction: The instruction

More information

4. MICROPROGRAMMED COMPUTERS

4. MICROPROGRAMMED COMPUTERS Structure of Computer Systems Laboratory No. 4 1 4. MICROPROGRAMMED COMPUTERS This laboratory work presents the principle of microprogrammed computers and an example of microprogrammed architecture, in

More information

MICROPROGRAMMED CONTROL

MICROPROGRAMMED CONTROL MICROPROGRAMMED CONTROL Hardwired Control Unit: When the control signals are generated by hardware using conventional logic design techniques, the control unit is said to be hardwired. Micro programmed

More information

Implementing the Control. Simple Questions

Implementing the Control. Simple Questions Simple Questions How many cycles will it take to execute this code? lw $t2, 0($t3) lw $t3, 4($t3) beq $t2, $t3, Label add $t5, $t2, $t3 sw $t5, 8($t3) Label:... #assume not What is going on during the

More information

Micro-programmed Control Ch 17

Micro-programmed Control Ch 17 Micro-programmed Control Ch 17 Micro-instructions Micro-programmed Control Unit Sequencing Execution Characteristics Course Summary 1 Hardwired Control (4) Complex Fast Difficult to design Difficult to

More information

Hardwired Control (4) Micro-programmed Control Ch 17. Micro-programmed Control (3) Machine Instructions vs. Micro-instructions

Hardwired Control (4) Micro-programmed Control Ch 17. Micro-programmed Control (3) Machine Instructions vs. Micro-instructions Micro-programmed Control Ch 17 Micro-instructions Micro-programmed Control Unit Sequencing Execution Characteristics Course Summary Hardwired Control (4) Complex Fast Difficult to design Difficult to modify

More information

Chapter 4. MARIE: An Introduction to a Simple Computer 4.8 MARIE 4.8 MARIE A Discussion on Decoding

Chapter 4. MARIE: An Introduction to a Simple Computer 4.8 MARIE 4.8 MARIE A Discussion on Decoding 4.8 MARIE This is the MARIE architecture shown graphically. Chapter 4 MARIE: An Introduction to a Simple Computer 2 4.8 MARIE MARIE s Full Instruction Set A computer s control unit keeps things synchronized,

More information

Microprogramming: Basic Idea

Microprogramming: Basic Idea 5-45 Chapter 5 Processor Design Advanced Topics Microprogramming: Basic Idea Recall control sequence for 1-bus SRC Step Concrete RTN Control Sequence T0 MA PC: C PC + 4; PC out, MA in, INC4, C in, Read

More information

Name: ID# UNIVERSITY OF CALIFORNIA Department of Electrical Engineering and Computer Sciences EECS150 Fall 2001 Prof. Subramanian Midterm III

Name:   ID# UNIVERSITY OF CALIFORNIA Department of Electrical Engineering and Computer Sciences EECS150 Fall 2001 Prof. Subramanian Midterm III UNIVERSITY OF CALIFORNIA Department of Electrical Engineering and Computer Sciences EECS150 Fall 2001 Prof. Subramanian Midterm III 1) Recalculate the various propogation delays in a 4-bit carry lookahead

More information

PROBLEMS. 7.1 Why is the Wait-for-Memory-Function-Completed step needed when reading from or writing to the main memory?

PROBLEMS. 7.1 Why is the Wait-for-Memory-Function-Completed step needed when reading from or writing to the main memory? 446 CHAPTER 7 BASIC PROCESSING UNIT (Corrisponde al cap. 10 - Struttura del processore) PROBLEMS 7.1 Why is the Wait-for-Memory-Function-Completed step needed when reading from or writing to the main memory?

More information

Memory Interface. More Realistic Block Diagram: Issue memory request. Is it a read or a write? Memory asks CPU to wait

Memory Interface. More Realistic Block Diagram: Issue memory request. Is it a read or a write? Memory asks CPU to wait CPU Design Memory Interface More ealistic Block Diagram: Issue memory request Is it a read or a write? PC I equest ead/write Wait M Memory Memory asks CPU to wait LD/ST Data Instructions M B Memory Buffer

More information

Block diagram view. Datapath = functional units + registers

Block diagram view. Datapath = functional units + registers Computer design an application of digital logic design procedures Computer = processing unit + memory system Processing unit = control + datapath Control = finite state machine inputs = machine instruction,

More information

CC 311- Computer Architecture. The Processor - Control

CC 311- Computer Architecture. The Processor - Control CC 311- Computer Architecture The Processor - Control Control Unit Functions: Instruction code Control Unit Control Signals Select operations to be performed (ALU, read/write, etc.) Control data flow (multiplexor

More information

Topic #6. Processor Design

Topic #6. Processor Design Topic #6 Processor Design Major Goals! To present the single-cycle implementation and to develop the student's understanding of combinational and clocked sequential circuits and the relationship between

More information

Initial Representation Finite State Diagram. Logic Representation Logic Equations

Initial Representation Finite State Diagram. Logic Representation Logic Equations Control Implementation Alternatives Control may be designed using one of several initial representations. The choice of sequence control, and how logic is represented, can then be determined independently;

More information

ECE468 Computer Organization and Architecture. Designing a Multiple Cycle Controller

ECE468 Computer Organization and Architecture. Designing a Multiple Cycle Controller ECE468 Computer Organization and Architecture Designing a Multiple Cycle Controller ECE468 multicontroller Review of a Multiple Cycle Implementation The root of the single cycle processor s problems: The

More information

Chapter 16. Control Unit Operation. Yonsei University

Chapter 16. Control Unit Operation. Yonsei University Chapter 16 Control Unit Operation Contents Micro-Operation Control of the Processor Hardwired Implementation 16-2 Micro-Operations Micro-Operations Micro refers to the fact that each step is very simple

More information

Advanced Computer Architecture

Advanced Computer Architecture Advanced Computer Architecture Lecture No. 22 Reading Material Vincent P. Heuring&Harry F. Jordan Chapter 5 Computer Systems Design and Architecture 5.3 Summary Microprogramming Working of a General Microcoded

More information

Blog - https://anilkumarprathipati.wordpress.com/

Blog - https://anilkumarprathipati.wordpress.com/ Control Memory 1. Introduction The function of the control unit in a digital computer is to initiate sequences of microoperations. When the control signals are generated by hardware using conventional

More information

Chapter 3 : Control Unit

Chapter 3 : Control Unit 3.1 Control Memory Chapter 3 Control Unit The function of the control unit in a digital computer is to initiate sequences of microoperations. When the control signals are generated by hardware using conventional

More information

Processing Unit CS206T

Processing Unit CS206T Processing Unit CS206T Microprocessors The density of elements on processor chips continued to rise More and more elements were placed on each chip so that fewer and fewer chips were needed to construct

More information

Processing Unit. Unit II

Processing Unit. Unit II Processing Unit Unit II Execution of a complete instruction Add (R3), R1 - Adds the contents of a memory location pointed to by R3 to register R1 and store the result in R1. 1. Fetch the instruction 2.

More information

Computer Organization. Structure of a Computer. Registers. Register Transfer. Register Files. Memories

Computer Organization. Structure of a Computer. Registers. Register Transfer. Register Files. Memories Computer Organization Structure of a Computer Computer design as an application of digital logic design procedures Computer = processing unit + memory system Processing unit = control + Control = finite

More information

Class Notes. Dr.C.N.Zhang. Department of Computer Science. University of Regina. Regina, SK, Canada, S4S 0A2

Class Notes. Dr.C.N.Zhang. Department of Computer Science. University of Regina. Regina, SK, Canada, S4S 0A2 Class Notes CS400 Part VI Dr.C.N.Zhang Department of Computer Science University of Regina Regina, SK, Canada, S4S 0A2 C. N. Zhang, CS400 83 VI. CENTRAL PROCESSING UNIT 1 Set 1.1 Addressing Modes and Formats

More information

Faculty of Engineering Systems & Biomedical Dept. First Year Cairo University Sheet 6 Computer I

Faculty of Engineering Systems & Biomedical Dept. First Year Cairo University Sheet 6 Computer I aculty of Engineering Systems & Biomedical Dept. irst Year Cairo University Sheet 6 Computer I 1. Choose rue or alse for each of the following statements a) In a direct addressing mode instruction, the

More information

Page 521 CPSC 5155 Last Revised July 9, 2011 Copyright 2011 by Edward L. Bosworth, Ph.D. All rights reserved.

Page 521 CPSC 5155 Last Revised July 9, 2011 Copyright 2011 by Edward L. Bosworth, Ph.D. All rights reserved. Chapter 15 Implementation of the Central Processing Unit In this chapter, we continue consideration of the design and implementation of the CPU, more specifically the control unit of the CPU. In previous

More information

ENGG3380: Computer Organization and Design Lab5: Microprogrammed Control

ENGG3380: Computer Organization and Design Lab5: Microprogrammed Control ENGG330: Computer Organization and Design Lab5: Microprogrammed Control School of Engineering, University of Guelph Winter 201 1 Objectives: The objectives of this lab are to: Start Date: Week #5 201 Due

More information

Computer Organization

Computer Organization Computer Organization! Computer design as an application of digital logic design procedures! Computer = processing unit + memory system! Processing unit = control + datapath! Control = finite state machine

More information

Major and Minor States

Major and Minor States Major and Minor States We now consider the micro operations and control signals associated with the execution of each instruction in the ISA. The execution of each instruction is divided into three phases.

More information

ﻪﺘﻓﺮﺸﻴﭘ ﺮﺗﻮﻴﭙﻣﺎﻛ يرﺎﻤﻌﻣ MIPS يرﺎﻤﻌﻣ data path and ontrol control

ﻪﺘﻓﺮﺸﻴﭘ ﺮﺗﻮﻴﭙﻣﺎﻛ يرﺎﻤﻌﻣ MIPS يرﺎﻤﻌﻣ data path and ontrol control معماري كامپيوتر پيشرفته معماري MIPS data path and control abbasi@basu.ac.ir Topics Building a datapath support a subset of the MIPS-I instruction-set A single cycle processor datapath all instruction actions

More information

Introduction to CPU Design

Introduction to CPU Design ١ Introduction to CPU Design Computer Organization & Assembly Language Programming Dr Adnan Gutub aagutub at uqu.edu.sa [Adapted from slides of Dr. Kip Irvine: Assembly Language for Intel-Based Computers]

More information

CPE 335. Basic MIPS Architecture Part II

CPE 335. Basic MIPS Architecture Part II CPE 335 Computer Organization Basic MIPS Architecture Part II Dr. Iyad Jafar Adapted from Dr. Gheith Abandah slides http://www.abandah.com/gheith/courses/cpe335_s08/index.html CPE232 Basic MIPS Architecture

More information

Microprogrammed Control Approach

Microprogrammed Control Approach Microprogrammed Control Approach Considering the FSM for our MIPS subset has 10 states, the complete MIPS instruction set, which contains more than 100 instructions, and considering that these instructions

More information

The overall datapath for RT, lw,sw beq instrucution

The overall datapath for RT, lw,sw beq instrucution Designing The Main Control Unit: Remember the three instruction classes {R-type, Memory, Branch}: a) R-type : Op rs rt rd shamt funct 1.src 2.src dest. 31-26 25-21 20-16 15-11 10-6 5-0 a) Memory : Op rs

More information

CC312: Computer Organization

CC312: Computer Organization CC312: Computer Organization Dr. Ahmed Abou EL-Farag Dr. Marwa El-Shenawy 1 Chapter 4 MARIE: An Introduction to a Simple Computer Chapter 4 Objectives Learn the components common to every modern computer

More information

Chapter 05: Basic Processing Units Control Unit Design. Lesson 15: Microinstructions

Chapter 05: Basic Processing Units Control Unit Design. Lesson 15: Microinstructions Chapter 05: Basic Processing Units Control Unit Design Lesson 15: Microinstructions 1 Objective Understand that an instruction implement by sequences of control signals generated by microinstructions in

More information

5.7. Microprogramming: Simplifying Control Design 5.7

5.7. Microprogramming: Simplifying Control Design 5.7 5.7 Microprogramming: Simplifying Control Design 5.7 For the of our simple MIPS subset, a graphical representation of the finite state machine, as in Figure 5.40 on page 345, is certainly adequate. We

More information

Systems Architecture I

Systems Architecture I Systems Architecture I Topics A Simple Implementation of MIPS * A Multicycle Implementation of MIPS ** *This lecture was derived from material in the text (sec. 5.1-5.3). **This lecture was derived from

More information

Chapter 20 - Microprogrammed Control (9 th edition)

Chapter 20 - Microprogrammed Control (9 th edition) Chapter 20 - Microprogrammed Control (9 th edition) Luis Tarrataca luis.tarrataca@gmail.com CEFET-RJ L. Tarrataca Chapter 20 - Microprogrammed Control 1 / 47 Table of Contents I 1 Motivation 2 Basic Concepts

More information

Examining the complete instruction cycle for one instruction illustrates the operation of the P8 CPU. Assume the following conditions: C C C

Examining the complete instruction cycle for one instruction illustrates the operation of the P8 CPU. Assume the following conditions: C C C 5.0 Operation 5.1 The Instruction Cycle The CPU executes instructions that are stored in memory. The process of retrieving instructions and executing them is called the instruction cycle. Because it is

More information

CS31001 COMPUTER ORGANIZATION AND ARCHITECTURE

CS31001 COMPUTER ORGANIZATION AND ARCHITECTURE CS31001 COMPUTER ORGANIZATION AND ARCHITECTURE Debdeep Mukhopadhyay, CSE, IIT Kharagpur Instruction Execution Steps: The Multi Cycle Circuit 1 The Micro Mips ISA The Instruction Format op rs rt rd sh fn

More information

Multicycle Approach. Designing MIPS Processor

Multicycle Approach. Designing MIPS Processor CSE 675.2: Introduction to Computer Architecture Multicycle Approach 8/8/25 Designing MIPS Processor (Multi-Cycle) Presentation H Slides by Gojko Babić and Elsevier Publishing We will be reusing functional

More information

MC9211Computer Organization. Unit 4 Lesson 1 Processor Design

MC9211Computer Organization. Unit 4 Lesson 1 Processor Design MC92Computer Organization Unit 4 Lesson Processor Design Basic Processing Unit Connection Between the Processor and the Memory Memory MAR PC MDR R Control IR R Processo ALU R n- n general purpose registers

More information

SCRAM Introduction. Philipp Koehn. 19 February 2018

SCRAM Introduction. Philipp Koehn. 19 February 2018 SCRAM Introduction Philipp Koehn 19 February 2018 This eek 1 Fully work through a computer circuit assembly code Simple but Complete Random Access Machine (SCRAM) every instruction is 8 bit 4 bit for op-code:

More information

Computer Logic II CCE 2010

Computer Logic II CCE 2010 Computer Logic II CCE 2010 Dr. Owen Casha Computer Logic II 1 The Processing Unit Computer Logic II 2 The Processing Unit In its simplest form, a computer has one unit that executes program instructions.

More information

Control unit. Input/output devices provide a means for us to make use of a computer system. Computer System. Computer.

Control unit. Input/output devices provide a means for us to make use of a computer system. Computer System. Computer. Lecture 6: I/O and Control I/O operations Control unit Microprogramming Zebo Peng, IDA, LiTH 1 Input/Output Devices Input/output devices provide a means for us to make use of a computer system. Computer

More information

Programmable machines

Programmable machines Page 1 of 9 Programmable machines indicates problems that have been selected for discussion in section, time permitting. Problem 1. Consider the following circuit: The heavy lines represent busses, which

More information

Chapter 4. MARIE: An Introduction to a Simple Computer

Chapter 4. MARIE: An Introduction to a Simple Computer Chapter 4 MARIE: An Introduction to a Simple Computer Chapter 4 Objectives Learn the components common to every modern computer system. Be able to explain how each component contributes to program execution.

More information

omputer Design Concept adao Nakamura

omputer Design Concept adao Nakamura omputer Design Concept adao Nakamura akamura@archi.is.tohoku.ac.jp akamura@umunhum.stanford.edu 1 1 Pascal s Calculator Leibniz s Calculator Babbage s Calculator Von Neumann Computer Flynn s Classification

More information

William Stallings Computer Organization and Architecture 8 th Edition. Micro-programmed Control

William Stallings Computer Organization and Architecture 8 th Edition. Micro-programmed Control William Stallings Computer Organization and Architecture 8 th Edition Chapter 16 Micro-programmed Control Presenters: Andres Borroto Juan Fernandez Laura Verdaguer Control Unit Organization Micro-programmed

More information

Advanced Parallel Architecture Lesson 3. Annalisa Massini /2015

Advanced Parallel Architecture Lesson 3. Annalisa Massini /2015 Advanced Parallel Architecture Lesson 3 Annalisa Massini - 2014/2015 Von Neumann Architecture 2 Summary of the traditional computer architecture: Von Neumann architecture http://williamstallings.com/coa/coa7e.html

More information

Processor (I) - datapath & control. Hwansoo Han

Processor (I) - datapath & control. Hwansoo Han Processor (I) - datapath & control Hwansoo Han Introduction CPU performance factors Instruction count - Determined by ISA and compiler CPI and Cycle time - Determined by CPU hardware We will examine two

More information

Lets Build a Processor

Lets Build a Processor Lets Build a Processor Almost ready to move into chapter 5 and start building a processor First, let s review Boolean Logic and build the ALU we ll need (Material from Appendix B) operation a 32 ALU result

More information

Chapter 5. Computer Architecture Organization and Design. Computer System Architecture Database Lab, SANGJI University

Chapter 5. Computer Architecture Organization and Design. Computer System Architecture Database Lab, SANGJI University Chapter 5. Computer Architecture Organization and Design Computer System Architecture Database Lab, SANGJI University Computer Architecture Organization and Design Instruction Codes Computer Registers

More information

8-1. Fig. 8-1 ASM Chart Elements 2001 Prentice Hall, Inc. M. Morris Mano & Charles R. Kime LOGIC AND COMPUTER DESIGN FUNDAMENTALS, 2e, Updated.

8-1. Fig. 8-1 ASM Chart Elements 2001 Prentice Hall, Inc. M. Morris Mano & Charles R. Kime LOGIC AND COMPUTER DESIGN FUNDAMENTALS, 2e, Updated. 8-1 Name Binary code IDLE 000 Register operation or output R 0 RUN 0 1 Condition (a) State box (b) Example of state box (c) Decision box IDLE R 0 From decision box 0 1 START Register operation or output

More information

Lecture 5 and 6. ICS 152 Computer Systems Architecture. Prof. Juan Luis Aragón

Lecture 5 and 6. ICS 152 Computer Systems Architecture. Prof. Juan Luis Aragón ICS 152 Computer Systems Architecture Prof. Juan Luis Aragón Lecture 5 and 6 Multicycle Implementation Introduction to Microprogramming Readings: Sections 5.4 and 5.5 1 Review of Last Lecture We have seen

More information

Objective now How are such control statements registers and other components Managed to ensure proper execution of each instruction

Objective now How are such control statements registers and other components Managed to ensure proper execution of each instruction Control and Control Components Introduction Software application similar to familiar nested Russian dolls As we ve observed earlier Application written in some high level programming language C, C++, C#,

More information

Multicycle conclusion

Multicycle conclusion Multicycle conclusion The last few lectures covered a lot of material! We introduced a multicycle datapath, where different instructions take different numbers of cycles to execute. A multicycle unit is

More information

The Processing Unit. TU-Delft. in1210/01-pds 1

The Processing Unit. TU-Delft. in1210/01-pds 1 The Processing Unit in1210/01-pds 1 Problem instruction? y Decoder a ALU y f Reg in1210/01-pds 2 Basic cycle! Assume an instruction occupies a single word in memory! Basic cycle to be implemented: 1. Fetch

More information

THE MICROPROCESSOR Von Neumann s Architecture Model

THE MICROPROCESSOR Von Neumann s Architecture Model THE ICROPROCESSOR Von Neumann s Architecture odel Input/Output unit Provides instructions and data emory unit Stores both instructions and data Arithmetic and logic unit Processes everything Control unit

More information

Department of Electrical Engineering Introduction to Computer Engineering 1 Assignment 6: Computer Architecture

Department of Electrical Engineering Introduction to Computer Engineering 1 Assignment 6: Computer Architecture Department of Electrical Engineering Introduction to Computer Engineering 1 Assignment 6: Computer Architecture This assignment is not to be handed in, but is intended as a tutorial to help you understand

More information

Basic Processing Unit (Chapter 7)

Basic Processing Unit (Chapter 7) Basic Processing Unit (Chapter 7) IN1212-PDS 1 Problem instruction? y Decoder a ALU y f Reg IN1212-PDS 2 Basic cycle Assume an instruction occupies a single word in memory Basic cycle to be implemented:

More information

Mark Redekopp and Gandhi Puvvada, All rights reserved. EE 357 Unit 15. Single-Cycle CPU Datapath and Control

Mark Redekopp and Gandhi Puvvada, All rights reserved. EE 357 Unit 15. Single-Cycle CPU Datapath and Control EE 37 Unit Single-Cycle CPU path and Control CPU Organization Scope We will build a CPU to implement our subset of the MIPS ISA Memory Reference Instructions: Load Word (LW) Store Word (SW) Arithmetic

More information

Chapter 4 The Von Neumann Model

Chapter 4 The Von Neumann Model Chapter 4 The Von Neumann Model The Stored Program Computer 1943: ENIAC Presper Eckert and John Mauchly -- first general electronic computer. (or was it John V. Atananasoff in 1939?) Hard-wired program

More information

ECE170 Computer Architecture. Single Cycle Control. Review: 3b: Add & Subtract. Review: 3e: Store Operations. Review: 3d: Load Operations

ECE170 Computer Architecture. Single Cycle Control. Review: 3b: Add & Subtract. Review: 3e: Store Operations. Review: 3d: Load Operations ECE7 Computer Architecture Single Cycle Control Review: 3a: Overview of the Fetch Unit The common operations Fetch the : mem[] Update the program counter: Sequential Code: < + Branch and Jump: < something

More information

Computer Organization II CMSC 3833 Lecture 33

Computer Organization II CMSC 3833 Lecture 33 Term MARIE Definition Machine Architecture that is Really Intuitive and Easy 4.8.1 The Architecture Figure s Architecture Characteristics: Binary, two s complement Stored program, fixed word length Word

More information

Computer Architecture 2/26/01 Lecture #

Computer Architecture 2/26/01 Lecture # Computer Architecture 2/26/01 Lecture #9 16.070 On a previous lecture, we discussed the software development process and in particular, the development of a software architecture Recall the output of the

More information

Designing a Multicycle Processor

Designing a Multicycle Processor Designing a Multicycle Processor Arquitectura de Computadoras Arturo Díaz D PérezP Centro de Investigación n y de Estudios Avanzados del IPN adiaz@cinvestav.mx Arquitectura de Computadoras Multicycle-

More information

Outline. EEL-4713 Computer Architecture Designing a Single Cycle Datapath

Outline. EEL-4713 Computer Architecture Designing a Single Cycle Datapath Outline EEL-473 Computer Architecture Designing a Single Cycle path Introduction The steps of designing a processor path and timing for register-register operations path for logical operations with immediates

More information

CpE 442. Designing a Multiple Cycle Controller

CpE 442. Designing a Multiple Cycle Controller CpE 442 Designing a Multiple Cycle Controller CPE 442 multicontroller.. Outline of Today s Lecture Recap (5 minutes) Review of FSM control (5 minutes) From Finite State Diagrams to Microprogramming (25

More information

Computer Architecture

Computer Architecture Computer Architecture Lecture 1: Digital logic circuits The digital computer is a digital system that performs various computational tasks. Digital computers use the binary number system, which has two

More information

Chapter 4 The Processor (Part 2)

Chapter 4 The Processor (Part 2) Department of Electr rical Eng ineering, Chapter 4 The Processor (Part 2) 王振傑 (Chen-Chieh Wang) ccwang@mail.ee.ncku.edu.tw ncku edu Feng-Chia Unive ersity Outline A Multicycle Implementation Mapping Control

More information

Initial Representation Finite State Diagram Microprogram. Sequencing Control Explicit Next State Microprogram counter

Initial Representation Finite State Diagram Microprogram. Sequencing Control Explicit Next State Microprogram counter Control Implementation Alternatives Control may be designed using one of several initial representations. The choice of sequence control, and how logic is represented, can then be determined independently;

More information

2 MARKS Q&A 1 KNREDDY UNIT-I

2 MARKS Q&A 1 KNREDDY UNIT-I 2 MARKS Q&A 1 KNREDDY UNIT-I 1. What is bus; list the different types of buses with its function. A group of lines that serves as a connecting path for several devices is called a bus; TYPES: ADDRESS BUS,

More information

FSM Design Problem (10 points)

FSM Design Problem (10 points) Problem FSM Design Problem (5 points) Problem 2 FSM Design Problem ( points). In this problem, you will design an FSM which takes a synchronized serial input (presented LSB first) and outputs a serial

More information

Fig: Computer memory with Program, data, and Stack. Blog - NEC (Autonomous) 1

Fig: Computer memory with Program, data, and Stack. Blog -   NEC (Autonomous) 1 Central Processing Unit 1. Stack Organization A useful feature that is included in the CPU of most computers is a stack or last in, first out (LIFO) list. A stack is a storage device that stores information

More information

There are four registers involved in the fetch cycle: MAR, MBR, PC, and IR.

There are four registers involved in the fetch cycle: MAR, MBR, PC, and IR. CS 320 Ch. 20 The Control Unit Instructions are broken down into fetch, indirect, execute, and interrupt cycles. Each of these cycles, in turn, can be broken down into microoperations where a microoperation

More information

MARIE: An Introduction to a Simple Computer

MARIE: An Introduction to a Simple Computer MARIE: An Introduction to a Simple Computer 4.2 CPU Basics The computer s CPU fetches, decodes, and executes program instructions. The two principal parts of the CPU are the datapath and the control unit.

More information

CHAPTER 4 MARIE: An Introduction to a Simple Computer

CHAPTER 4 MARIE: An Introduction to a Simple Computer CHAPTER 4 MARIE: An Introduction to a Simple Computer 4.1 Introduction 177 4.2 CPU Basics and Organization 177 4.2.1 The Registers 178 4.2.2 The ALU 179 4.2.3 The Control Unit 179 4.3 The Bus 179 4.4 Clocks

More information

MICROPROGRAMMED CONTROL:-

MICROPROGRAMMED CONTROL:- MICROPROGRAMMED CONTROL:- Two methods of implementing control unit are Hardwired Control & Micro-Programmed Control. Hardwired: - when the control signals are generated by hardware using conventional logic

More information