Overview of 15-740

Total Page:16

File Type:pdf, Size:1020Kb

Overview of 15-740 Vector Computers and GPUs 15-740 FALL’18 NATHAN BECKMANN BASED ON SLIDES BY DANIEL SANCHEZ, MIT 1 Today: Vector/GPUs Focus on throughput, not latency Programmer/compiler must expose parallel work directly Works on regular, replicated codes (i.e., data parallel / SIMD) 2 Background: Supercomputer Applications Typical application areas ◦ Military research (nuclear weapons aka “computational fluid dynamics”, cryptography) ◦ Scientific research ◦ Weather forecasting ◦ Oil exploration ◦ Industrial design (car crash simulation) ◦ Bioinformatics ◦ Cryptography All involve huge computations on large data sets In 70s-80s, Supercomputer Vector Machine 4 Vector Supercomputers Epitomized by Cray-1, 1976: Scalar Unit ◦ Load/Store Architecture Vector Extension ◦ Vector Registers ◦ Vector Instructions Implementation ◦ Hardwired Control ◦ Highly Pipelined Functional Units ◦ Interleaved Memory System ◦ No Data Caches ◦ No Virtual Memory 5 Cray-1 (1976) Vector registers V0 V1 V. Mask V2 V3 V. Length V4 V5 V6 V7 FP Add S0 FP Mul S1 Single Port S2 Primary FP Recip Temporary S3 Memory data 64 S4 data Int Add High- T Regs S5 registers registers S6 Int Logic bandwidth 16 banks of S7 memory Int Shift 64-bit words A0 A1 Pop Cnt A2 Primary Temporary A3 64 A4 address Addr Add address A5 B Regs A6 registers Addr Mul registers A7 64-bitx16 NIP CIP memory bank 4 Instruction LIP cycle 50 ns Buffers processor cycle 12.5 ns (80MHz) 7 Vector Programming Model Scalar Registers Vector Registers r15 v15 r0 v0 [0] [1] [2] [VLRMAX-1] Vector Length Register VLR 9 Vector Programming Model Scalar Registers Vector Registers r15 v15 r0 v0 [0] [1] [2] [VLRMAX-1] Vector Length Register VLR v1 Vector Arithmetic v2 Instructions + + + + + + ADDV v3, v1, v2 v3 [0] [1] [VLR-1] 10 Vector Programming Model Scalar Registers Vector Registers r15 v15 r0 v0 [0] [1] [2] [VLRMAX-1] Vector Length Register VLR Vector Load and Vector Register Store Instructions v1 LV v1, r1, r2 Memory Base, r1 Stride, r2 11 Vector Code Example # C code # Scalar Code # Vector Code for (i=0; i<64; i++) LI R4, 64 LI VLR, 64 C[i] = A[i] + B[i]; loop: LI R4, 4 LD F0, 0(R1) LV V1, R1, R4 LD F2, 0(R2) LV V2, R2, R4 ADD F4, F2, F0 ADDV V3, V1, V2 ST F4, 0(R3) SV V3, R3, R4 ADD R1, R1, 8 ADD R2, R2, 8 ADD R3, R3, 8 SUB R4, R4, 1 BNEZ R4, loop What if we want to execute larger loops than the vector registers? 12 Vector Stripmining Problem: Vector registers are finite Solution: Break loops into chunks that fit into registers, “stripmining” for (i=0; i<N; i++) LI R1, N # R1 is ops left to perform C[i] = A[i]+B[i]; LI R2, 8 # R2 is stride loop: VSETVLR R3, R1 # R3 = ops done A B C # = min(VLRMAX, R1) + Remainder LV V1, RA, R2 # Inner loop using vector LV V2, RB, R2 VADD V3, V1, V2 + 64 elements SV V3, RC, R2 SLL R3, R3, 3 # R3 = R3 * 8 ADD RA, RA, R3 # Lots of pointer updates ADD RB, RB, R3 ADD RC, RC, R3 + 64 elements SUB R1, R1, R3 # Any more to do? BNEZ R1, loop 13 Vector Stripmining Problem: Vector registers are finite Solution: Break loops into chunks that fit into registers, “stripmining” for (i=0; i<N; i++) LI R1, N # R1 is ops left to perform C[i] = A[i]+B[i]; LI R2, 8 # R2 is stride loop: VSETVLR R3, R1 # R3 = ops done A B C # = min(VLRMAX, R1) + Remainder LV V1, RA, R2 # Inner loop using vector LV V2, RB, R2 VADD V3, V1, V2 + 64 elements SV V3, RC, R2 SLL R3, R3, 3 # R3 = R3 * 8 ADD RA, RA, R3 # Lots of pointer updates ADD RB, RB, R3 ADD RC, RC, R3 + 64 elements SUB R1, R1, R3 # Any more to do? BNEZ R1, loop 14 Vector Instruction Set Advantages Compact ◦ one short instruction encodes N operations Expressive, tells hardware that these N operations: ◦ are independent ◦ use the same functional unit ◦ access disjoint registers ◦ access registers in same pattern as previous instructions ◦ access a contiguous block of memory (unit-stride load/store) ◦ access memory in a known pattern (strided load/store) Scalable & (somewhat) portable ◦ can run same code on more parallel pipelines (lanes) 15 Vector Arithmetic Execution Use deep pipeline to execute element operations ◦ Deep pipeline Fast clock! V V V Much simpler pipeline control! 1 2 3 ◦ Operations are independent no pipeline hazards Vector maximizes advantages of pipelining and avoids its downsides Six stage multiply pipeline V3 <- V1 * V2 16 Vector Instruction Execution Vector machine can microarchitecturally vary the number of “lanes” Execution using Execution using one pipelined ADDV C,A,B four pipelined functional unit functional units A[6] B[6] A[24] B[24] A[25] B[25] A[26] B[26] A[27] B[27] A[5] B[5] A[20] B[20] A[21] B[21] A[22] B[22] A[23] B[23] A[4] B[4] A[16] B[16] A[17] B[17] A[18] B[18] A[19] B[19] A[3] B[3] A[12] B[12] A[13] B[13] A[14] B[14] A[15] B[15] C[2] C[8] C[9] C[10] C[11] C[1] C[4] C[5] C[6] C[7] C[0] C[0] C[1] C[2] C[3] 17 Registers are kept nearby functional units to Vector Unit Structure minimize data movement. Functional Unit Vector Registers Elements Elements Elements Elements 0, 4, 8, … 1, 5, 9, … 2, 6, 10, … 3, 7, 11, … Lane Memory Subsystem 18 Vector Memory System Challenge is bandwidth aggressive banking Cray-1: 16 banks, 4 cycle bank busy time, 12 cycle latency ◦ More on this in GPUs… Base Stride Vector Registers Address Generator + 0 1 2 3 4 5 6 7 8 9 A B C D E F Memory Banks 19 Vector Chaining Vector analog of bypassing V V V V V LV v1 1 2 3 4 5 MULV v3,v1,v2 ADDV v5, v3, v4 Chain Chain Load Unit Mult. Add Memory 20 Vector Chaining Advantage • Without chaining, must wait for last element of result to be written before starting dependent instruction Load Mul Time Add • With chaining, can start dependent instruction as soon as first result appears Load Mul Add 21 Vector Instruction-Level Parallelism Can overlap execution of multiple vector instructions ◦ Example machine has 32 elements per vector register and 8 lanes Load Unit Multiply Unit Add Unit load mul add time load mul add Instruction issue Complete 24 operations/cycle while issuing <1 short instruction/cycle 22 Vector Conditional Execution Problem: Want to vectorize loops with conditional code: ◦ for (i=0; i<N; i++) if (A[i]>0) A[i] = B[i]; Solution: Add vector mask (or flag) registers ◦ vector version of predicate registers, 1 bit per element …and maskable vector instructions ◦ vector operation becomes NOP at elements where mask bit is clear Code example: ◦ CVM # Turn on all elements LV vA, rA # Load entire A vector SGTV vA, F0 # Set bits in mask register where A>0 LV vA, rB # Load B vector into A under mask SV vA, rA # Store A back to memory under mask 23 Masked Vector Instructions Simple Implementation Efficient Implementation – execute all N operations, turn off result – scan mask vector and only execute writeback according to mask elements with non-zero masks M[7]=1 A[7] B[7] M[7]=1 M[6]=0 A[6] B[6] M[6]=0 A[7] B[7] M[5]=1 A[5] B[5] M[5]=1 M[4]=1 A[4] B[4] M[4]=1 M[3]=0 A[3] B[3] M[3]=0 C[5] M[2]=0 C[4] M[1]=1 M[2]=0 C[2] M[0]=0 M[1]=1 C[1] C[1] Write data port M[0]=0 C[0] Write Enable Write data port 24 Vector Scatter/Gather Want to vectorize loops with indirect accesses: for (i=0; i<N; i++) A[i] = B[i] + C[D[i]] Indexed load instruction (Gather) LV vD, rD # Load indices in D vector LVI vC, rC, vD # Load indirect from rC base LV vB, rB # Load B vector ADDV vA, vB, vC # Do add SV vA, rA # Store result 25 Vector Scatter/Gather Scatter example: for (i=0; i<N; i++) A[B[i]]++; Is following a correct translation? LV vB, rB # Load indices in B vector LVI vA, rA, vB # Gather initial A values ADDV vA, vA, 1 # Increment SVI vA, rA, vB # Scatter incremented values 26 Multimedia Extensions Short vectors added to existing general-purpose ISAs Initially, 64-bit registers split into 2x32b or 4x16b or 8x8b Limited instruction set: ◦ No vector length control ◦ No strided load/store or scatter/gather ◦ Unit-stride loads must be aligned to 64-bit boundary Limitation: Short vector registers ◦ Requires superscalar dispatch to keep multiply/add/load units busy ◦ Loop unrolling to hide latencies increases register pressure Trend towards fuller vector support in microprocessors ◦ e.g. x86: MMX SSEx (128 bits) AVX (256 bits) AVX-512 (512 bits) 28 Intel Larrabee Motivation Design experiment: not a real 10-core chip! # CPU cores 2 out of order 10 in-order Instructions per issue 4 per clock 2 per clock VPU lanes per core 4-wide SSE 16-wide L2 cache size 4 MB 4 MB Single-stream 4 per clock 2 per clock Vector throughput 8 per clock 160 per clock 20 times the multiply-add operations per clock Data in chart taken from Seiler, L., Carmean, D., et al.
Recommended publications
  • Pipelining 2
    Instruction-Level Parallelism Dynamic Scheduling CS448 1 Dynamic Scheduling • Static Scheduling – Compiler rearranging instructions to reduce stalls • Dynamic Scheduling – Hardware rearranges instruction stream to reduce stalls – Possible to account for dependencies that are only known at run time - e. g. memory reference – Simplifies the compiler – Code built for one pipeline in mind could also run efficiently on a different pipeline – minimizes the need for speculative slot filling - NP hard • Once a common tactic with supercomputers and mainframes but was too expensive for single-chip – Now fits on a desktop PC’s 2 1 Dynamic Scheduling • Dependencies that are close together stall the entire pipeline – DIVD F0, F2, F4 – ADDD F10, F0, F8 – SUBD F12, F8, F14 • The ADD needs the DIV to finish, so there is a stall… which also stalls the SUBD – Looong stall for DIV – But the SUBD is independent so there is no reason why we shouldn’t execute it – Or is there? • Precise Interrupts - Ignore for now • Compiler could rearrange instructions, but so could the hardware 3 Dynamic Scheduling • It would be desirable to decode instructions into the pipe in order but then let them stall individually while waiting for operands before issue to execution units. • Dynamic Scheduling – Out of Order Issue / Execution • Scoreboarding 4 2 Scoreboarding Split ID stage into two: Issue (Decode, check for Structural hazards) Read Operands (Wait until no data hazards, read operands) 5 Scoreboard Overview • Consider another example: – DIVD F0, F2, F4 – ADDD F10, F0,
    [Show full text]
  • EECS 570 Lecture 5 GPU Winter 2021 Prof
    EECS 570 Lecture 5 GPU Winter 2021 Prof. Satish Narayanasamy http://www.eecs.umich.edu/courses/eecs570/ Slides developed in part by Profs. Adve, Falsafi, Martin, Roth, Nowatzyk, and Wenisch of EPFL, CMU, UPenn, U-M, UIUC. 1 EECS 570 • Slides developed in part by Profs. Adve, Falsafi, Martin, Roth, Nowatzyk, and Wenisch of EPFL, CMU, UPenn, U-M, UIUC. Discussion this week • Term project • Form teams and start to work on identifying a problem you want to work on Readings For next Monday (Lecture 6): • Michael Scott. Shared-Memory Synchronization. Morgan & Claypool Synthesis Lectures on Computer Architecture (Ch. 1, 4.0-4.3.3, 5.0-5.2.5). • Alain Kagi, Doug Burger, and Jim Goodman. Efficient Synchronization: Let Them Eat QOLB, Proc. 24th International Symposium on Computer Architecture (ISCA 24), June, 1997. For next Wednesday (Lecture 7): • Michael Scott. Shared-Memory Synchronization. Morgan & Claypool Synthesis Lectures on Computer Architecture (Ch. 8-8.3). • M. Herlihy, Wait-Free Synchronization, ACM Trans. Program. Lang. Syst. 13(1): 124-149 (1991). Today’s GPU’s “SIMT” Model CIS 501 (Martin): Vectors 5 Graphics Processing Units (GPU) • Killer app for parallelism: graphics (3D games) Tesla S870 What is Behind such an Evolution? • The GPU is specialized for compute-intensive, highly data parallel computation (exactly what graphics rendering is about) ❒ So, more transistors can be devoted to data processing rather than data caching and flow control ALU ALU Control ALU ALU CPU GPU Cache DRAM DRAM • The fast-growing video game industry
    [Show full text]
  • 14 Superscalar Processors
    UNIT- 5 Chapter 14 Instruction Level Parallelism and Superscalar Processors What is Superscalar? • Use multiple independent instruction pipeline. • Instruction level parallelism • Identify dependencies in program • Eliminate Unnecessary dependencies • Use additional registers & renaming of register references in original code. • Branch prediction improves efficiency What is Superscalar? • RISC-like instructions, one per word • Multiple parallel execution units • Reorders and optimizes instruction stream at run time • Branch prediction with speculative execution of one path • Loads data from memory only when needed, and tries to find the data in the caches first Why Superscalar? • In 1987, scalar instruction • Most operations are on scalar quantities • Improving these operations to get an overall improvement • High performance microprocessors. General Superscalar Organization Superscalar V/S Superpipelined • Ordinary:- • One instruction/clock cycle & can perform one pipeline stage per clock cycle. • Superpipelined:- • 2 pipeline stage per cycle • Execution time:-half a clock cycle • Double internal clock speed gets two tasks per external clock cycle • Superscalar :- • allows parallel fetch execute • Start of the program & at branch target it performs better than above said. Superscalar v Superpipeline Limitations • Instruction level parallelism • Compiler based optimisation • Hardware techniques • Limited by —True data dependency —Procedural dependency —Resource conflicts —Output dependency —Antidependency True Data Dependency • ADD r1,
    [Show full text]
  • Concepts Introduced in Chapter 3 Instruction Level Parallelism (ILP)
    Intro Compiler Techs Branch Pred Dynamic Sched Speculation Multi Issue ILP Limits MT Intro Compiler Techs Branch Pred Dynamic Sched Speculation Multi Issue ILP Limits MT Concepts Introduced in Chapter 3 Instruction Level Parallelism (ILP) introduction Pipelining is the overlapping of dierent portions of instruction compiler techniques for ILP execution. advanced branch prediction Instruction level parallelism is the parallel execution of a dynamic scheduling sequence of instructions associated with a single thread of speculation execution. multiple issue scheduling approaches to exploit ILP static (compiler) limits of ILP dynamic (hardware) multithreading Intro Compiler Techs Branch Pred Dynamic Sched Speculation Multi Issue ILP Limits MT Intro Compiler Techs Branch Pred Dynamic Sched Speculation Multi Issue ILP Limits MT Data Dependences Control Dependences An instruction is control dependent on a branch instruction if the instruction will only be executed when the branch has a specic result. An instruction that is control dependent on a branch cannot be moved before the branch so that its execution is not controlled by the branch. Instructions must be independent to be executed in parallel. instruction types of data dependences branch branch True dependences can lead to RAW hazards. name dependences instruction Antidependences can lead to WAR hazards. before transformation after transformation Output dependences can lead to WAW hazards. An instruction that is not control dependent on a branch cannot be moved after the branch so that its execution is controlled by the branch. instruction branch branch instruction before transformation after transformation Intro Compiler Techs Branch Pred Dynamic Sched Speculation Multi Issue ILP Limits MT Intro Compiler Techs Branch Pred Dynamic Sched Speculation Multi Issue ILP Limits MT Static Scheduling Latencies of FP Operations Used in This Chapter The latency here indicates the number of intervening independent instructions that are needed to avoid a stall.
    [Show full text]
  • Intro Evolution of Superscalar Processor
    Superscalar Processors Superscalar Processors vs. VLIW • 7.1 Introduction • 7.2 Parallel decoding • 7.3 Superscalar instruction issue • 7.4 Shelving • 7.5 Register renaming • 7.6 Parallel execution • 7.7 Preserving the sequential consistency of instruction execution • 7.8 Preserving the sequential consistency of exception processing • 7.9 Implementation of superscalar CISC processors using a superscalar RISC core • 7.10 Case studies of superscalar processors TECH Computer Science CH01 Superscalar Processor: Intro Emergence and spread of superscalar processors • Parallel Issue • Parallel Execution • {Hardware} Dynamic Instruction Scheduling • Currently the predominant class of processors 4Pentium 4PowerPC 4UltraSparc 4AMD K5- 4HP PA7100- 4DEC α Evolution of superscalar processor Specific tasks of superscalar processing Parallel decoding {and Dependencies check} Decoding and Pre-decoding • What need to be done • Superscalar processors tend to use 2 and sometimes even 3 or more pipeline cycles for decoding and issuing instructions • >> Pre-decoding: 4shifts a part of the decode task up into loading phase 4resulting of pre-decoding f the instruction class f the type of resources required for the execution f in some processor (e.g. UltraSparc), branch target addresses calculation as well 4the results are stored by attaching 4-7 bits • + shortens the overall cycle time or reduces the number of cycles needed The principle of perdecoding Number of perdecode bits used Specific tasks of superscalar processing: Issue 7.3 Superscalar instruction issue • How and when to send the instruction(s) to EU(s) Instruction issue policies of superscalar processors: Issue policies ---Performance, tread-----Æ Issue rate {How many instructions/cycle} Issue policies: Handing Issue Blockages • CISC about 2 • RISC: Issue stopped by True dependency Issue order of instructions • True dependency Æ (Blocked: need to wait) Aligned vs.
    [Show full text]
  • Simty: Generalized SIMT Execution on RISC-V Caroline Collange
    Simty: generalized SIMT execution on RISC-V Caroline Collange To cite this version: Caroline Collange. Simty: generalized SIMT execution on RISC-V. CARRV 2017: First Work- shop on Computer Architecture Research with RISC-V, Oct 2017, Boston, United States. pp.6, 10.1145/nnnnnnn.nnnnnnn. hal-01622208 HAL Id: hal-01622208 https://hal.inria.fr/hal-01622208 Submitted on 7 Oct 2020 HAL is a multi-disciplinary open access L’archive ouverte pluridisciplinaire HAL, est archive for the deposit and dissemination of sci- destinée au dépôt et à la diffusion de documents entific research documents, whether they are pub- scientifiques de niveau recherche, publiés ou non, lished or not. The documents may come from émanant des établissements d’enseignement et de teaching and research institutions in France or recherche français ou étrangers, des laboratoires abroad, or from public or private research centers. publics ou privés. Simty: generalized SIMT execution on RISC-V Caroline Collange Inria [email protected] ABSTRACT and programming languages to target GPU-like SIMT cores. Be- We present Simty, a massively multi-threaded RISC-V processor side simplifying software layers, the unification of CPU and GPU core that acts as a proof of concept for dynamic inter-thread vector- instruction sets eases prototyping and debugging of parallel pro- ization at the micro-architecture level. Simty runs groups of scalar grams. We have implemented Simty in synthesizable VHDL and threads executing SPMD code in lockstep, and assembles SIMD synthesized it for an FPGA target. instructions dynamically across threads. Unlike existing SIMD or We present our approach to generalizing the SIMT model in SIMT processors like GPUs or vector processors, Simty vector- Section 2, then describe Simty’s microarchitecture is Section 3, and izes scalar general-purpose binaries.
    [Show full text]
  • History Scoreboarding Overview Machine Correctness Four Stages
    History 1966: scoreboarding in CDC6600, Lecture 6: Scoreboarding and Tomasulo implementing limited dynamic Algorithm scheduling Three years later: Tomasulo in IBM 360/91, introducing register renaming and reservation station Now appearing in todays Dec Alpha, SGI MIPS, SUN UltraSparc, Intel Pentium, IBM PowerPC, and others 1 Zhao Zhang, CPRE 581, Fall 2005 2 Adapted from UCB CS252 S98, Copyright 1998 USB Scoreboarding Overview Machine Correctness Basic idea: E(D,P) = E(S,P) if Use scoreboard to track data (RAW) dependence 1. E(D,P) and E(S,P) execute the same set of through register instructions Main points of design: 2. For any inst i, i receives the outputs in Instructions are sent to FU unit if there is no E(D,P) of its parents in E(S,P) outstanding name dependence 3. In E(D,P) any register or memory word receives RAW data dependence is tracked and enforced the output of inst j, where j is the last by scoreboard instruction writes to the register or memory Register values are passed through the register word in E(S,P) file; a child instruction starts execution after the last parent finishes execution Scoreboarding merit: Be able to execute Pipeline stalls if any name dependence (WAR or independent instructions in parallel without WAW) is detected violating statement 2. Zhao Zhang, CPRE 581, Fall 2005 3 Zhao Zhang, CPRE 581, Fall 2005 4 Four Stages of Scoreboard Control Four Stages of Scoreboard Control Fetch first, then 3.Execution—operate on operands (EX) 1. Issue—decode instructions & check for structural Actions: The functional unit begins execution upon receiving hazards operands.
    [Show full text]
  • Advanced RISC-V Architectures
    PULP PLATFORM Open Source Hardware, the way it should be! Working with RISC-V Part 2 of 4 : Advanced RISC-V Architectures Luca Benini <[email protected]> Frank K. Gürkaynak <[email protected]> http://pulp-platform.org @pulp_platform https://www.youtube.com/pulp_platform Working with RISC-V Summary ▪ Part 1 – Introduction to RISC-V ISA ▪ Part 2 – Advanced RISC-V Architectures ▪ Going 64 bit ▪ Bottlenecks ▪ Safety/Security ▪ Vector units ▪ Part 3 – PULP concepts ▪ Part 4 – PULP based chips | ACACES 2020 - July 2020 Working with RISC-V PULP RISC-V Cores from Tiny to App-level 32 bit 64 bit Low Cost DSP Streaming Linux Core Enhanced Compute capable Core Core Core ▪ Zero-riscy ▪ RI5CY ▪ Snitch ▪ Ariane ▪ RV32-ICM ▪ RV32-ICMFX ▪ RV32- ▪ RV64-IC(MA) ▪ Micro-riscy ▪ SIMD ICMDFX ▪ Full ▪ HW loops ▪ RV32-CE privileged ▪ Bit specification manipulation ▪ Fixed point ARM Cortex-M0+ ARM Cortex-M4 ARM Cortex-A5 | ACACES 2020 - July 2020 Working with RISC-V From IoT to HPC ▪ For the first 4 years of PULP, we used only 32bit cores ▪ Most IoT near-sensor applications work well with 32bit cores. ▪ 64bit memory space is not affordable in an MCU-class device ▪ But times change: ▪ Large datasets, high-precision numerical calculations (e.g. double precision FP) at the IoT edge (gateways) and cloud ▪ Software infrastructure (OS – typically linux) with virtual memory assumes 64bit ▪ High-performance computing, being hot again, requires 64bit ▪ Research question – pJ/OP on 64bit data+address space is possible? How? | ACACES 2020 - July 2020 Working with RISC-V
    [Show full text]
  • 5 10 15 20 25 30 35 Class 712 Electrical Computers And
    CLASS 712 ELECTRICAL COMPUTERS AND DIGITAL PROCESSING SYSTEMS: 712 - 1 PROCESSING ARCHITECTURES AND INSTRUCTION PROCESSING (E.G., PROCES- SORS) 712 ELECTRICAL COMPUTERS AND DIGITAL PROCESSING SYSTEMS: PROCESSING ARCHITECTURES AND INSTRUCTION PROCESSING (E.G., PROCESSORS) 1 PROCESSING ARCHITECTURE 40 ...External sync or interrupt 2 .Vector processor signal 3 ..Scalar/vector processor 41 ..RISC interface 42 ..Operation 4 ..Distributing of vector data to 43 ...Mode switching vector registers 200 ARCHITECTURE BASED INSTRUCTION 5 ...Masking to control an access PROCESSING to data in vector register 201 .Data flow based system 6 ..Controlling access to external 202 .Stack based computer vector data 203 .Multiprocessor instruction 7 ..Vector processor operation 204 INSTRUCTION ALIGNMENT 8 ...Sequential 205 INSTRUCTION FETCHING 9 ...Concurrent 206 .Of multiple instructions 10 .Array processor simultaneously 11 ..Array processor element 207 .Prefetching interconnection 208 INSTRUCTION DECODING (E.G., BY 12 ...Cube or hypercube MICROINSTRUCTION, START 13 ...Partitioning ADDRESS GENERATOR, HARDWIRED) 14 ...Processing element memory 209 .Decoding instruction to 15 ...Reconfiguring accommodate plural instruction 16 ..Array processor operation interpretations (e.g., different dialects, languages, 17 ...Application specific emulation, etc.) 18 ...Data flow array processor 210 .Decoding instruction to 19 ...Systolic array processor accommodate variable length 20 ...Multimode (e.g., MIMD to SIMD, instruction or operand etc.) 211 .Decoding instruction to
    [Show full text]
  • Modern Computer Architectures Lecture-1: Introduction
    Modern Computer Architectures Lecture-1: Introduction Sandeep Kumar Panda Asso.Prof. IT Department CEB,BBSR 1 Introduction – Computer performance has been increasing phenomenally over the last five decades. – Brought out by Moore’s Law: ● Transistors per square inch roughly double every eighteen months. – Moore’s law is not exactly a law: ● But, has held good for nearly 50 years. 2 Introduction Cont… ● If commercial aircrafts had similar performance increase over the last 50 years, we should have: – Commercial planes flying at 1000 times the supersonic speed. – Aircrafts of the size of a chair. – Costing couple of thousand rupees only. 3 Moore’s Law Gordon Moore (co-founder of Intel) predicted in 1965: “Transistor density of minimum cost semiconductor chips would Moore’s Law: it’s worked for double roughly every 18 months.” a long time. Transistor density is correlated to processing speed. 4 Trends Related to Moore’s Law Cont… • Processor performance: • Twice as fast after every 2 years (roughly). • Memory capacity: • Twice as much after every 18 months (roughly). 5 Interpreting Moore’s Law ● Moore's law is not about just the density of transistors on a chip that can be achieved: – But about the density of transistors at which the cost per transistor is the lowest. ● As more transistors are made on a chip: – The cost to make each transistor reduces. – But the chance that the chip will not work due to a defect rises. ● Moore observed in 1965 there is a transistor density or complexity: – At which "a minimum cost" is achieved. 6 Integrated Circuits Costs IC cost = Die cost + Testing cost + Packaging cost Final test yield Final test yield: Fraction of packaged dies which pass the final testing state.
    [Show full text]
  • Pipelining: Basic and Intermediate Concepts
    C-2 ■ Appendix C Pipelining: Basic and Intermediate Concepts C.1 Introduction Many readers of this text will have covered the basics of pipelining in another text (such as our more basic text Computer Organization and Design) or in another course. Because Chapter 3 builds heavily on this material, readers should ensure that they are familiar with the concepts discussed in this appendix before proceeding. As you read Chapter 2, you may find it helpful to turn to this mate- rial for a quick review. We begin the appendix with the basics of pipelining, including discussing the data path implications, introducing hazards, and examining the performance of pipelines. This section describes the basic five-stage RISC pipeline that is the basis for the rest of the appendix. Section C.2 describes the issue of hazards, why they cause performance problems, and how they can be dealt with. Section C.3 discusses how the simple five-stage pipeline is actually implemented, focusing on control and how hazards are dealt with. Section C.4 discusses the interaction between pipelining and various aspects of instruction set design, including discussing the important topic of exceptions and their interaction with pipelining. Readers unfamiliar with the concepts of precise and imprecise interrupts and resumption after exceptions will find this material useful, since they are key to understanding the more advanced approaches in Chapter 3. Section C.5 discusses how the five-stage pipeline can be extended to handle longer-running floating-point instructions. Section C.6 puts these concepts together in a case study of a deeply pipelined processor, the MIPS R4000/4400, including both the eight-stage integer pipeline and the floating-point pipeline.
    [Show full text]
  • Lecture 6: Scoreboarding and Tomasulo Algorithm
    Lecture 6: Scoreboarding and Tomasulo Algorithm 1 History 1966: scoreboarding in CDC6600, implementing limited dynamic scheduling Three years later: Tomasulo in IBM 360/91, introducing register renaming and reservation station Now appearing in todays Dec Alpha, SGI MIPS, SUN UltraSparc, Intel Pentium, IBM PowerPC, and others Zhao Zhang, CPRE 581, Fall 2005 2 Adapted from UCB CS252 S98, Copyright 1998 USB Scoreboarding Overview Basic idea: Use scoreboard to track data (RAW) dependence through register Main points of design: Instructions are sent to FU unit if there is no outstanding name dependence RAW data dependence is tracked and enforced by scoreboard Register values are passed through the register file; a child instruction starts execution after the last parent finishes execution Pipeline stalls if any name dependence (WAR or WAW) is detected Zhao Zhang, CPRE 581, Fall 2005 3 Machine Correctness E(D,P) = E(S,P) if 1. E(D,P) and E(S,P) execute the same set of instructions 2. For any inst i, i receives the outputs in E(D,P) of its parents in E(S,P) 3. In E(D,P) any register or memory word receives the output of inst j, where j is the last instruction writes to the register or memory word in E(S,P) Scoreboarding merit: Be able to execute independent instructions in parallel without violating statement 2. Zhao Zhang, CPRE 581, Fall 2005 4 Four Stages of Scoreboard Control Fetch first, then 1. Issue—decode instructions & check for structural hazards Wait conditions: (1) the required FU is free; (2) no other instruction writes to the same register destination (to avoid WAW) Actions: (1) the instruction proceeds to the FU; (2) scoreboard updates its internal data structure If an instruction is stalled at this stage, no other instructions can proceed 2.
    [Show full text]