Questions Parallel Programming Shared memory performance issues ITCS 4/5145 Parallel Programming, UNC-Charlotte, B. Wilkinson, QuizQuestions8d.ppt Sept 8, 2014
Do the two code sequences: forall (i = 0 i < 4; i++) a[i] = a[i+4]; and for (i = 0 i < 4; i++) a[i] = a[i+4]; always produce the same results. (Use Bernstein’s conditions) (a) Yes (b) No (c) None of the other answers.
Use Bernstein’s conditions to determine how much parallelism can be extracted from the following sequence: a = b + c; y = 3; c = a; x = y + z; How many threads can be used? 1 2 3 None of the other answers
Bernstein’s conditions are sufficient but not necessary conditions to establish whether statements can be executed in parallel (in the mathematical sense). Devise a sequence of two statements that fails Bernstein’s conditions but still can be executed in parallel or in any order?