Designing a Single- Cycle Processor 國立清華大學資訊工程學系 黃婷婷教授.

Slides:



Advertisements
Similar presentations
CS152 Lec9.1 CS152 Computer Architecture and Engineering Lecture 9 Designing Single Cycle Control.
Advertisements

EECC550 - Shaaban #1 Lec # 4 Summer Major CPU Design Steps 1Using independent RTN, write the micro- operations required for all target ISA.
361 datapath Computer Architecture Lecture 8: Designing a Single Cycle Datapath.
CS61C L19 CPU Design : Designing a Single-Cycle CPU (1) Beamer, Summer 2007 © UCB Scott Beamer Instructor inst.eecs.berkeley.edu/~cs61c CS61C : Machine.
CS61C L26 Single Cycle CPU Datapath II (1) Garcia © UCB Lecturer PSOE Dan Garcia inst.eecs.berkeley.edu/~cs61c CS61C : Machine.
CS152 / Kubiatowicz Lec8.1 9/26/01©UCB Fall 2001 CS152 Computer Architecture and Engineering Lecture 8 Designing Single Cycle Control September 26, 2001.
CS61C L26 CPU Design : Designing a Single-Cycle CPU II (1) Garcia, Spring 2007 © UCB 3.6 TB DVDs? Maybe!  Researchers at Harvard have found a way to use.
Savio Chau Single Cycle Controller Design Last Time: Discussed the Designing of a Single Cycle Datapath Control Datapath Memory Processor (CPU) Input Output.
Processor II CPSC 321 Andreas Klappenecker. Midterm 1 Tuesday, October 5 Thursday, October 7 Advantage: less material Disadvantage: less preparation time.
Ceg3420 control.1 ©UCB, DAP’ 97 CEG3420 Computer Design Lecture 9.2: Designing Single Cycle Control.
Inst.eecs.berkeley.edu/~cs61c UCB CS61C : Machine Structures Lecture 25 CPU design (of a single-cycle CPU) Sat Google in Mountain.
EECC550 - Shaaban #1 Lec # 4 Winter CPU Organization Datapath Design: –Capabilities & performance characteristics of principal Functional.
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.
CS61C L25 Single Cycle CPU Datapath (1) Garcia © UCB Lecturer PSOE Dan Garcia inst.eecs.berkeley.edu/~cs61c CS61C : Machine.
ECE 232 L13. Control.1 ©UCB, DAP’ 97 ECE 232 Hardware Organization and Design Lecture 13 Control Design
CS152 / Kubiatowicz Lec8.1 2/22/99©UCB Spring 1999 CS152 Computer Architecture and Engineering Lecture 8 Designing Single Cycle Control Feb 22, 1999 John.
CS61C L25 CPU Design : Designing a Single-Cycle CPU (1) Garcia, Fall 2006 © UCB T-Mobile’s Wi-Fi / Cell phone  T-mobile just announced a new phone that.
CS 61C L17 Control (1) A Carle, Summer 2006 © UCB inst.eecs.berkeley.edu/~cs61c/su06 CS61C : Machine Structures Lecture #17: CPU Design II – Control
CS151B Computer Systems Architecture Winter 2002 TuTh 2-4pm BH Instructor: Prof. Jason Cong Lecture 8 Designing a Single Cycle Control.
CS61C L26 CPU Design : Designing a Single-Cycle CPU II (1) Garcia, Fall 2006 © UCB Lecturer SOE Dan Garcia inst.eecs.berkeley.edu/~cs61c.
Inst.eecs.berkeley.edu/~cs61c UCB CS61C : Machine Structures Lecture 25 CPU design (of a single-cycle CPU) Intel is prototyping circuits that.
EECC550 - Shaaban #1 Lec # 4 Winter CPU Organization (Design) Datapath Design: –Capabilities & performance characteristics of principal.
CS61C L25 CPU Design : Designing a Single-Cycle CPU (1) Garcia, Spring 2007 © UCB Google Summer of Code  Student applications are now open (through );
EECC550 - Shaaban #1 Lec # 4 Winter Major CPU Design Steps 1Using independent RTN, write the micro- operations required for all target.
EEM 486: Computer Architecture Lecture 3 Designing a Single Cycle Datapath.
CS 61C L16 Datapath (1) A Carle, Summer 2004 © UCB inst.eecs.berkeley.edu/~cs61c/su05 CS61C : Machine Structures Lecture #16 – Datapath Andy.
CS 61C: Great Ideas in Computer Architecture (Machine Structures) Lecture 28: Single-Cycle CPU Datapath Control Part 1 Guest Lecturer: Sagar Karandikar.
361 control Computer Architecture Lecture 9: Designing Single Cycle Control.
CS61C L26 CPU Design : Designing a Single-Cycle CPU II (1) Garcia, Spring 2010 © UCB inst.eecs.berkeley.edu/~cs61c UC Berkeley CS61C : Machine Structures.
ECE 232 L12.Datapath.1 Adapted from Patterson 97 ©UCBCopyright 1998 Morgan Kaufmann Publishers ECE 232 Hardware Organization and Design Lecture 12 Datapath.
ELEN 350 Single Cycle Datapath Adapted from the lecture notes of John Kubiatowicz(UCB) and Hank Walker (TAMU)
CS61C L27 Single Cycle CPU Control (1) Garcia, Fall 2006 © UCB Wireless High Definition?  Several companies will be working on a “WirelessHD” standard,
CS3350B Computer Architecture Winter 2015 Lecture 5.6: Single-Cycle CPU: Datapath Control (Part 1) Marc Moreno Maza [Adapted.
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
Computer Organization CS224 Fall 2012 Lesson 26. Summary of Control Signals addsuborilwswbeqj RegDst ALUSrc MemtoReg RegWrite MemWrite Branch Jump ExtOp.
Chapter 4 CSF 2009 The processor: Building the datapath.
EEM 486: Computer Architecture Designing Single Cycle Control.
Lec 15Systems Architecture1 Systems Architecture Lecture 15: A Simple Implementation of MIPS Jeremy R. Johnson Anatole D. Ruslanov William M. Mongan Some.
Computer Organization CS224 Fall 2012 Lesson 22. The Big Picture  The Five Classic Components of a Computer  Chapter 4 Topic: Processor Design Control.
Designing a Single Cycle Datapath In this lecture, slides from lectures 3, 8 and 9 from the course Computer Architecture ECE 201 by Professor Mike Schulte.
CS 61C: Great Ideas in Computer Architecture Datapath
ECE 445 – Computer Organization
CPS3340 COMPUTER ARCHITECTURE Fall Semester, /19/2013 Lecture 17: The Processor - Overview Instructor: Ashraf Yaseen DEPARTMENT OF MATH & COMPUTER.
EEM 486: Computer Architecture Designing a Single Cycle Datapath.
CPE 442 single-cycle datapath.1 Intro. To Computer Architecture CpE242 Computer Architecture and Engineering Designing a Single Cycle Datapath.
Datapath and Control Unit Design
CS3350B Computer Architecture Winter 2015 Lecture 5.7: Single-Cycle CPU: Datapath Control (Part 2) Marc Moreno Maza [Adapted.
1 Processor: Datapath and Control Single cycle processor –Datapath and Control Multicycle processor –Datapath and Control Microprogramming –Vertical and.
Computer Organization CS224 Chapter 4 Part a The Processor Spring 2011 With thanks to M.J. Irwin, T. Fountain, D. Patterson, and J. Hennessy for some lecture.
CPU Overview Computer Organization II 1 February 2009 © McQuain & Ribbens Introduction CPU performance factors – Instruction count n Determined.
CS4100: 計算機結構 Designing a Single-Cycle Processor 國立清華大學資訊工程學系 一零零學年度第二學期.
Csci 136 Computer Architecture II –Single-Cycle Datapath Xiuzhen Cheng
EEM 486: Computer Architecture Lecture 3 Designing Single Cycle Control.
CS 61C: Great Ideas in Computer Architecture (Machine Structures) Single-Cycle CPU Datapath & Control Part 2 Instructors: Krste Asanovic & Vladimir Stojanovic.
CS141-L4-1Tarun Soni, Summer’03 Single Cycle CPU  Previously: built and ALU.  Today: Actually build a CPU Questions on CS140 ? Computer Arithmetic ?
Single Cycle Controller Design
Morgan Kaufmann Publishers The Processor
Designing a Single-Cycle Processor
IT 251 Computer Organization and Architecture
(Chapter 5: Hennessy and Patterson) Winter Quarter 1998 Chris Myers
Morgan Kaufmann Publishers The Processor
Morgan Kaufmann Publishers
Single Cycle CPU Design
CS152 Computer Architecture and Engineering Lecture 8 Designing a Single Cycle Datapath Start: X:40.
COMS 361 Computer Organization
CSC3050 – Computer Architecture
COMS 361 Computer Organization
Designing a Single-Cycle Processor
Processor: Datapath and Control
Presentation transcript:

Designing a Single- Cycle Processor 國立清華大學資訊工程學系 黃婷婷教授

Outline  Introduction to designing a processor  Analyzing the instruction set ( step 1 )  Building the datapath ( steps 2 and 3 )  A single-cycle implementation  Control for the single-cycle CPU ( steps 4 and 5 ) Control of CPU operations ALU controller Main controller  Adding jump instruction 1

Introduction  CPU performance factors Instruction count Determined by ISA and compiler CPI and Cycle time Determined by CPU hardware  We will examine two MIPS implementations A simplified version A more realistic pipelined version  Simple subset, shows most aspects Memory reference: lw, sw Arithmetic/logical: add, sub, and, or, slt Control transfer: beq, j §4.1 Introduction 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 3

CPU Overview 4

Multiplexers  Can’t just join wires together Use multiplexers 5

Control 6

Logic Design Basics §4.2 Logic Design Conventions  Information encoded in binary Low voltage = 0, High voltage = 1 One wire per bit Multi-bit data encoded on multi-wire buses  Combinational element Operate on data Output is a function of input  State (sequential) elements Store information 7

Combinational Elements  AND-gate Y = A & B A B Y I0 I1 Y MuxMux S  Multiplexer Y = S ? I1 : I0 A B Y + A B Y ALU F  Adder Y = A + B  Arithmetic/Logic Unit Y = F(A, B) 8

Sequential Elements  Register: stores data in a circuit Uses a clock signal to determine when to update the stored value Edge-triggered: update when Clk changes from 0 to 1 D Clk Q D Q 9

Sequential Elements  Register with write control Only updates on clock edge when write control input is 1 Used when stored value is required later D Clk Q Write D Q Clk 10

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 11

How to Design a Processor? 1. Analyze instruction set (datapath requirements) The meaning of each instruction is given by the register transfers Datapath must include storage element Datapath must support each register transfer 2. Select set of datapath components and establish clocking methodology 3. Assemble datapath meeting the requirements 4. Analyze implementation of each instruction to determine setting of control points effecting register transfer 5. Assemble the control logic 12

Outline  Introduction to designing a processor  Analyzing the instruction set (step 1)  Building the datapath (steps 2 and 3)  A single-cycle implementation  Control for the single-cycle CPU Control of CPU operations ALU controller Main controller 13

 All MIPS instructions are 32 bits long with 3 formats: R-type: I-type: J-type:  The different fields are: op: operation of the instruction rs, rt, rd: source and destination register shamt: shift amount funct: selects variant of the “op” field address / immediate target address: target address of jump optarget address bits26 bits oprsrtrdshamtfunct bits 5 bits oprsrt immediate bits16 bits5 bits Step 1: Analyze Instruction Set 14

oprsrtrdshamtfunct bits 5 bits oprsrtimmediate bits16 bits5 bits opaddress bits26 bits Our Example: A MIPS Subset  R-Type: add rd, rs, rt sub rd, rs, rt and rd, rs, rt or rd, rs, rt slt rd, rs, rt  Load/Store: lw rt,rs,imm16 sw rt,rs,imm16  Imm operand: addi rt,rs,imm16  Branch: beq rs,rt,imm16  Jump: j target 15

Logical Register Transfers MEM[ PC ] = op | rs | rt | rd | shamt | funct or = op | rs | rt | Imm16 or = op | Imm26 (added at the end) Inst Register transfers ADDR[rd] <- R[rs] + R[rt]; PC <- PC + 4 SUBR[rd] <- R[rs] - R[rt]; PC <- PC + 4 LOADR[rt] <- MEM[ R[rs] + sign_ext(Imm16)]; PC <- PC + 4 STOREMEM[ R[rs] + sign_ext(Imm16) ] <-R[rt]; PC <- PC + 4 ADDI R[rt] <- R[rs] + sign_ext(Imm16)]; PC <- PC + 4 BEQ if (R[rs] == R[rt]) then PC <- PC sign_ext(Imm16)] || 00 else PC <- PC + 4  RTL gives the meaning of the instructions  All start by fetching the instruction, read registers, then use ALU => simplicity and regularity help 16

