processor architecture
play

Processor Architecture Stream Arithmetic Logic Unit Programming - PowerPoint PPT Presentation

Processor Architecture Stream Arithmetic Logic Unit Programming ALU for high-performance computing 7 8 2 Memory CS334 F09 Prof. McGuire Williams College 1 2 Multi-Processor Stream Programming Arithmetic Logic Unit Arithmetic Logic


  1. Processor Architecture Stream Arithmetic Logic Unit Programming ALU for high-performance computing 7 8 2 Memory CS334 F09 Prof. McGuire Williams College 1 2 Multi-Processor Stream Programming Arithmetic Logic Unit Arithmetic Logic Unit ALU ALU ALU ALU ALU ALU ALU ALU ALU ALU 8 5 7 2 ? 4 7 8 2 4 5 8 9 3 5 6 Memory Memory 3 4

  2. Stream Primitives Map • Apply a function to all source destination • Map elements • Reduce (map * ‘(1 2) (3 4)) ! ‘(3 8) • Scatter • Matrix addition • Gather • Audio adjustment “kernel” function dst[i] = f(src[i]) (map * ‘(1 2) (3 4)) ! ‘(3 8) 5 6 Reduce (Filter) Reduce (Fold) • Drop elements that • Combine elements fail a predicate • Summation • Strip outliers • Average • Parse whitespace • Maximum dst = f(src[0], src[1], ..., src[n]) (foldl + 0 ‘(1 2 3 4)) ! 10 (filter even? ‘(1 2 3 4)) ! ‘(2 4) 7 8

  3. Scatter (“Push”) Gather (“Pull”) • Iterate over destination, • Iterate over source, compute source index compute destination index • Merge sort • Radix, Insertion, Quick sort • Sparse matrix operations • Hash table insertion • Ray tracing • Permutation • Database query • Rasterization dst[ f(i) ] = src[i] dst[i] = src[ f(i) ] 9 10 The Next Big Thing? • OpenMP - Parallel C and Fortran extensions • Chapel - Cray; streaming Fortran-ish • X10 - IBM; streaming Java • Fortress - Sun; Guy Steele’s Mathematica-Scheme • HPC, ZPL, Cilk, Titanium, UPC, Cuda, CTM, Sh, ... 11

Recommend


More recommend