# Software Pipelining - Modulo Scheduling

Save this PDF as:

Size: px
Start display at page:

## Transcription

1 EECS 583 Class 12 Software Pipelining - Modulo Scheduling University of Michigan October 15, 2014

2 Announcements + Reading Material HW 2 Due this Thursday Today s class reading» Iterative Modulo Scheduling: An Algorithm for Software Pipelining Loops, B. Rau, MICRO-27, 1994, pp Next next Wednesday s reading» Register Allocation and Spilling Via Graph Coloring, G. Chaitin, Proc SIGPLAN Symposium on Compiler Construction,

3 Homework Problem From Last Time Answer Machine: 2 issue, 1 memory port, 1 ALU Memory port = 2 cycles, pipelined ALU = 1 cycle 3,5 5 0,1 2, m , ,5 6, m 4m m 0,0 2,2 4,4 0,4 1. Calculate height-based priorities 2. Schedule using Operation scheduler Op priority RU_map time ALU MEM 0 X 1 X 2 X 3 X X 4 X 5 X 6 X 7 X 8 X Schedule Time Placed ,

4 Generalize Beyond a Basic Block Superblock» Single entry» Multiple exits (side exits)» No side entries Schedule just like a BB» Priority calculations needs change» Dealing with control deps - 3 -

5 Change Focus to Scheduling Loops Most of program execution time is spent in loops Problem: How do we achieve compact schedules for loops for (j=0; j<100; j++) b[j] = a[j] * 26 Loop: r1 = _a r2 = _b r9 = r1 * 4 1: r3 = load(r1) 2: r4 = r3 * 26 3: store (r2, r4) 4: r1 = r : r2 = r : p1 = cmpp (r1 < r9) 7: brct p1 Loop - 4 -

6 Basic Approach List Schedule the Loop Body time Iteration n Schedule each iteration resources: 4 issue, 2 alu, 1 mem, 1 br latencies: add=1, mpy=3, ld = 2, st = 1, br = 1 1: r3 = load(r1) 2: r4 = r3 * 26 3: store (r2, r4) 4: r1 = r : r2 = r : p1 = cmpp (r1 < r9) 7: brct p1 Loop time ops 0 1, , 5, 7 Total time = 6 * n - 5 -

7 Unroll Then Schedule Larger Body time Iteration 1,2 3,4 5,6 n-1,n Schedule each iteration resources: 4 issue, 2 alu, 1 mem, 1 br latencies: add=1, cmpp = 1, mpy=3, ld = 2, st = 1, br = 1 1: r3 = load(r1) 2: r4 = r3 * 26 3: store (r2, r4) 4: r1 = r : r2 = r : p1 = cmpp (r1 < r9) 7: brct p1 Loop time ops 0 1, 4 1 1, 6, 4 2 2, , 5, 7 6 3,5,7 Total time = 7 * n/2-6 -

8 Problems With Unrolling Code bloat» Typical unroll is 4-16x» Use profile statistics to only unroll important loops» But still, code grows fast Barrier after across unrolled bodies» I.e., for unroll 2, can only overlap iterations 1 and 2, 3 and 4, Does this mean unrolling is bad?» No, in some settings its very useful Ÿ Low trip count Ÿ Lots of branches in the loop body» But, in other settings, there is room for improvement - 7 -

9 Overlap Iterations Using Pipelining time Iteration n n With hardware pipelining, while one instruction is in fetch, another is in decode, another in execute. Same thing here, multiple iterations are processed simultaneously, with each instruction in a separate stage. 1 iteration still takes the same time, but time to complete n iterations is reduced! - 8 -

10 A Software Pipeline time A B A C B A Prologue - fill the pipe Loop body with 4 ops A B C D D C B A D C B A D C B A D C B D C D Kernel steady state Epilogue - drain the pipe Steady state: 4 iterations executed simultaneously, 1 operation from each iteration. Every cycle, an iteration starts and finishes when the pipe is full

11 Creating Software Pipelines Lots of software pipelining techniques out there Modulo scheduling» Most widely adopted» Practical to implement, yields good results Conceptual strategy» Unroll the loop completely» Then, schedule the code completely with 2 constraints Ÿ All iteration bodies have identical schedules Ÿ Each iteration is scheduled to start some fixed number of cycles later than the previous iteration» Initiation Interval (II) = fixed delay between the start of successive iterations» Given the 2 constraints, the unrolled schedule is repetitive (kernel) except the portion at the beginning (prologue) and end (epilogue) Ÿ Kernel can be re-rolled to yield a new loop

12 Creating Software Pipelines (2) Create a schedule for 1 iteration of the loop such that when the same schedule is repeated at intervals of II cycles» No intra-iteration dependence is violated» No inter-iteration dependence is violated» No resource conflict arises between operation in same or distinct iterations We will start out assuming Itanium-style hardware support, then remove it later» Rotating registers» Predicates» Software pipeline loop branch

13 Terminology time Iter 3 II Iter 2 Iter 1 Initiation Interval (II) = fixed delay between the start of successive iterations Each iteration can be divided into stages consisting of II cycles each Number of stages in 1 iteration is termed the stage count (SC) Takes SC-1 cycles to fill/drain the pipe