Requirements of Instruction Set After checking the register transfers, we can see that datapath needs the followings:  Memory store instructions and data  Registers (32 x 32) read RS read RT Write RT or RD  PC  Extender for zero- or sign-extension  Add and sub register or extended immediate (ALU)  Add 4 or extended immediate to PC 17

Outline  Introduction to designing a processor  Analyzing the instruction set (step 1)  Building the datapath (steps 2, 3)  A single-cycle implementation  Control for the single-cycle CPU Control of CPU operations ALU controller Main controller  Adding jump instruction 18

 Basic building blocks of combinational logic elements : 32 A B Sum Carry 32 A B Result ALU control 32 A B Y Select Adder MUX ALU CarryIn Adder MUX ALU 4 Step 2a: Combinational Components for Datapath 19

Storage elements:  Register: Similar to the D Flip Flop except N-bit input and output Write Enable input Write Enable: negated (0): Data Out will not change asserted (1): Data Out will become Data In Clk Data In Write Enable NN Data Out Step 2b: Sequential Components for Datapath 20

Clk busW Write Enable 32 busA 32 busB 555 RWRARB 32-bit Registers Storage Element: Register File  Consists of 32 registers: Appendix B.8 Two 32-bit output busses: busA and busB One 32-bit input bus: busW  Register is selected by: RA selects the register to put on busA (data) RB selects the register to put on busB (data) RW selects the register to be written via busW (data) when Write Enable is 1  Clock input (CLK) The CLK input is a factor ONLY during write operation During read, behaves as a combinational circuit 21

