XcalableMP Programming Model and Language
41
Fig. 29 Example of reflect construct (1)
Fig. 30 Example of reflect construct (2)
Fig. 31 Example of periodic reflect construct
XcalableMP Fortran
!$xmp reflect (a)
!xmp loop on t(i)
do i=2, 15
5
a(i) = (a(i-1) + a(i) + a(i+1))/3
enddo
With this reflect directive, in XMP/C, node p[1] sends an element a[4] to
the shadow area on the upper bound on node p[0] and a[7] to the shadow area
on the lower bound on p[2]; p[0] sends an element a[3] to the shadow area on
the lower bound on p[1], and p[2] sends a[8] to the shadow area on the upper
bound on p[1].
Précédent

- 49/265

Suivant