CS 141 ChienMay 3, 1999 Concepts in Pipelining u Last Time –Midterm Exam, Grading in progress u Today –Concepts in Pipelining u Reminders/Announcements.

Slides:



Advertisements
Similar presentations
PipelineCSCE430/830 Pipeline: Introduction CSCE430/830 Computer Architecture Lecturer: Prof. Hong Jiang Courtesy of Prof. Yifeng Zhu, U of Maine Fall,
Advertisements

Computer Organization and Architecture
RISC and Pipelining Prof. Sin-Min Lee Department of Computer Science.
Pipeline Computer Organization II 1 Hazards Situations that prevent starting the next instruction in the next cycle Structural hazards – A required resource.
Lecture Objectives: 1)Define pipelining 2)Calculate the speedup achieved by pipelining for a given number of instructions. 3)Define how pipelining improves.
CMPT 334 Computer Organization
Pipeline and Vector Processing (Chapter2 and Appendix A)
Pipelining, Parallelism, and Simplified Circuits Discrete Math April 13, 2006 Harding University Jonathan White.
Chapter 8. Pipelining.
Review: Pipelining. Pipelining Laundry Example Ann, Brian, Cathy, Dave each have one load of clothes to wash, dry, and fold Washer takes 30 minutes Dryer.
Pipelining I (1) Fall 2005 Lecture 18: Pipelining I.
10/11: Lecture Topics Slides on starting a program from last time Where we are, where we’re going RISC vs. CISC reprise Execution cycle Pipelining Hazards.
Pipelining Hwanmo Sung CS147 Presentation Professor Sin-Min Lee.
Goal: Describe Pipelining
Chapter Six 1.
Instruction-Level Parallelism (ILP)
1 Lecture 17: Basic Pipelining Today’s topics:  5-stage pipeline  Hazards and instruction scheduling Mid-term exam stats:  Highest: 90, Mean: 58.
Pipelining II Andreas Klappenecker CPSC321 Computer Architecture.
1 Recap (Pipelining). 2 What is Pipelining? A way of speeding up execution of tasks Key idea : overlap execution of multiple taks.
Chapter 12 Pipelining Strategies Performance Hazards.
Prof. John Nestor ECE Department Lafayette College Easton, Pennsylvania Computer Organization Pipelined Processor Design 1.
Pipelining Andreas Klappenecker CPSC321 Computer Architecture.
1 COMP541 Sequencing – III (Sequencing a Computer) Montek Singh April 9, 2007.
Pipelined Processor II CPSC 321 Andreas Klappenecker.
1 Atanasoff–Berry Computer, built by Professor John Vincent Atanasoff and grad student Clifford Berry in the basement of the physics building at Iowa State.
Appendix A Pipelining: Basic and Intermediate Concepts
Prof. John Nestor ECE Department Lafayette College Easton, Pennsylvania ECE Computer Organization Lecture 17 - Pipelined.
Introduction to Pipelining Rabi Mahapatra Adapted from the lecture notes of Dr. John Kubiatowicz (UC Berkeley)
Lecture 24: CPU Design Today’s topic –Multi-Cycle ALU –Introduction to Pipelining 1.
9.2 Pipelining Suppose we want to perform the combined multiply and add operations with a stream of numbers: A i * B i + C i for i =1,2,3,…,7.
CS1104: Computer Organisation School of Computing National University of Singapore.
What have mr aldred’s dirty clothes got to do with the cpu
Pipelining (I). Pipelining Example  Laundry Example  Four students have one load of clothes each to wash, dry, fold, and put away  Washer takes 30.
ECE 456 Computer Architecture Lecture #14 – CPU (III) Instruction Cycle & Pipelining Instructor: Dr. Honggang Wang Fall 2013.
1 Designing a Pipelined Processor In this Chapter, we will study 1. Pipelined datapath 2. Pipelined control 3. Data Hazards 4. Forwarding 5. Branch Hazards.
ECE 232 L18.Pipeline.1 Adapted from Patterson 97 ©UCBCopyright 1998 Morgan Kaufmann Publishers ECE 232 Hardware Organization and Design Lecture 18 Pipelining.
CS 1104 Help Session IV Five Issues in Pipelining Colin Tan, S