Clk Data In Write Enable 32 DataOut Address Storage Element: Memory  Memory (idealized) Appendix B.8 One input bus: Data In One output bus: Data Out  Word is selected by: Address selects the word to put on Data Out Write Enable = 1: address selects the memory word to be written via the Data In bus  Clock input (CLK) The CLK input is a factor ONLY during write operation During read operation, behaves as a combinational logic block: Address valid => Data Out valid after access time No need for read control 22

 Instruction fetch unit: common operations Fetch the instruction: mem[PC] Update the program counter: Sequential code: PC <- PC + 4 Branch and Jump: PC <- “Something else” Step 3a: Datapath Assembly 23

oprsrtrdshamtfunct bits 5 bits rs rt rd Step 3b: Add and Subtract  R[rd] <- R[rs] op R[rt] Ex: add rd, rs, rt Ra, Rb, Rw come from inst.’s rs, rt, and rd fields ALU and RegWrite: control logic after decode 4 (funct) 24

Step 3c: Store/Load Operations  R[rt]<-Mem[R[rs]+SignExt[imm16]] Ex: lw rt,rs,imm16 rs rt 11 oprsrtimmediate bits16 bits5 bits rd 4 rt 25

R-Type/Load/Store Datapath 26

 beq rs, rt, imm16 mem[PC]Fetch inst. from memory Equal <- R[rs] == R[rt]Calculate branch condition if (COND == 0)Calculate next inst. address PC <- PC ( SignExt(imm16) x 4 ) else PC <- PC + 4 oprsrtimmediate bits16 bits5 bits Step 3d: Branch Operations 27

