15-447 Computer ArchitectureFall 2008 © September 17th, 2008 Majd F. Sakr CS-447– Computer Architecture.

Slides:



Advertisements
Similar presentations
Machine cycle.
Advertisements

Adding the Jump Instruction
Control path Recall that the control path is the physical entity in a processor which: fetches instructions, fetches operands, decodes instructions, schedules.
Arithmetic Logic Unit (ALU)
EEM 486 EEM 486: Computer Architecture Lecture 4 Designing a Multicycle Processor.
Computer ArchitectureFall 2007 © October 1st, 2007 Majd F. Sakr CS-447– Computer Architecture.
10/13/2005Comp 120 Fall October Questions? Today Control.
CS-447– Computer Architecture Lecture 12 Multiple Cycle Datapath
L14 – Control & Execution 1 Comp 411 – Fall /04/09 Control & Execution Finite State Machines for Control MIPS Execution.
Midterm Wednesday Chapter 1-3: Number /character representation and conversion Number arithmetic Combinational logic elements and design (DeMorgan’s Law)
Levels in Processor Design
Topics covered: CPU Architecture CSE 243: Introduction to Computer Architecture and Hardware/Software Interface.
Computer ArchitectureFall 2007 © October 3rd, 2007 Majd F. Sakr CS-447– Computer Architecture.
Lecture 16: Basic CPU Design
Computer ArchitectureFall 2007 © October 31, CS-447– Computer Architecture M,W 10-11:20am Lecture 17 Review.
L15 – Control & Execution 1 Comp 411 – Spring /25/08 Control & Execution Finite State Machines for Control MIPS Execution.
Henry Hexmoor1 Chapter 10- Control units We introduced the basic structure of a control unit, and translated assembly instructions into a binary representation.
Computer ArchitectureFall 2007 © Sep 10 th, 2007 Majd F. Sakr CS-447– Computer Architecture.
Chapter 6 Memory and Programmable Logic Devices
Processor Types And Instruction Sets Barak Perelman CS147 Prof. Lee.
Lecture 24: CPU Design Today’s topic –Multi-Cycle ALU –Introduction to Pipelining 1.
Dr. Iyad F. Jafar Basic MIPS Architecture: Multi-Cycle Datapath and Control.
Computing Systems The Processor: Datapath and Control.
Computer Science 210 Computer Organization The von Neumann Architecture.
COSC 3430 L08 Basic MIPS Architecture.1 COSC 3430 Computer Architecture Lecture 08 Processors Single cycle Datapath PH 3: Sections
Computer Design Basics
Computer Architecture Lecture 09 Fasih ur Rehman.
Processor: Datapath and Control
General Concepts of Computer Organization Overview of Microcomputer.
A Simple Computer Architecture Digital Logic Design Instructor: Kasım Sinan YILDIRIM.
Intro MIPS Computer Organization I 1 September 2009 © McQuain, Feng & Ribbens The Stored Program Computer 1945: John von Neumann – Wrote a.
Gary MarsdenSlide 1University of Cape Town Chapter 5 - The Processor  Machine Performance factors –Instruction Count, Clock cycle time, Clock cycles per.
Computer Organization CS224 Fall 2012 Lesson 22. The Big Picture  The Five Classic Components of a Computer  Chapter 4 Topic: Processor Design Control.
Spring 2002INEL 4206 Microprocessors Lecture 4 1 Practical Universal Computers Prof. Bienvenido Velez Lecture 4 Bits Wires Gates Turing Machines.
1/8/ Data Path Design & Control Copyright Joanne DeGroat, ECE, OSU1 Processor Data Paths - ALU and Registers Incorporating the ALU into a.
Computer Structure & Architecture 7b - CPU & Buses.
Computer Organization CDA 3103 Dr. Hassan Foroosh Dept. of Computer Science UCF © Copyright Hassan Foroosh 2002.
EKT 221 : Chapter 4 Computer Design Basics
ALU (Continued) Computer Architecture (Fall 2006).
Von Neumann Model Computer Organization I 1 September 2009 © McQuain, Feng & Ribbens The Stored Program Computer 1945: John von Neumann –
CPU Overview Computer Organization II 1 February 2009 © McQuain & Ribbens Introduction CPU performance factors – Instruction count n Determined.
1 Basic Processor Architecture. 2 Building Blocks of Processor Systems CPU.
EKT 221 : Digital 2 Computer Design Basics Date : Lecture : 2 hrs.
CS161 – Design and Architecture of Computer Systems
CS161 – Design and Architecture of Computer Systems
The Stored Program Computer
Control & Execution Finite State Machines for Control MIPS Execution.
Computer Science 210 Computer Organization
Introduction CPU performance factors
Systems Architecture I
Morgan Kaufmann Publishers The Processor
Morgan Kaufmann Publishers
Decode and Operand Read
Simple Processor Control Unit
Control & Execution Finite State Machines for Control MIPS Execution.
Computer Architecture
Computer Science 210 Computer Organization
COMS 161 Introduction to Computing
Design of the Control Unit for One-cycle Instruction Execution
Morgan Kaufmann Publishers The Processor
Systems Architecture I
22 October 3 classes before 2nd exam! Control 1/16/2019
April 3 Fun with MUXes Implementing arbitrary logical functions
Systems Architecture I
MARIE: An Introduction to a Simple Computer
Systems Architecture I
Lecture 6 CdM-8 CPU overview
Systems Architecture I
Finite State Machine Continued
CS161 – Design and Architecture of Computer Systems
Presentation transcript:

