(j3.2006) (SC22WG5.5700) [ukfortran] AW: coarray dummy arguments

Anton Shterenlikht mexas
Wed Apr 6 05:37:00 EDT 2016


Hi Reinhold

Your example makes your point much clearer.
Still...

> Image 1:
> 
> INTEGER  ::  I[*] = 0
> 
> I[2] = I[2] + 1
> SYNC IMAGES( [1,2] )
> 
> Image 2:
> 
> INTEGER :: IL
> 
> CALL S1(I, IL)
> 
> The current text in the standard causes the above to be non-conforming
> for two reasons:
> 
> (1) the dummy argument A of procedure S1 is modified by a different
>     image, in violation of 12.5.2.13 para 3+4. Since the ability to do
>     such modifications is part of the coarray design, further
>     exceptions need to be added to the above paragraphs. The exceptions

I think this code violates [195:3-4].
Variable I is defined on image 1 and used on image 2
in the same segment, which is prohibited.
"I" is used on image 2 as actual argument when
calling subroutine S1. I believe that to conform,
SYNC IMAGES( [1,2] ) must appear before CALL S1(I, IL).

This seems to be related to the dummy variable issue
you are addressing. When you say that the ability to
modify a dummy argument by a different image is part
of the coarray design, I'm not sure.

Anton



More information about the J3 mailing list