Datapath for Branch Operations  beq rs, rt, imm

Outline  Introduction to designing a processor  Analyzing the instruction set  Building the datapath  A single-cycle implementation  Control for the single-cycle CPU Control of CPU operations ALU controller Main controller 29

A Single Cycle Datapath 30

Data Flow during add Clocking data flows in other paths  4 31

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 32

Clocking Methodology  Define when signals are read and written  Assume edge-triggered: Values in storage (state) elements updated only on a clock edge => clock edge should arrive only after input signals stable Any combinational circuit must have inputs from and outputs to storage elements Clock cycle : time for signals to propagate from one storage element, through combinational circuit, to reach the second storage element A register can be read, its value propagated through some combinational circuit, new value is written back to the same register, all in same cycle => no feedback within a single cycle 33

34 Register-Register Timing 32 Result ALUctr Clk busW RegWr 32 busA 32 busB 555 RwRaRb bit Registers RsRtRd ALU Clk PC Rs, Rt, Rd, Op, Func Clk-to-Q ALUctr Instruction Memory Access Time Old ValueNew Value RegWrOld ValueNew Value Delay through Control Logic busA, B Register File Access Time Old ValueNew Value busW ALU Delay Old ValueNew Value Old ValueNew Value Old Value Register Write Occurs Here Ideal Instruction Memory PC 32 Clk

