lectures.alex.balgavy.eu

Lecture notes from university.
git clone git://git.alex.balgavy.eu/lectures.alex.balgavy.eu.git
Log | Files | Refs | Submodules

Vector (SIMD) processing & GPUs.md (1221B)


      1 +++
      2 title = 'Vector (SIMD) processing & GPUs'
      3 +++
      4 # Vector (SIMD) processing & GPUs
      5 many programs use loops to operate on vectors of data, so many instructions are executed
      6 
      7 single-instruction multiple-data (SIMD) — use multiple ALUs to operate on multiple data in parallel using a single instruction (as long as operations performed in parallel are independent)
      8 
      9 vector registers hold data for vector instructions — have number of elements L (vector length), determines number of operations that can be done in parallel (multiple ALUs)
     10 
     11 ## Vectorisation
     12 
     13 in a high-level language, loops working with arrays of numbers are vectorisable if the operations on every pass are independent of all other passes
     14 
     15 a vectorising compiler can recognise those loops and generate vector instructions
     16 
     17 they’re used for stuff like computer graphics and digital signal processing
     18 
     19 ## GPUs (Graphics Processing Units)
     20 
     21 their main purpose in life is to speed up calculations on a large number of floating-points
     22 
     23 a large chip has hundreds of simple cores with floating-point ALUs to do a lot of work in parallel
     24 
     25 a video card has both a GPU and a dedicated memory for it
     26 they have a special instruction set and hardware architecture