===================================================================
@@ -1,3 +1,8 @@
+2014-04-07 Tobias Burnus <burnus@net-b.de>
+
+ * gfortran.dg/coarray/send_array.f90: Really fix support
+ for num_images() > 1.
+
2014-04-06 Tobias Burnus <burnus@net-b.de>
* gfortran.dg/coarray/send_array.f90: Fix support
===================================================================
@@ -130,7 +130,7 @@ subroutine two()
a(:,:) = b(lb1, lb2)
sync all
if (this_image() == 1) then
- caf(:,:)[this_image()] = b(lb1, lb2)
+ caf(:,:)[num_images()] = b(lb1, lb2)
end if
sync all
if (this_image() == num_images()) then
@@ -144,7 +144,7 @@ subroutine two()
a(:,:) = b(:, :)
sync all
if (this_image() == 1) then
- caf(:,:)[this_image()] = b(:, :)
+ caf(:,:)[num_images()] = b(:, :)
end if
sync all
if (this_image() == num_images()) then
@@ -167,7 +167,8 @@ subroutine two()
a(i:i_e:i_s*i_sgn1, j:j_e:j_s*i_sgn2) = b(lb1, lb2)
sync all
if (this_image() == 1) then
- caf(i:i_e:i_s*i_sgn1, j:j_e:j_s*i_sgn2)[1] = b(lb1, lb2)
+ caf(i:i_e:i_s*i_sgn1, j:j_e:j_s*i_sgn2)[num_images()] &
+ = b(lb1, lb2)
end if
sync all
@@ -178,7 +179,7 @@ subroutine two()
= b(i:i_e:i_s*i_sgn1, j:j_e:j_s*i_sgn2)
sync all
if (this_image() == 1) then
- caf(i:i_e:i_s*i_sgn1, j:j_e:j_s*i_sgn2)[1] &
+ caf(i:i_e:i_s*i_sgn1, j:j_e:j_s*i_sgn2)[num_images()] &
= b(i:i_e:i_s*i_sgn1, j:j_e:j_s*i_sgn2)
end if
sync all
@@ -222,7 +223,7 @@ subroutine three()
a(:,:) = b(lb1, lb2)
sync all
if (this_image() == 1) then
- caf(:,:)[this_image()] = b(lb1, lb2)
+ caf(:,:)[num_images()] = b(lb1, lb2)
end if
sync all
if (this_image() == num_images()) then
@@ -236,7 +237,7 @@ subroutine three()
a(:,:) = b(:, :)
sync all
if (this_image() == 1) then
- caf(:,:)[this_image()] = b(:, :)
+ caf(:,:)[num_images()] = b(:, :)
end if
sync all
if (this_image() == num_images()) then
@@ -259,7 +260,8 @@ subroutine three()
a(i:i_e:i_s*i_sgn1, j:j_e:j_s*i_sgn2) = b(lb1, lb2)
sync all
if (this_image() == 1) then
- caf(i:i_e:i_s*i_sgn1, j:j_e:j_s*i_sgn2)[1] = b(lb1, lb2)
+ caf(i:i_e:i_s*i_sgn1, j:j_e:j_s*i_sgn2)[num_images()] &
+ = b(lb1, lb2)
end if
sync all
@@ -270,7 +272,7 @@ subroutine three()
= b(i:i_e:i_s*i_sgn1, j:j_e:j_s*i_sgn2)
sync all
if (this_image() == 1) then
- caf(i:i_e:i_s*i_sgn1, j:j_e:j_s*i_sgn2)[1] &
+ caf(i:i_e:i_s*i_sgn1, j:j_e:j_s*i_sgn2)[num_images()] &
= b(i:i_e:i_s*i_sgn1, j:j_e:j_s*i_sgn2)
end if
sync all