14 Resource Usage Legality Need to guarantee that» No resource is used at 2 points in time that are separated by an interval which is a multiple of II» I.E., within a single iteration, the same resource is never used more than 1x at the same time modulo II» Known as modulo constraint, where the name modulo scheduling comes from» Modulo reservation table solves this problem Ÿ To schedule an op at time T needing resource R The entry for R at T mod II must be free Ÿ Mark busy at T mod II if schedule II = alu1 alu2 mem bus0 bus1 br

15 Dependences in a Loop Need worry about 2 kinds» Intra-iteration» Inter-iteration Delay» Minimum time interval between the start of operations» Operation read/write times Distance» Number of iterations separating the 2 operations involved» Distance of 0 means intraiteration Recurrence manifests itself as a circuit in the dependence graph <1,2> <1,0> <1,1> <1,0> <1,2> Edges annotated with tuple <delay, distance>

16 Dynamic Single Assignment (DSA) Form Impossible to overlap iterations because each iteration writes to the same register. So, we ll have to remove the anti and output dependences. Virtual rotating registers * Each register is an infinite push down array (Expanded virtual reg or EVR) * Write to top element, but can reference any element * Remap operation slides everything down à r[n] changes to r[n+1] A program is in DSA form if the same virtual register (EVR element) is never assigned to more than 1x on any dynamic execution path 1: r3 = load(r1) 2: r4 = r3 * 26 3: store (r2, r4) 4: r1 = r : r2 = r : p1 = cmpp (r1 < r9) 7: brct p1 Loop DSA conversion : r3[-1] = load(r1[0]) 2: r4[-1] = r3[-1] * 26 3: store (r2[0], r4[-1]) 4: r1[-1] = r1[0] + 4 5: r2[-1] = r2[0] + 4 6: p1[-1] = cmpp (r1[-1] < r9) remap r1, r2, r3, r4, p1 7: brct p1[-1] Loop

17 Physical Realization of EVRs EVR may contain an unlimited number values» But, only a finite contiguous set of elements of an EVR are ever live at any point in time» These must be given physical registers Conventional register file» Remaps are essentially copies, so each EVR is realized by a set of physical registers and copies are inserted Rotating registers» Direct support for EVRs» No copies needed» File rotated after each loop iteration is completed

18 Loop Dependence Example 1,1 1: r3[-1] = load(r1[0]) 2: r4[-1] = r3[-1] * 26 3: store (r2[0], r4[-1]) 4: r1[-1] = r1[0] + 4 5: r2[-1] = r2[0] + 4 6: p1[-1] = cmpp (r1[-1] < r9) remap r1, r2, r3, r4, p1 7: brct p1[-1] Loop 0,0 3,0 1, ,0 0,0 1,1 1,1 1,1 In DSA form, there are no inter-iteration anti or output dependences! 6 1,0 7 <delay, distance>

19 Class Problem Latencies: ld = 2, st = 1, add = 1, cmpp = 1, br = 1 1: r1[-1] = load(r2[0]) 2: r3[-1] = r1[1] r1[2] 3: store (r3[-1], r2[0]) 4: r2[-1] = r2[0] + 4 5: p1[-1] = cmpp (r2[-1] < 100) remap r1, r2, r3 6: brct p1[-1] Loop Draw the dependence graph showing both intra and inter iteration dependences

20 Minimum Initiation Interval (MII) Remember, II = number of cycles between the start of successive iterations Modulo scheduling requires a candidate II be selected before scheduling is attempted» Try candidate II, see if it works» If not, increase by 1, try again repeating until successful MII is a lower bound on the II» MII = Max(ResMII, RecMII)» ResMII = resource constrained MII Ÿ Resource usage requirements of 1 iteration» RecMII = recurrence constrained MII Ÿ Latency of the circuits in the dependence graph

21 ResMII Concept: If there were no dependences between the operations, what is the the shortest possible schedule? Simple resource model A processor has a set of resources R. For each resource r in R there is count(r) specifying the number of identical copies ResMII = MAX for all r in R (uses(r) / count(r)) uses(r) = number of times the resource is used in 1 iteration In reality its more complex than this because operations can have multiple alternatives (different choices for resources it could be assigned to), but we will ignore this for now

22 ResMII Example resources: 4 issue, 2 alu, 1 mem, 1 br latencies: add=1, mpy=3, ld = 2, st = 1, br = 1 1: r3 = load(r1) 2: r4 = r3 * 26 3: store (r2, r4) 4: r1 = r : r2 = r : p1 = cmpp (r1 < r9) 7: brct p1 Loop ALU: used by 2, 4, 5, 6 à 4 ops / 2 units = 2 Mem: used by 1, 3 à 2 ops / 1 unit = 2 Br: used by 7 à 1 op / 1 unit = 1 ResMII = MAX(2,2,1) =

23 RecMII Approach: Enumerate all irredundant elementary circuits in the dependence graph RecMII = MAX for all c in C (delay(c) / distance(c)) delay(c) = total latency in dependence cycle c (sum of delays) distance(c) = total iteration distance of cycle c (sum of distances) 1, ,1 delay(c) = = 4 distance(c) = = 1 RecMII = 4/1 = 4 cycle k 1 1 k+1 2 k+2 k cycles, RecMII = 4 k+4 1 k