Computer ArchitectureFall 2008 © September 17th, 2008 Majd F. Sakr CS-447– Computer Architecture M,W 2-3:50pm Lecture 10 Datapath & Control

Computer ArchitectureFall 2008 © Lecture Objectives ° Learn what a datapath is, and how does it provide the required functions. ° Appreciate why different implementation strategies affects the clock rate and CPI of a machine. ° Understand how the ISA determines many aspects of the hardware implementation.

Computer ArchitectureFall 2008 © The Big Picture of a Computer System DatapathControl Processor Main Memory Input / Output

Computer ArchitectureFall 2008 © Focusing on CPU & Memory Register File ALU Datapath IR PC CPUMemory Data Address Control Unit

Computer ArchitectureFall 2008 © The Datapath A load / store machine (RISC), register – register where access to memory is only done by load & store operations. Source 1 Register File ALU Source 2 Destination Result Control : (Register File)

Computer ArchitectureFall 2008 © Register File Design # Bits / Register = 8=> 8 MUXs # Registers = 4=>4 to 1 each MUX 4->1 MUX control 4->1 MUX s1_buss2_bus Reg A Reg B Reg CReg D

Computer ArchitectureFall 2008 © A0 A1 A2 A3C0 C1 C2 C3 MUX 4 -> 1 A0 B0 C0 D0 MUX 4 -> 1 A1 B1 C1 D1 MUX 4 -> 1 A2 B2 C2 D2 MUX 4 -> 1 A2 B2 C2 D2 B0 B1 B2 B3 MUX 4 -> 1 A0 B0 C0 D0 MUX 4 -> 1 A1 B1 C1 D1 MUX 4 -> 1 A2 B2 C2 D2 MUX 4 -> 1 A2 B2 C2 D2 D0 D1 D2 D3 S0 S1 S2 S3 s0 s1 s2 s3 Register File: 4 registers, 4 bits / register Control bits

Computer ArchitectureFall 2008 © The Datapath The Result of the operation performed in the ALU needs to be stored in a register. Source 1 Register File ALU Source 2 Destination Result Control

Computer ArchitectureFall 2008 © Destination: 2 registers / 3-bits per register DeMux3DeMux2DeMux1 Register 1Register 2 Control Result from ALU to Destination Bus

Computer ArchitectureFall 2008 © Quiz °Draw your design of a register file: Three registers, each is 2-bits wide Two source buses, one destination bus °How many & what size: Muxes did you use? Demuxes did you use? °Total number of control lines?

Computer ArchitectureFall 2008 © The Datapath A load / store machine (RISC), register – register where access to memory is only done by load & store operations. Source 1 Register File ALU Source 2 Destination Result Control : (ALU)

Computer ArchitectureFall 2008 © Simple ALU Design control s1_bus dest_bus Add/Sub s2_bus Shift/Logic 16 to 8 MUX

Computer ArchitectureFall 2008 © How about the Control? Register File ALU Datapath IR PC CPUMemory Data Address Control Unit

Computer ArchitectureFall 2008 © The Control Unit Control Logic

Computer ArchitectureFall 2008 © A simple device Build a custom controller for a vending machine. We could use a general purpose processor, but we might save money with a custom controller. Take coins, give drinks

Computer ArchitectureFall 2008 © Input and Output Inputs: 10 drink selectors coin trigger refund button Outputs: 10 drink release latches Coin refund latch 10 pressure sensors

Computer ArchitectureFall 2008 © Operation of Machine Accepts quarters only Once we get the money, they can select a drink. If they want a refund, release any coins inserted All drinks are $0.75 No free drinks! No stealing money!

Computer ArchitectureFall 2008 © Building the controller °Finite State Remember how many coins have been put in the machine and what inputs are acceptable °Read-Only Memory (ROM) Define the outputs and state transitions °Custom combinational circuits Reduce the size (and therefore cost) of the controller

Computer ArchitectureFall 2008 © Finite State Machines °A Finite State Machine (FSM) consists of: K states: S = {s 1, s 2, …,s k }, s 1 is initial state N inputs: I = {i 1, i 2, …,i n } M outputs: O = {o 1, o 2, …,o m } Transition function T(S,I) mapping each current state and input to next state Output Function P(S) [or P(S,I)] specifies output

Computer ArchitectureFall 2008 © Two common state machines °Moore machine output function based on current state only °Mealy machine output function based on current state and current input see P&H page B-35

Computer ArchitectureFall 2008 © FSM for vending machine 0 coins1 coin 3 coins2 coins Coin trigger Refund button Drink Select Ran out of specific drink selection

Computer ArchitectureFall 2008 © FSM for addition in Load/Store Architecture Fetch Decode Store result ALU Execute Store result in R 1 Send signal to ALU to perform addition Fetch Instruction (Add R 1, R 2 ) Registers R 1 and R 2 Fetch next instruction

Computer ArchitectureFall 2008 © D Q Implementing FSM D Q Current state Implement transition functions (using a ROM and combinational circuits) InputsOutputs Next state 2-bit state

Computer ArchitectureFall 2008 © The Control Unit When Add is Exechting Control Logic

Computer ArchitectureFall 2008 © The Control Unit When Add is Exechting Control Logic Instruction The control Turns on the required lines. In the Case of add, Ex: ALU OP, ALU source, Etc.

Computer ArchitectureFall 2008 © ROMs and PROMs °Read Only Memory Array of memory values that are constant Non-volatile °Programmable Read Only Memory Array of memory values that can be written exactly once (destructive writes) °You can use ROMs to implement FSM transition functions ROM inputs: ROM address ; current state + primary inputs ROM outputs: ROM data ; next state + primary outputs