
116 CHAPTER 2 Parallel Programs
To better appreciate the differences between the shared address space and
message-passing programming models, it will be instructive to perform an exercise to
transform the message-passing version of the equation solver to use a cyclic assign-
ment as we did for the shared address space version in Example 2.2. The point to
observe in this case is that, although the two message-passing versions will look syn-
tactically similar, the meaning of the myA data structure will be completely different.
In one case it is a contiguous section of the global array, and in the other it is a set of
widely separated rows. Onl ...