(j3.2006) MPI usage problems in Fortran

Aleksandar Donev donev1
Tue Mar 18 20:05:33 EDT 2008


On Tuesday 18 March 2008 16:04, Bill Long wrote:

> If the actual argument is not simply contiguous, you get a
> constraint violation, and hence a compile time error.  This is what
> assures there is no copy-in/copy-out.
Bill is referring to this constraint:

C1238 (R1223) If an actual argument is a nonpointer array that is not simply 
contiguous (6.5.4), and the
corresponding dummy argument has either the VOLATILE or ASYNCHRONOUS 
attribute, that dummy
argument shall be an assumed-shape array that does not have the CONTIGUOUS 
attribute.

which used to be in Fortran 2003:

C1232 (R1221) If an actual argument is an array section or an assumed-shape 
array, and the corresponding dummy argument has either the VOLATILE or 
ASYNCHRONOUS attribute, that dummy argument shall be an assumed-shape array.

> The asynchronous attribute for a dummy does require an explicit
> interface in the caller, so the caller knows the corresponding actual is
> 'tainted'.
Tainted when? During the call. Forever after the call completes? Both? Where 
is this specified in the standard?

Where exactly does the asynchronous data-transfer occur---during the call to 
the procedure or after the procedure returns. If it is after the procedure 
returns, then you've just nixed the so-called design principle:
"An object may have the asynchronous attribute in a particular ?
scoping unit without necessarily having it in other scoping units."
since putting ASYNC attribute on the dummy taints *every* actual in all other 
units where the procedure is called.
Does the actual need to have the ASYNC attribute or does it somehow implicitly 
get it after calling the procedure?

Read the words more carefully please and think about whether they actually 
accomplish what the attached note says they do.

Best,
Aleks




More information about the J3 mailing list