24 RecMII Example 1: r3 = load(r1) 2: r4 = r3 * 26 3: store (r2, r4) 4: r1 = r : r2 = r : p1 = cmpp (r1 < r9) 7: brct p1 Loop 0,0 3, ,0 0,0 1,1 1,1 1,1 4 à 4: 1 / 1 = 1 5 à 5: 1 / 1 = 1 4 à 1 à 4: 1 / 1 = 1 5 à 3 à 5: 1 / 1 = 1 RecMII = MAX(1,1,1,1) = 1 Then, 1,0 5 1,1 MII = MAX(ResMII, RecMII) MII = MAX(2,1) = 2 6 1,0 7 <delay, distance>

25 Class Problem Latencies: ld = 2, st = 1, add = 1, cmpp = 1, br = 1 Resources: 1 ALU, 1 MEM, 1 BR 1: r1[-1] = load(r2[0]) 2: r3[-1] = r1[1] r1[2] 3: store (r3[-1], r2[0]) 4: r2[-1] = r2[0] + 4 5: p1[-1] = cmpp (r2[-1] < 100) remap r1, r2, r3 6: brct p1[-1] Loop Calculate RecMII, ResMII, and MII

26 Modulo Scheduling Process Use list scheduling but we need a few twists» II is predetermined starts at MII, then is incremented» Cyclic dependences complicate matters Ÿ Estart/Priority/etc. Ÿ Consumer scheduled before producer is considered There is a window where something can be scheduled!» Guarantee the repeating pattern 2 constraints enforced on the schedule» Each iteration begin exactly II cycles after the previous one» Each time an operation is scheduled in 1 iteration, it is tentatively scheduled in subsequent iterations at intervals of II Ÿ MRT used for this