Cs 152 L1 3.1 DAP Fa97,  U.CB Pipelining Lessons °Pipelining doesn’t help latency of single task, it helps throughput of entire workload °Multiple tasks.
Chap 6.1 Computer Architecture Chapter 6 Enhancing Performance with Pipelining.
CSIE30300 Computer Architecture Unit 04: Basic MIPS Pipelining Hsin-Chou Chi [Adapted from material by and
Oct. 18, 2000Machine Organization1 Machine Organization (CS 570) Lecture 4: Pipelining * Jeremy R. Johnson Wed. Oct. 18, 2000 *This lecture was derived.
Pipelining Example Laundry Example: Three Stages
Lecture 9. MIPS Processor Design – Pipelined Processor Design #1 Prof. Taeweon Suh Computer Science Education Korea University 2010 R&E Computer System.
Csci 136 Computer Architecture II – Superscalar and Dynamic Pipelining Xiuzhen Cheng
Chapter One Introduction to Pipelined Processors.
CSCI-365 Computer Organization Lecture Note: Some slides and/or pictures in the following are adapted from: Computer Organization and Design, Patterson.
Real-World Pipelines Idea Divide process into independent stages
Lecture 18: Pipelining I.
Pipelines An overview of pipelining
Review: Instruction Set Evolution
Performance of Single-cycle Design
Pipeline Implementation (4.6)
Chapter One Introduction to Pipelined Processors
CSCI206 - Computer Organization & Programming
CSCI206 - Computer Organization & Programming
CS 5513 Computer Architecture Pipelining Examples
Lecturer: Alan Christopher
Lecture 5: Pipelining Basics
Serial versus Pipelined Execution
CSCI206 - Computer Organization & Programming
Pipelining Chapter 6.
Chapter 8. Pipelining.
8086 processor.
Pipelining Appendix A and Chapter 3.
CS 3853 Computer Architecture Pipelining Examples
A relevant question Assuming you’ve got: One washer (takes 30 minutes)
Pipelining.
Presentation transcript:

CS 141 ChienMay 3, 1999 Concepts in Pipelining u Last Time –Midterm Exam, Grading in progress u Today –Concepts in Pipelining u Reminders/Announcements –Read P&H Chapter , Pipelining

CS 141 ChienMay 3, 1999 Complete Basic Computer Implementation u Constituents –Instruction Fetch –Decode –Read Registers –Execute –Write Registers u Single Cycle Control (slow...) u Multiple Cycle Control (Control FSM) u Exceptions u So, how can we make it go faster?

CS 141 ChienMay 3, 1999 Concepts of Pipelining u Latency = Time from initiation of an operation until its results are available u Examples –Adder: time from inputs valid to output valid –Memory: time from addresses valid, read strobe, to data out –Control logic: time from stable inputs to stable outputs –Others? u Macroscopic examples? (real life)

CS 141 ChienMay 3, 1999 Latency Examples (real life) u Line at McDonalds: 10 mins from entry to “have food” u Car ride SD -> LAX: 2.5 hours (or faster) u Homework grading: time from turn-in, to handed back (hopefully, < 1.5 week) u Turning tap on until water comes out of hose u Others?

CS 141 ChienMay 3, 1999 Throughput u Throughput = rate at which something happens or gets done. Generally the initiation rate or completion rate is fine. Usually OPs / unit time u Examples –Instructions per second (instruction processing throughput) –Floating point operations per second (floating point throughput) –Megabits per second (network throughput) –Megawords per second (memory read throughput) u Macroscopic examples?

CS 141 ChienMay 3, 1999 Throughput Examples u McDonalds, 10 people served per minute, –600 people get food in 1 hour! –Latency = 10 mins, how many people served while you wait? u Car Drive SD -> LAX, one car, 5 people, 2 people per hour –2.5 hours latency –Rate NOT same as latency u Homework grading, 100 homeworks per week –16.7 homeworks per day, but latency is still 1 week. =>Rate NOT same as latency, no direct relationship.

CS 141 ChienMay 3, 1999 Contrasting Latency and Throughput u Multiple Resources (Parallelism) 5 seconds to copy12 copies / minute All 3 machines: 5 secs to copy, 36 copies / minute 5 seconds to copy

CS 141 ChienMay 3, 1999 Latency versus Throughput  Replication only increases throughput, not latency. Throughput is additive, latency is min(x,y). u Latency is a critical commodity, and very expensive to improve. u Pipelining and replication only improve throughput. u Pipelining: the basic idea –Think “assembly line” –Breaking total work into small components –Each component can be “busy” doing useful work

CS 141 ChienMay 3, 1999 Pipelining u Washing Laundry: Washer + Dryer 30 minutes50 minutes Latency for a wash = = 80 minutes 2 loads ==> 160 minutes = 2 hrs, 40 minutes? Pipelined: start 1 wash, start second when first goes into the dryer.

CS 141 ChienMay 3, 1999 Pipelining u Washer and Dryer 30 minutes50 minutes Latency = 80 minutes Overlapped execution allows us to achieve loads in = 130 minutes, much faster! Throughput = 1 load / 50 minutes = 1.2 loads / hour Latency and Throughput are not reciprocals.

CS 141 ChienMay 3, 1999 Doing Pipelining Well u Issues for good performance? –Unrelated activities –Equal pipeline stages (all match clock) –Fast issue rate (short clock period) u What limits the performance improvement in our simple washer/dryer case? –granularity –moving the clothes –others? u How do these apply to computers? Instruction execution

CS 141 ChienMay 3, 1999 Pipelining Instruction Execution u Parts: Fetch, Decode/Rd, Exec, WriteResults –Overlap the parts –Overlap execution of several instructions –Increase instruction throughput –Doesn’t reduce instruction latency? –How does this relate to performance measures? »MIPS, Execution Time u When does the next instruction depend on the current one? –Uses value produced by current instruction –Current instruction is a branch –Otherwise, No problem!

CS 141 ChienMay 3, 1999 Pipelined Execution FetchdecodeexecuteMemReg FetchdecodeexecuteMemReg FetchdecodeexecuteMemReg FetchdecodeexecuteMemReg Op1 Op2 Op3 Op4 Latency or Pipeline load time 1 instruction per cycle AFTER pipeline is loaded

CS 141 ChienMay 3, 1999 Pipeline Hazards u There must be problems and pitfalls u Structural Hazard –Hardware cannot support two instructions simultaneously »e.g. either wash or dry, but not both »read or write memory, but not both u Control Hazard –Decision made by partially executed instruction affects currently loading instruction »May execute wrong code if branch taken »Later: Branch Prediction, Delayed Branching u Data Hazard –Current instruction depends on output of incomplete instruction ahead of it in the pipeline

CS 141 ChienMay 3, 1999 Summary u Throughput and Latency u Basics of Pipelining –Increases throughput –Doesn’t reduce latency –Can increase performance! u Next time: Applying pipelining to instruction execution.