PRAM
9A
Concurrent Write (CW)
 Priority CW
 Higher priority processor (normally lower
index) wins
 Common CW
 Succeeds only if all writes have the same
value
 Arbitrary/Random CW
 One of the values is randomly chosen
EREW CREW Common Arbitrary
≤ ≤ ≤ ≤
Priority
Simplest
to
Implemen
Hardest
to
Implemen
Example CRCW-PRAM
 Initially
 Table A contains 0 and 1
 Output contains 0
for i = 1 to 5
if A[i] == 1
output = 1
 The program computes the “Boolean
OR” of A[1], A[2], A[3], A[4], A[5]
Parallel Addition
 log(n) time
 n/2 processors
 Speed-up: n/log(n)
 Efficiency: 1/log(n)
 Work: n log n *
P0 + P1 + P2 + P3 +
step 1
P0 + P2 +
step 2
P0 + step
3
Parallel Computing - PRAM -- LECTURE - 1
Parallel Computing - PRAM -- LECTURE - 1
Parallel Computing - PRAM -- LECTURE - 1
Parallel Computing - PRAM -- LECTURE - 1
Parallel Computing - PRAM -- LECTURE - 1
Parallel Computing - PRAM -- LECTURE - 1
Parallel Computing - PRAM -- LECTURE - 1
Parallel Computing - PRAM -- LECTURE - 1

Parallel Computing - PRAM -- LECTURE - 1

  • 1.
  • 2.
  • 3.
    Concurrent Write (CW) Priority CW  Higher priority processor (normally lower index) wins  Common CW  Succeeds only if all writes have the same value  Arbitrary/Random CW  One of the values is randomly chosen EREW CREW Common Arbitrary ≤ ≤ ≤ ≤ Priority Simplest to Implemen Hardest to Implemen
  • 4.
    Example CRCW-PRAM  Initially Table A contains 0 and 1  Output contains 0 for i = 1 to 5 if A[i] == 1 output = 1  The program computes the “Boolean OR” of A[1], A[2], A[3], A[4], A[5]
  • 5.
    Parallel Addition  log(n)time  n/2 processors  Speed-up: n/log(n)  Efficiency: 1/log(n)  Work: n log n * P0 + P1 + P2 + P3 + step 1 P0 + P2 + step 2 P0 + step 3