Lec16_17 Irregular problems workload decomposition

Art of Parallel Programming

Info iconThis preview shows pages 1–12. Sign up to view the full content.

View Full Document Right Arrow Icon
Lecture 17 Irregular problems: workload decomposition, programming models
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
11/17/06 Scott B. Baden / CSE 160 / Fall 2006 2 Announcements • Quiz in class on Tuesday 11/21 – You may bring your text book, lecture slides, and handout readers – 25 minutes – Covers material for lectures 13-16 • A5 is now due Weds 11/22 at 5pm • Come see my talk at the “Last Lecture Series” – Wed 11/22 at 12Noon – Gallery A, Price Center – Free Pizza and Drinks • Office hours on Weds 11/22 delayed to 2pm to 3pm
Background image of page 2
11/17/06 Scott B. Baden / CSE 160 / Fall 2006 3 Issues in building a parallel program How do processes communicate? Blocking vs. non-blocking communication Collective vs. point-point communication Granularity: collect data into long messages rather than sending piecemeal How do we divide up the computation and assign to processors? Decomposition or partitioning Processor mapping Dynamic or static?
Background image of page 3

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
11/17/06 Scott B. Baden / CSE 160 / Fall 2006 4 Issues in data decomposition Functional decomposition Task parallelism Pipelining Data decomposition – The most common technique in parallel computing – Are the data decomposed uniformly or non- uniformly?
Background image of page 4
11/17/06 Scott B. Baden / CSE 160 / Fall 2006 5 Irregular Problems • In the Jacobi application, computational effort is applied uniformly Irregular applications apply computational effort non-uniformly • A load balancing problem arises when partitioning the data Courtesy of Randy Bank
Background image of page 5

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
11/17/06 Scott B. Baden / CSE 160 / Fall 2006 6 Dynamic non-uniform workload assignment • Compute the Mandelbroit set for a region of the complex plane • A quick review of complex numbers
Background image of page 6
11/17/06 Scott B. Baden / CSE 160 / Fall 2006 7 A quick review of complex numbers • We define i = ¯ 1 • A complex number z = x + i y – x is called the real part – y is called the imaginary part • We associate each complex number with a point in the x-y plane • The magnitude of a complex number is the same as vector length: |z| = (x 2 + y 2 ) • z 2 = (x+iy)(x+iy) = (x 2 – y 2 ) +2xyi
Background image of page 7

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
11/17/06 Scott B. Baden / CSE 160 / Fall 2006 8 The Mandelbrot set • Named for the mathematician B. Mandelbrot • For which points c in the complex plane does the following iteration remain bounded? z k+1 = z k 2 + c c a given complex constant z 0 = 0 • When c=0, all points lay within a unit disk : |z| 1 • If |z| 2, the iteration is guaranteed to diverge to
Background image of page 8
11/17/06 Scott B. Baden / CSE 160 / Fall 2006 9 The computation • Plot the rate at which points in a given region diverge • Stop the iterations when z k+1 2 or k reaches some limit • Plot k at each position and associate colors with k
Background image of page 9

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
11/17/06 Scott B. Baden / CSE 160 / Fall 2006 10 A load balancing problem • Some points iterate longer than others • If we use block decomposition, some processors finish later than others • We have a load imbalance 1 2 3 4 5 6 7 8 0 1000 2000 3000 4000 5000 6000 7000 8000
Background image of page 10
11/17/06 Scott B. Baden / CSE 160 / Fall 2006 11 • Split up the complex plane into many small uniform blocks of size b × b • Assign the data in round robin fashion to processors
Background image of page 11

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Image of page 12
This is the end of the preview. Sign up to access the rest of the document.

This note was uploaded on 02/14/2008 for the course CSE 160 taught by Professor Baden during the Fall '06 term at UCSD.

Page1 / 76

Lec16_17 Irregular problems workload decomposition -...

This preview shows document pages 1 - 12. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online