Critical Path (Load Operation) = PC’s Clk-to-Q + Instruction memory’s Access Time + Register file’s Access Time + ALU to Perform a 32-bit Add + Data Memory Access Time + Setup Time for Register File Write + Clock Skew Clk 5 RwRaRb bit Registers Rd ALU Clk Data In Data Address Ideal Data Memory Instruction Address Ideal Instruction Memory Clk PC 5 Rs 5 Rt 16 Imm 32 A B Next Address The Critical Path  Register file and ideal memory: During read, behave as combinational logic: Address valid => Output valid after access time 35

Worst Case Timing (Load) Clk PC Rs, Rt, Rd, Op, Func Clk-to-Q ALUctr Instruction Memoey Access Time Old ValueNew Value RegWrOld ValueNew Value Delay through Control Logic busA Register File Access Time Old ValueNew Value busB ALU Delay Old ValueNew Value Old ValueNew Value Old Value ExtOpOld ValueNew Value ALUSrcOld ValueNew Value MemtoRegOld ValueNew Value AddressOld ValueNew Value busWOld ValueNew Delay through Extender & Mux Register Write Occurs Data Memory Access Time 36

Outline  Introduction to designing a processor  Analyzing the instruction set  Building the datapath  A single-cycle implementation  Control for the single-cycle CPU Control of CPU operations (step 4) ALU controller ( step 5a) Main controller (step 5b)  Adding jump instruction 37

ALUctr RegDstALUSrc MemRd MemtoReg MemWr Equal Instruction Imm16RdRsRt PCsrc Addr Inst. Memory Datapath Control Op Funct RegWr Step 4: Control Points and Signals 38

Datapath with Mux and Control Control point 39

Designing Main Control  Some observations: opcode (Op[5-0]) is always in bits

Datapath with Control Unit 41

Instruction Fetch at Start of Add  instruction <- mem[PC]; PC

Instruction Decode of Add  Fetch the two operands and decode instruction: 43

ALU Operation during Add  R[rs] + R[rt] 44

Write Back at the End of Add  R[rd] <- ALU; PC <- PC

Datapath Operation for lw  R[rt] <- Memory {R[rs] + SignExt[imm16]} 46

Datapath Operation for beq if (R[rs]-R[rt]==0) then Zero<-1 else Zero<-0 if (Zero==1) then PC=PC+4+signExt[imm16]*4; else PC = PC

Outline  Designing a processor  Analyzing the instruction set  Building the datapath  A single-cycle implementation  Control for the single-cycle CPU Control of CPU operations (step 4) ALU controller (step 5a) Main controller (step 5b)  Adding jump instruction 48

Datapath with Control Unit 49

Step 5a: ALU Control  ALU used for Load/Store: F = add Branch: F = subtract R-type: F depends on funct field ALU controlFunction 0000AND 0001OR 0010add 0110subtract 0111set-on-less-than 1100NOR 50

 ALUop is 2-bit wide to represent: “I-type” requiring the ALU to perform: (00) add for load/store and (01) sub for beq “R-type” (10), need to reference func field Main Control Op code 6 ALU Control (Local) func 2 6 ALUop ALUctr 3 R-typelwswbeqjump ALUop (Symbolic)“R-type”Add Subtract xxx ALUop xxx Our Plan for the Controller oprsrtrdshamtfunct R-type ALU 7 51

ALU Control  Assume 2-bit ALUOp derived from opcode Combinational logic derives ALU control opcodeALUOpOperationfunctALU functionALU control lw00load wordXXXXXXadd0010 sw00store wordXXXXXXadd0010 beq01branch equalXXXXXXsubtract0110 R-type10add100000add0010 subtract100010subtract0110 AND100100AND0000 OR100101OR0001 set-on-less- than set-on-less- than

