Introduction CPU performance factors

Slides:



Advertisements
Similar presentations
CIS 314 Fall 2005 MIPS Datapath (Single Cycle and Multi-Cycle)
Advertisements

Datorteknik DatapathControl bild 1 Designing a Single Cycle Datapath & Datapath Control.
331 W08.1Spring :332:331 Computer Architecture and Assembly Language Spring 2006 Week 8: Datapath Design [Adapted from Dave Patterson’s UCB CS152.
The Processor: Datapath & Control
Fall 2007 MIPS Datapath (Single Cycle and Multi-Cycle)
Lec 17 Nov 2 Chapter 4 – CPU design data path design control logic design single-cycle CPU performance limitations of single cycle CPU multi-cycle CPU.
Computer Structure - Datapath and Control Goal: Design a Datapath  We will design the datapath of a processor that includes a subset of the MIPS instruction.
The Processor 2 Andreas Klappenecker CPSC321 Computer Architecture.
Shift Instructions (1/4)
Processor I CPSC 321 Andreas Klappenecker. Midterm 1 Thursday, October 7, during the regular class time Covers all material up to that point History MIPS.
S. Barua – CPSC 440 CHAPTER 5 THE PROCESSOR: DATAPATH AND CONTROL Goals – Understand how the various.
The Processor: Datapath & Control. Implementing Instructions Simplified instruction set memory-reference instructions: lw, sw arithmetic-logical instructions:
Designing a Simple Datapath Lecture for CPSC 5155 Edward Bosworth, Ph.D. Computer Science Department Columbus State University Revised 9/12/2013.
COSC 3430 L08 Basic MIPS Architecture.1 COSC 3430 Computer Architecture Lecture 08 Processors Single cycle Datapath PH 3: Sections
Chapter 4 CSF 2009 The processor: Building the datapath.
Lecture 8: Processors, Introduction EEN 312: Processors: Hardware, Software, and Interfacing Department of Electrical and Computer Engineering Spring 2014,
Lec 15Systems Architecture1 Systems Architecture Lecture 15: A Simple Implementation of MIPS Jeremy R. Johnson Anatole D. Ruslanov William M. Mongan Some.
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.
ECE 445 – Computer Organization
CPS3340 COMPUTER ARCHITECTURE Fall Semester, /19/2013 Lecture 17: The Processor - Overview Instructor: Ashraf Yaseen DEPARTMENT OF MATH & COMPUTER.
CDA 3101 Fall 2013 Introduction to Computer Organization
Datapath Design Computer Organization I 1 August 2009 © McQuain, Feng & Ribbens Composing the Elements First-cut data path does an instruction.
Computer Organization & Programming Chapter 6 Single Datapath CPU Architecture.
1. Building A CPU  We’ve built a small ALU l Add, Subtract, SLT, And, Or l Could figure out Multiply and Divide  What about the rest l How do.
More Intro MIPS Computer Organization I 1 September 2009 © McQuain, Feng & Ribbens Machine Language But, how is all of this driven? Machine.
CPU Overview Computer Organization II 1 February 2009 © McQuain & Ribbens Introduction CPU performance factors – Instruction count n Determined.
Datapath and Control AddressInstruction Memory Write Data Reg Addr Register File ALU Data Memory Address Write Data Read Data PC Read Data Read Data.
COM181 Computer Hardware Lecture 6: The MIPs CPU.
Morgan Kaufmann Publishers The Processor
May 22, 2000Systems Architecture I1 Systems Architecture I (CS ) Lecture 14: A Simple Implementation of MIPS * Jeremy R. Johnson Mon. May 17, 2000.
Computer Architecture Lecture 6.  Our implementation of the MIPS is simplified memory-reference instructions: lw, sw arithmetic-logical instructions:
CS161 – Design and Architecture of Computer Systems
Single-Cycle Datapath and Control
Morgan Kaufmann Publishers
Morgan Kaufmann Publishers The Processor
/ Computer Architecture and Design
Morgan Kaufmann Publishers The Processor
Morgan Kaufmann Publishers
Processor Architecture: Introduction to RISC Datapath (MIPS and Nios II) CSCE 230.
Processor (I).
Morgan Kaufmann Publishers The Processor
CSCI206 - Computer Organization & Programming
Single-Cycle CPU DataPath.
Datapath & Control MIPS
Morgan Kaufmann Publishers The Processor
Topic 5: Processor Architecture Implementation Methodology
Rocky K. C. Chang 6 November 2017
Composing the Elements
Composing the Elements
The Processor Lecture 3.2: Building a Datapath with Control
The Processor Lecture 3.1: Introduction & Logic Design Conventions
Topic 5: Processor Architecture
Datapath: Instruction Store/Fetch & PC Increment
Systems Architecture I
COMS 361 Computer Organization
COSC 2021: Computer Organization Instructor: Dr. Amir Asif
Lecture 14: Single Cycle MIPS Processor
Access the Instruction from Memory
COMP541 Datapaths I Montek Singh Mar 18, 2010.
Single Cycle Datapath Lecture notes from MKP, H. H. Lee and S. Yalamanchili.
Basic MIPS Implementation
CS/COE0447 Computer Organization & Assembly Language
A single-cycle MIPS processor
The Processor: Datapath & Control.
COMS 361 Computer Organization
Designing a Single-Cycle Processor
Processor: Datapath and Control
CS/COE0447 Computer Organization & Assembly Language
Presentation transcript:

Introduction CPU performance factors - Instruction count; determined by ISA and compiler - CPI and Cycle time; determined by CPU hardware We will examine a simplified MIPS implementation in this course and a more realistic pipelined version in the next. Simple subset of machine instructions, shows most aspects - Memory reference: lw, sw - Arithmetic/logical: add, sub, and, or, slt - Control transfer: beq, j CS@VT August 2009 ©2006-09 McQuain, Feng & Ribbens

Review of MIPS Machine Language Simple instructions, all 32 bits wide Very structured, no unnecessary baggage Only three instruction formats: R funct shamt rd rt rs op 16-bit immediate 26-bit immediate I J Basic arithmetical-logical instructions are R-format. Load/store/conditional branch instructions are I-format. Jump/unconditional branch instructions are J-format. CS@VT August 2009 ©2006-09 McQuain, Feng & Ribbens ©2009 McQuain & Ribbens 2

Instruction Execution PC  instruction memory, fetch instruction Register numbers  register file, read registers Depending on instruction class - Use ALU to calculate - Arithmetic result - Memory address for load/store - Branch target address - Access data memory for load/store - PC  target address or PC + 4 CS@VT August 2009 ©2006-09 McQuain, Feng & Ribbens

CPU Overview CS@VT August 2009 ©2006-09 McQuain, Feng & Ribbens

Need for Selection Mechanisms Must choose which one goes back to PC. BUT, you cannot just join wires together to achieve this… Compute address for sequential execution. Compute address for conditional branch. CS@VT August 2009 ©2006-09 McQuain, Feng & Ribbens

Need for Control Logic The 2x1 multiplexor must have a 1-bit control line to select between the two inputs. There must be a combinational circuit that determines which input should be selected and passed through to the PC. So, under what condition(s) should the branch address be used? … if we're executing a conditional branch instruction and the condition has evaluated to true. CS@VT August 2009 ©2006-09 McQuain, Feng & Ribbens

Control Questions What's the logic for controlling the other MUXes? What control settings will the ALU need? What goes here? CS@VT August 2009 ©2006-09 McQuain, Feng & Ribbens

Logic Design Basics Information encoded in binary - Low voltage = 0, High voltage = 1 - One wire per bit - Multi-bit data encoded on multi-wire buses Combinational elements - Operate on data - Output is purely a function of input State (sequential) elements - Store information - Output/state depends on input and on previous state CS@VT August 2009 ©2006-09 McQuain, Feng & Ribbens

Clocking Methodology Combinational logic transforms data during clock cycles - Between clock edges - Input from state elements, output to state element - Longest delay determines clock period CS@VT August 2009 ©2006-09 McQuain, Feng & Ribbens

Building a Datapath Datapath - Elements that process data and addresses in the CPU - Registers, ALUs, mux’s, memories, … We will build a MIPS datapath incrementally - Refining the overview design CS@VT August 2009 ©2006-09 McQuain, Feng & Ribbens

Increment by 4 for next instruction Instruction Fetch Increment by 4 for next instruction 32-bit register CS@VT August 2009 ©2006-09 McQuain, Feng & Ribbens

R-Format Instructions Read two register operands Perform arithmetic/logical operation Write register result funct shamt rd rt rs op CS@VT August 2009 ©2006-09 McQuain, Feng & Ribbens

Load/Store Instructions Read register operands Calculate address using 16-bit offset - Use ALU, but sign-extend offset Load: Read memory and update register Store: Write register value to memory 16-bit immediate rt rs op CS@VT August 2009 ©2006-09 McQuain, Feng & Ribbens

Branch Instructions Read register operands Compare operands - Use ALU, subtract and check Zero output Calculate target address - Sign-extend displacement - Shift left 2 places (word displacement) - Add to PC + 4 - Already calculated by instruction fetch 16-bit immediate rt rs op CS@VT August 2009 ©2006-09 McQuain, Feng & Ribbens

Sign-bit wire replicated Branch Instructions Just re-route wires Sign-bit wire replicated CS@VT August 2009 ©2006-09 McQuain, Feng & Ribbens