27 Priority Function Height-based priority worked well for acyclic scheduling, makes sense that it will work for loops as well Acyclic: Height(X) = 0, if X has no successors MAX ((Height(Y) + Delay(X,Y)), otherwise for all Y = succ(x) Cyclic: HeightR(X) = 0, if X has no successors MAX ((HeightR(Y) + EffDelay(X,Y)), otherwise for all Y = succ(x) EffDelay(X,Y) = Delay(X,Y) II*Distance(X,Y)

28 Calculating Height 1. Insert pseudo edges from all nodes to branch with latency = 0, distance = 0 (dotted edges) 2. Compute II, For this example assume II = 2 3. HeightR(4) = 4. HeightR(3) = 5. HeightR(2) = 0,0 3,0 0,0 2, ,0 1,1 2,2 6. HeightR(1)

29 The Scheduling Window With cyclic scheduling, not all the predecessors may be scheduled, so a more flexible earliest schedule time is: E(Y) = MAX for all X = pred(y) 0, if X is not scheduled MAX (0, SchedTime(X) + EffDelay(X,Y)), otherwise where EffDelay(X,Y) = Delay(X,Y) II*Distance(X,Y) Every II cycles a new loop iteration will be initialized, thus every II cycles the pattern will repeat. Thus, you only have to look in a window of size II, if the operation cannot be scheduled there, then it cannot be scheduled. Latest schedule time(y) = L(Y) = E(Y) + II

30 To be continued

### EECS 583 Class 11 Instruction Scheduling Software Pipelining Intro

EECS 58 Class Instruction Scheduling Software Pipelining Intro University of Michigan October 8, 04 Announcements & Reading Material Reminder: HW Class project proposals» Signup sheet available next Weds

### Software Pipelining. Y.N. Srikant. NPTEL Course on Compiler Design. Department of Computer Science Indian Institute of Science Bangalore 560 012

Department of Computer Science Indian Institute of Science Bangalore 560 2 NPTEL Course on Compiler Design Introduction to Overlaps execution of instructions from multiple iterations of a loop Executes

### Fli;' HEWLETT. Iterative Modulo Scheduling. B. Ramakrishna Rau Compiler and Architecture Research HPL-94-115 November, 1995

Fli;' HEWLETT a:~ PACKARD Iterative Modulo Scheduling B. Ramakrishna Rau Compiler and Architecture Research HPL-94-115 November, 1995 modulo scheduling, instruction scheduling, software pipelining, loop

### AN IMPLEMENTATION OF SWING MODULO SCHEDULING WITH EXTENSIONS FOR SUPERBLOCKS TANYA M. LATTNER

AN IMPLEMENTATION OF SWING MODULO SCHEDULING WITH EXTENSIONS FOR SUPERBLOCKS BY TANYA M. LATTNER B.S., University of Portland, 2000 THESIS Submitted in partial fulfillment of the requirements for the degree

### Module: Software Instruction Scheduling Part I

Module: Software Instruction Scheduling Part I Sudhakar Yalamanchili, Georgia Institute of Technology Reading for this Module Loop Unrolling and Instruction Scheduling Section 2.2 Dependence Analysis Section

### Administration. Instruction scheduling. Modern processors. Examples. Simplified architecture model. CS 412 Introduction to Compilers

CS 4 Introduction to Compilers ndrew Myers Cornell University dministration Prelim tomorrow evening No class Wednesday P due in days Optional reading: Muchnick 7 Lecture : Instruction scheduling pr 0 Modern

### To appear in MICRO-25 Conference Proceedings, December 1992 1. Enhanced Modulo Scheduling for Loops with Conditional Branches

To appear in MICRO-5 Conference Proceedings, December 199 1 Enhanced Modulo Scheduling for Loops with Conditional Branches Nancy J. Warter Grant E. Haab John W. Bockhaus Krishna Subramanian Coordinated

### THE FLORIDA STATE UNIVERSITY COLLEGE OF ARTS AND SCIENCES APPLICATION CONFIGURABLE PROCESSORS CHRISTOPHER J. ZIMMER

THE FLORIDA STATE UNIVERSITY COLLEGE OF ARTS AND SCIENCES APPLICATION CONFIGURABLE PROCESSORS By CHRISTOPHER J. ZIMMER A Thesis submitted to the Department of Computer Science In partial fulfillment of

### VLIW Processors. VLIW Processors

1 VLIW Processors VLIW ( very long instruction word ) processors instructions are scheduled by the compiler a fixed number of operations are formatted as one big instruction (called a bundle) usually LIW

### Instruction Scheduling. Software Pipelining - 2

and Software Pipelining - 2 Department of Computer Science and Automation Indian Institute of Science Bangalore 560 012 NPTEL Course on Principles of Compiler Design Outline Simple Basic Block Scheduling

### Software Pipelining by Modulo Scheduling. Philip Sweany University of North Texas

Software Pipelining by Modulo Scheduling Philip Sweany University of North Texas Overview Opportunities for Loop Optimization Software Pipelining Modulo Scheduling Resource and Dependence Constraints Scheduling

### A Brief Review of Processor Architecture. Why are Modern Processors so Complicated? Basic Structure

A Brief Review of Processor Architecture Why are Modern Processors so Complicated? Basic Structure CPU PC IR Regs ALU Memory Fetch PC -> Mem addr [addr] > IR PC ++ Decode Select regs Execute Perform op

### Software Pipelining: An Effective Scheduling Technique for VLIW Machines

Software Pipelining: An Effective Scheduling Technique for VLIW Machines Monica Lam Department of Computer Science Carnegie Mellon University Pittsburgh, Pennsylvania 15213 Abstract This paper shows that

### Hiding Memory Access Latency in Software Pipelining

1000-9825/2005/16(10)1833 2005 Journal of Software Vol16, No10 1+, 2, 1, 1 1, 1 (, 100084) 2 (Intel, 100080) Hiding Memory Access Latency in Software Pipelining LIU Li 1+, LI Wen-Long 2, CHEN Yu 1, LI

### Software Programmable DSP Platform Analysis Episode 7, Monday 19 March 2007, Ingredients. Software Pipelining. Data Dependence. Resource Constraints

Software Programmable DSP Platform Analysis Episode 7, Monday 19 March 7, Ingredients Software Pipelining Data & Resource Constraints Resource Constraints in C67x Loop Scheduling Without Resource Bounds

### On some Potential Research Contributions to the Multi-Core Enterprise

On some Potential Research Contributions to the Multi-Core Enterprise Oded Maler CNRS - VERIMAG Grenoble, France February 2009 Background This presentation is based on observations made in the Athole project

### Q. Consider a dynamic instruction execution (an execution trace, in other words) that consists of repeats of code in this pattern:

Pipelining HW Q. Can a MIPS SW instruction executing in a simple 5-stage pipelined implementation have a data dependency hazard of any type resulting in a nop bubble? If so, show an example; if not, prove

### A high-level implementation of software pipelining in LLVM

A high-level implementation of software pipelining in LLVM Roel Jordans 1, David Moloney 2 1 Eindhoven University of Technology, The Netherlands r.jordans@tue.nl 2 Movidius Ltd., Ireland 2015 European

### A Comparison Of Shared Memory Parallel Programming Models. Jace A Mogill David Haglin

A Comparison Of Shared Memory Parallel Programming Models Jace A Mogill David Haglin 1 Parallel Programming Gap Not many innovations... Memory semantics unchanged for over 50 years 2010 Multi-Core x86

### AN IMPLEMENTATION OF SWING MODULO SCHEDULING WITH EXTENSIONS FOR SUPERBLOCKS TANYA M. LATTNER. B.S., University of Portland, 2000 THESIS

AN IMPLEMENTATION OF SWING MODULO SCHEDULING WITH EXTENSIONS FOR SUPERBLOCKS BY TANYA M. LATTNER B.S., University of Portland, 2000 THESIS Submitted in partial fulfillment of the requirements for the degree

### Solution: start more than one instruction in the same clock cycle CPI < 1 (or IPC > 1, Instructions per Cycle) Two approaches:

Multiple-Issue Processors Pipelining can achieve CPI close to 1 Mechanisms for handling hazards Static or dynamic scheduling Static or dynamic branch handling Increase in transistor counts (Moore s Law):

### Why? A central concept in Computer Science. Algorithms are ubiquitous.

Analysis of Algorithms: A Brief Introduction Why? A central concept in Computer Science. Algorithms are ubiquitous. Using the Internet (sending email, transferring files, use of search engines, online

### INSTRUCTION LEVEL PARALLELISM PART VII: REORDER BUFFER

Course on: Advanced Computer Architectures INSTRUCTION LEVEL PARALLELISM PART VII: REORDER BUFFER Prof. Cristina Silvano Politecnico di Milano cristina.silvano@polimi.it Prof. Silvano, Politecnico di Milano

### Static Scheduling. option #1: dynamic scheduling (by the hardware) option #2: static scheduling (by the compiler) ECE 252 / CPS 220 Lecture Notes

basic pipeline: single, in-order issue first extension: multiple issue (superscalar) second extension: scheduling instructions for more ILP option #1: dynamic scheduling (by the hardware) option #2: static

### Architecture of Hitachi SR-8000

Architecture of Hitachi SR-8000 University of Stuttgart High-Performance Computing-Center Stuttgart (HLRS) www.hlrs.de Slide 1 Most of the slides from Hitachi Slide 2 the problem modern computer are data

### A STUDY OF TASK SCHEDULING IN MULTIPROCESSOR ENVIROMENT Ranjit Rajak 1, C.P.Katti 2, Nidhi Rajak 3

A STUDY OF TASK SCHEDULING IN MULTIPROCESSOR ENVIROMENT Ranjit Rajak 1, C.P.Katti, Nidhi Rajak 1 Department of Computer Science & Applications, Dr.H.S.Gour Central University, Sagar, India, ranjit.jnu@gmail.com

### Instruction scheduling

Instruction ordering Instruction scheduling Advanced Compiler Construction Michel Schinz 2015 05 21 When a compiler emits the instructions corresponding to a program, it imposes a total order on them.

### Throughput constraint for Synchronous Data Flow Graphs

Throughput constraint for Synchronous Data Flow Graphs *Alessio Bonfietti Michele Lombardi Michela Milano Luca Benini!"#\$%&'()*+,-)./&0&20304(5 60,7&-8990,.+:&;/&."!?@A>&"'&=,0B+C. !"#\$%&'()* Resource

### IA-64 Application Developer s Architecture Guide

IA-64 Application Developer s Architecture Guide The IA-64 architecture was designed to overcome the performance limitations of today s architectures and provide maximum headroom for the future. To achieve

### FPGA area allocation for parallel C applications

1 FPGA area allocation for parallel C applications Vlad-Mihai Sima, Elena Moscu Panainte, Koen Bertels Computer Engineering Faculty of Electrical Engineering, Mathematics and Computer Science Delft University

### Introduction to Data-flow analysis

Introduction to Data-flow analysis Last Time LULESH intro Typed, 3-address code Basic blocks and control flow graphs LLVM Pass architecture Data dependencies, DU chains, and SSA Today CFG and SSA example

### GameTime: A Toolkit for Timing Analysis of Software

GameTime: A Toolkit for Timing Analysis of Software Sanjit A. Seshia and Jonathan Kotker EECS Department, UC Berkeley {sseshia,jamhoot}@eecs.berkeley.edu Abstract. Timing analysis is a key step in the

### Clustering and scheduling maintenance tasks over time

Clustering and scheduling maintenance tasks over time Per Kreuger 2008-04-29 SICS Technical Report T2008:09 Abstract We report results on a maintenance scheduling problem. The problem consists of allocating

### Goals of the Unit. spm - 2014 adolfo villafiorita - introduction to software project management

Project Scheduling Goals of the Unit Making the WBS into a schedule Understanding dependencies between activities Learning the Critical Path technique Learning how to level resources!2 Initiate Plan Execute

### Fli;' HEWLETT. Software Pipelining and Superblock Scheduling: Compilation Techniques for VLIW Machines

Fli;' HEWLETT a:~ PACKARD Software Pipelining and Superblock Scheduling: Compilation Techniques for VLIW Machines Meng Lee, Partha Tirumalai, Tin-Fook Ngai Computer Systems Laboratory HPL-92-78 June, 1992

### Register Allocation and Optimal Spill Code Scheduling in Software Pipelined Loops Using 0-1 Integer Linear Programming Formulation

Register Allocation and Optimal Spill Code Scheduling in Software Pipelined Loops Using -1 Integer Linear Programming Formulation Santosh G. Nagarakatte 1 and R. Govindarajan 1,2 1 Department of Computer

### FLIX: Fast Relief for Performance-Hungry Embedded Applications

FLIX: Fast Relief for Performance-Hungry Embedded Applications Tensilica Inc. February 25 25 Tensilica, Inc. 25 Tensilica, Inc. ii Contents FLIX: Fast Relief for Performance-Hungry Embedded Applications...

### Real-time Process Network Sonar Beamformer

Real-time Process Network Sonar Gregory E. Allen Applied Research Laboratories gallen@arlut.utexas.edu Brian L. Evans Dept. Electrical and Computer Engineering bevans@ece.utexas.edu The University of Texas

### CS521 CSE IITG 11/23/2012

CS521 CSE TG 11/23/2012 A Sahu 1 Degree of overlap Serial, Overlapped, d, Super pipelined/superscalar Depth Shallow, Deep Structure Linear, Non linear Scheduling of operations Static, Dynamic A Sahu slide

### Instruction Set Design

Instruction Set Design Instruction Set Architecture: to what purpose? ISA provides the level of abstraction between the software and the hardware One of the most important abstraction in CS It s narrow,

### CPU Organization and Assembly Language

COS 140 Foundations of Computer Science School of Computing and Information Science University of Maine October 2, 2015 Outline 1 2 3 4 5 6 7 8 Homework and announcements Reading: Chapter 12 Homework:

### UNIVERSITY OF CALIFORNIA, DAVIS Department of Electrical and Computer Engineering. EEC180B Lab 7: MISP Processor Design Spring 1995

UNIVERSITY OF CALIFORNIA, DAVIS Department of Electrical and Computer Engineering EEC180B Lab 7: MISP Processor Design Spring 1995 Objective: In this lab, you will complete the design of the MISP processor,

### Post-Pass Periodic Register Allocation to Minimise Loop Unrolling Degree

Post-Pass Periodic Register Allocation to Minimise Loop Unrolling Degree Mounira BACHIR, Sid-Ahmed-Ali TOUATI, Albert COHEN April 10, 2009 Abstract This paper solves an open problem regarding loop unrolling

### Parallel Compression and Decompression of DNA Sequence Reads in FASTQ Format

, pp.91-100 http://dx.doi.org/10.14257/ijhit.2014.7.4.09 Parallel Compression and Decompression of DNA Sequence Reads in FASTQ Format Jingjing Zheng 1,* and Ting Wang 1, 2 1,* Parallel Software and Computational

### Software Pipelining. for (i=1, i<100, i++) { x := A[i]; x := x+1; A[i] := x

Software Pipelining for (i=1, i

### TDT 4260 lecture 11 spring semester 2013. Interconnection network continued

1 TDT 4260 lecture 11 spring semester 2013 Lasse Natvig, The CARD group Dept. of computer & information science NTNU 2 Lecture overview Interconnection network continued Routing Switch microarchitecture

### Optimizing Parallel Reduction in CUDA. Mark Harris NVIDIA Developer Technology

Optimizing Parallel Reduction in CUDA Mark Harris NVIDIA Developer Technology Parallel Reduction Common and important data parallel primitive Easy to implement in CUDA Harder to get it right Serves as

### Pipelining Review and Its Limitations

Pipelining Review and Its Limitations Yuri Baida yuri.baida@gmail.com yuriy.v.baida@intel.com October 16, 2010 Moscow Institute of Physics and Technology Agenda Review Instruction set architecture Basic

### forexploitingilpwithinloops,whichcaneectivelyoverlaptheexecutionofoperationsfrom

SoftwarePipeliningwithRegisterAllocationandSpilling M.AntonErtlChristineEisenbeisz InstitutfurComputersprachen TechnischeUniversitatWien JianWangyAndreasKrall A-040Wien,Austria Argentinierstr.8 (RRG)whichcandynamicallyreecttheregisterrequirementduringsoftwarepipelining.

### Introduction to Scheduling Theory

Introduction to Scheduling Theory Arnaud Legrand Laboratoire Informatique et Distribution IMAG CNRS, France arnaud.legrand@imag.fr November 8, 2004 1/ 26 Outline 1 Task graphs from outer space 2 Scheduling

### (Refer Slide Time: 00:01:16 min)

Digital Computer Organization Prof. P. K. Biswas Department of Electronic & Electrical Communication Engineering Indian Institute of Technology, Kharagpur Lecture No. # 04 CPU Design: Tirning & Control

### Contents. System Development Models and Methods. Design Abstraction and Views. Synthesis. Control/Data-Flow Models. System Synthesis Models

System Development Models and Methods Dipl.-Inf. Mirko Caspar Version: 10.02.L.r-1.0-100929 Contents HW/SW Codesign Process Design Abstraction and Views Synthesis Control/Data-Flow Models System Synthesis

### Control Flow Testing

Control low esting Structural esting In structural testing, the software is viewed as a white box and test cases are determined from the implementation of the software. Structural testing techniques include

More on Pipelining and Pipelines in Real Machines CS 333 Fall 2006 Main Ideas Data Hazards RAW WAR WAW More pipeline stall reduction techniques Branch prediction» static» dynamic bimodal branch prediction

### Scalability and Classifications

Scalability and Classifications 1 Types of Parallel Computers MIMD and SIMD classifications shared and distributed memory multicomputers distributed shared memory computers 2 Network Topologies static

### Scheduling. Open shop, job shop, flow shop scheduling. Related problems. Open shop, job shop, flow shop scheduling

Scheduling Basic scheduling problems: open shop, job shop, flow job The disjunctive graph representation Algorithms for solving the job shop problem Computational complexity of the job shop problem Open

### EVALUATION OF SCHEDULING AND ALLOCATION ALGORITHMS WHILE MAPPING ASSEMBLY CODE ONTO FPGAS

EVALUATION OF SCHEDULING AND ALLOCATION ALGORITHMS WHILE MAPPING ASSEMBLY CODE ONTO FPGAS ABSTRACT Migration of software from older general purpose embedded processors onto newer mixed hardware/software

### Architectures and Platforms

Hardware/Software Codesign Arch&Platf. - 1 Architectures and Platforms 1. Architecture Selection: The Basic Trade-Offs 2. General Purpose vs. Application-Specific Processors 3. Processor Specialisation

### Lecture 2 Introduction to Data Flow Analysis

Lecture 2 Introduction to Data Flow Analysis I. Introduction II. Example: Reaching definition analysis III. Example: Liveness analysis IV. A General Framework (Theory in next lecture) Reading: Chapter

WAR: Write After Read write-after-read (WAR) = artificial (name) dependence add R1, R2, R3 sub R2, R4, R1 or R1, R6, R3 problem: add could use wrong value for R2 can t happen in vanilla pipeline (reads

### Register Allocation for Software Pipelined Multidimensional Loops

Register Allocation for Software Pipelined Multidimensional Loops HONGBO RONG Microsoft Corporation ALBAN DOUILLET Hewlett-Packard Co. and GUANG R. GAO University of Delaware This article investigates

### ! Solve problem to optimality. ! Solve problem in poly-time. ! Solve arbitrary instances of the problem. !-approximation algorithm.

Approximation Algorithms Chapter Approximation Algorithms Q Suppose I need to solve an NP-hard problem What should I do? A Theory says you're unlikely to find a poly-time algorithm Must sacrifice one of

### Chapter 5: Sequential Circuits (LATCHES)

Chapter 5: Sequential Circuits (LATCHES) Latches We focuses on sequential circuits, where we add memory to the hardware that we ve already seen Our schedule will be very similar to before: We first show

### PROBLEMS. which was discussed in Section 1.6.3.

22 CHAPTER 1 BASIC STRUCTURE OF COMPUTERS (Corrisponde al cap. 1 - Introduzione al calcolatore) PROBLEMS 1.1 List the steps needed to execute the machine instruction LOCA,R0 in terms of transfers between

### Introduction to Cloud Computing

Introduction to Cloud Computing Parallel Processing I 15 319, spring 2010 7 th Lecture, Feb 2 nd Majd F. Sakr Lecture Motivation Concurrency and why? Different flavors of parallel computing Get the basic

### This Unit: Floating Point Arithmetic. CIS 371 Computer Organization and Design. Readings. Floating Point (FP) Numbers

This Unit: Floating Point Arithmetic CIS 371 Computer Organization and Design Unit 7: Floating Point App App App System software Mem CPU I/O Formats Precision and range IEEE 754 standard Operations Addition

### 2) Write in detail the issues in the design of code generator.

COMPUTER SCIENCE AND ENGINEERING VI SEM CSE Principles of Compiler Design Unit-IV Question and answers UNIT IV CODE GENERATION 9 Issues in the design of code generator The target machine Runtime Storage

### Dynamic programming formulation

1.24 Lecture 14 Dynamic programming: Job scheduling Dynamic programming formulation To formulate a problem as a dynamic program: Sort by a criterion that will allow infeasible combinations to be eli minated

### Small Maximal Independent Sets and Faster Exact Graph Coloring

Small Maximal Independent Sets and Faster Exact Graph Coloring David Eppstein Univ. of California, Irvine Dept. of Information and Computer Science The Exact Graph Coloring Problem: Given an undirected

### Parametric Analysis of Mobile Cloud Computing using Simulation Modeling

Parametric Analysis of Mobile Cloud Computing using Simulation Modeling Arani Bhattacharya Pradipta De Mobile System and Solutions Lab (MoSyS) The State University of New York, Korea (SUNY Korea) StonyBrook

### Basic CPM Calculations

Overview Core Scheduling Papers: #7 Basic CPM Calculations Time Analysis calculations in a Precedence Diagramming Method (PDM) Critical Path Method (CPM) network can be done in a number of different ways.

CSE / Notes : Task Scheduling & Load Balancing Task Scheduling A task is a (sequential) activity that uses a set of inputs to produce a set of outputs. A task (precedence) graph is an acyclic, directed

### Register File, Finite State Machines & Hardware Control Language

Register File, Finite State Machines & Hardware Control Language Avin R. Lebeck Some slides based on those developed by Gershon Kedem, and by Randy Bryant and ave O Hallaron Compsci 04 Administrivia Homework

Load Balancing Backtracking, branch & bound and alpha-beta pruning: how to assign work to idle processes without much communication? Additionally for alpha-beta pruning: implementing the young-brothers-wait

### Introduction to LAN/WAN. Network Layer

Introduction to LAN/WAN Network Layer Topics Introduction (5-5.1) Routing (5.2) (The core) Internetworking (5.5) Congestion Control (5.3) Network Layer Design Isues Store-and-Forward Packet Switching Services

### Graph Database Proof of Concept Report

Objectivity, Inc. Graph Database Proof of Concept Report Managing The Internet of Things Table of Contents Executive Summary 3 Background 3 Proof of Concept 4 Dataset 4 Process 4 Query Catalog 4 Environment

Advanced Pipelining Techniques 1. Dynamic Scheduling 2. Loop Unrolling 3. Software Pipelining 4. Dynamic Branch Prediction Units 5. Register Renaming 6. Superscalar Processors 7. VLIW (Very Large Instruction

### High Performance Computing for Operation Research

High Performance Computing for Operation Research IEF - Paris Sud University claude.tadonki@u-psud.fr INRIA-Alchemy seminar, Thursday March 17 Research topics Fundamental Aspects of Algorithms and Complexity

### System-Level Performance Analysis for Designing On-Chip Communication Architectures

768 IEEE TRANSACTIONS ON COMPUTER-AIDED DESIGN OF INTEGRATED CIRCUITS AND SYSTEMS, VOL. 20, NO. 6, JUNE 2001 System-Level Performance Analysis for Designing On-Chip Communication Architectures Kanishka

### This Unit: Code Scheduling. CIS 371 Computer Organization and Design. Pipelining Review. Readings. ! Pipelining and superscalar review

This Unit: Code Scheduling CIS 371 Computer Organization and Design App App App System software Mem CPU I/O! Pipelining and superscalar review! Code scheduling! To reduce pipeline stalls! To increase ILP

### Annotation to the assignments and the solution sheet. Note the following points

Computer rchitecture 2 / dvanced Computer rchitecture Seite: 1 nnotation to the assignments and the solution sheet This is a multiple choice examination, that means: Solution approaches are not assessed

### Project and Production Management Prof. Arun Kanda Department of Mechanical Engineering Indian Institute of Technology, Delhi

Project and Production Management Prof. Arun Kanda Department of Mechanical Engineering Indian Institute of Technology, Delhi Lecture - 15 Limited Resource Allocation Today we are going to be talking about

### Cloud and Big Data Summer School, Stockholm, Aug. 2015 Jeffrey D. Ullman

Cloud and Big Data Summer School, Stockholm, Aug. 2015 Jeffrey D. Ullman 2 In a DBMS, input is under the control of the programming staff. SQL INSERT commands or bulk loaders. Stream management is important

### Operating Systems. Virtual Memory

Operating Systems Virtual Memory Virtual Memory Topics. Memory Hierarchy. Why Virtual Memory. Virtual Memory Issues. Virtual Memory Solutions. Locality of Reference. Virtual Memory with Segmentation. Page

### System Interconnect Architectures. Goals and Analysis. Network Properties and Routing. Terminology - 2. Terminology - 1

System Interconnect Architectures CSCI 8150 Advanced Computer Architecture Hwang, Chapter 2 Program and Network Properties 2.4 System Interconnect Architectures Direct networks for static connections Indirect

### picojava TM : A Hardware Implementation of the Java Virtual Machine

picojava TM : A Hardware Implementation of the Java Virtual Machine Marc Tremblay and Michael O Connor Sun Microelectronics Slide 1 The Java picojava Synergy Java s origins lie in improving the consumer

### Lecture 8: Routing I Distance-vector Algorithms. CSE 123: Computer Networks Stefan Savage

Lecture 8: Routing I Distance-vector Algorithms CSE 3: Computer Networks Stefan Savage This class New topic: routing How do I get there from here? Overview Routing overview Intra vs. Inter-domain routing

### PROBLEMS #20,R0,R1 #\$3A,R2,R4

506 CHAPTER 8 PIPELINING (Corrisponde al cap. 11 - Introduzione al pipelining) PROBLEMS 8.1 Consider the following sequence of instructions Mul And #20,R0,R1 #3,R2,R3 #\$3A,R2,R4 R0,R2,R5 In all instructions,

### Lecture 10 Partial Redundancy Elimination

References Lecture 10 Partial Redundancy Elimination Global code motion optimization Remove partially redundant expressions Loop invariant code motion Can be extended to do Strength Reduction No loop analysis

Load Balancing Techniques 1 Lecture Outline Following Topics will be discussed Static Load Balancing Dynamic Load Balancing Mapping for load balancing Minimizing Interaction 2 1 Load Balancing Techniques

### CSE 504: Compiler Design. Data Flow Analysis

Data Flow Analysis Pradipta De pradipta.de@sunykorea.ac.kr Current Topic Iterative Data Flow Analysis LiveOut sets Static Single Assignment (SSA) Form Data Flow Analysis Techniques to reason about runtime

### I. ADDITIONAL EVALUATION RESULTS. A. Environment

1 A. Environment I. ADDITIONAL EVALUATION RESULTS The tests have been performed in a virtualized environment with Mininet 1.0.0 [?]. Mininet is tool to create a virtual network running actual kernel, switch

### CS5460: Operating Systems

CS5460: Operating Systems Lecture 13: Memory Management (Chapter 8) Where are we? Basic OS structure, HW/SW interface, interrupts, scheduling Concurrency Memory management Storage management Other topics

### 4.2 Description of the Event operation Network (EON)

Integrated support system for planning and scheduling... 2003/4/24 page 39 #65 Chapter 4 The EON model 4. Overview The present thesis is focused in the development of a generic scheduling framework applicable

### Computer Architecture

Computer Architecture Having studied numbers, combinational and sequential logic, and assembly language programming, we begin the study of the overall computer system. The term computer architecture is

### CCPM: TOC Based Project Management Technique

CCPM: TOC Based Project Management Technique Prof. P.M. Chawan, Ganesh P. Gaikwad, Prashant S. Gosavi M. Tech, Computer Engineering, VJTI, Mumbai. Abstract In this paper, we are presenting the drawbacks

### 18-742 Lecture 4. Parallel Programming II. Homework & Reading. Page 1. Projects handout On Friday Form teams, groups of two

age 1 18-742 Lecture 4 arallel rogramming II Spring 2005 rof. Babak Falsafi http://www.ece.cmu.edu/~ece742 write X Memory send X Memory read X Memory Slides developed in part by rofs. Adve, Falsafi, Hill,

### Scheduling. Monday, November 22, 2004

Scheduling Page 1 Scheduling Monday, November 22, 2004 11:22 AM The scheduling problem (Chapter 9) Decide which processes are allowed to run when. Optimize throughput, response time, etc. Subject to constraints