Logic Equation for ALUctr x ALUopfunc bit 00x ALUctr 1 0 bit x10 1x0 1x0 1x0 1x x x x x x x1 x x x x x x x x x x x x x x x

ALUctr2 = ALUop0 + ALUop1 ‧ func2’ ‧ func1 ‧ func0’ ALUopfunc bit ALUctr x11 1x1 1x bit x 0 0 x 1 1 x x 0 1 This makes func a don’t care Logic Equation for ALUctr2 bit x x x x x x 54

ALUctr1 = ALUop1’ + ALUop1 ‧ func2’ ‧ func0’ ALUopfunc bit 00 ALUctr x1 1x 1x 1x bit x x x x x x x x Logic Equation for ALUctr1 bit x x x x x x x x x x 55

ALUctr0 = ALUop1 ‧ func3’ ‧ func2 ‧ func1’ ‧ func0 + ALUop1’ ‧ func3 ‧ func2’ ‧ func1 ‧ func0’ ALUopfunc bit ALUctr 1x1 1x bit Logic Equation for ALUctr0 bit x x x x 56

The Resultant ALU Control Block 57 0 Operation3

Outline  Introduction to designing a processor  Analyzing the instruction set  Building the datapath  A single-cycle implementation  Control for the single-cycle CPU Control of CPU operations ALU controller Main controller (step 5b)  Adding jump instruction 58

Datapath with Control Unit 59

Step 5b: The Main Control Unit  Control signals derived from instruction 0rsrtrdshamtfunct 31:265:025:2120:1615:1110:6 35 or 43rsrtaddress 31:2625:2120:1615:0 4rsrtaddress 31:2625:2120:1615:0 R-type Load/ Store Branch opcodealways read read, except for load write for R-type and load sign-extend and add 60

addsublwswbeq RegDst ALUSrc MemtoReg RegWrite MemWrite Branch ALUop1 ALUop x 1 x x 0 x func op Appendix A See We Don’t Care :-) Truth Table of Control Signals (6 inputs and 9 outputs) MemRead00100 Main Control Op code 6 ALU Control (Local) func 2 6 ALUop ALUctr 4 RegDst ALUSrc : 61

R-typelwswbeq RegWrite1100 Op code RegWrite = R-type + lw = op5’ ‧ op4’ ‧ op3’ ‧ op2’ ‧ op1’ ‧ op0’(R-type) + op5 ‧ op4’ ‧ op3’ ‧ op2’ ‧ op1 ‧ op0(lw) op.... op.. op.. op.. R-typelwswbeqjump RegWrite Truth Table for RegWrite X 62

PLA Implementing Main Control 63

Outline  Introduction to designing a processor  Analyzing the instruction set (step 1)  Building the datapath (steps 2, 3)  A single-cycle implementation  Control for the single-cycle CPU Control of CPU operations ALU controller Main controller  Adding jump instruction 64

Implementing Jumps  Jump uses word address  Update PC with concatenation of Top 4 bits of old PC 26-bit jump address 00  Need an extra control signal decoded from opcode 2address 31:2625:0 Jump 65

Putting it Altogether (+ jump instruction) 66

67 Worst Case Timing (Load) Clk PC Rs, Rt, Rd, Op, Func Clk-to-Q ALUctr Instruction Memoey Access Time Old ValueNew Value RegWrOld ValueNew Value Delay through Control Logic busA Register File Access Time Old ValueNew Value busB ALU Delay Old ValueNew Value Old ValueNew Value Old Value ExtOpOld ValueNew Value ALUSrcOld ValueNew Value MemtoRegOld ValueNew Value AddressOld ValueNew Value busWOld ValueNew Delay through Extender & Mux Register Write Occurs Data Memory Access Time

Drawback of Single-Cycle Design  Long cycle time: Cycle time must be long enough for the load instruction: PC’s Clock -to-Q + Instruction Memory Access Time + Register File Access Time + ALU Delay (address calculation) + Data Memory Access Time + Register File Setup Time + Clock Skew  Cycle time for load is much longer than needed for all other instructions 68

Summary  Single cycle datapath => CPI=1, Clock cycle time long  MIPS makes control easier Instructions same size Source registers always in same place Immediates same size, location Operations always on registers/immediates 69