Re: Fortran assumed-shape array problems with MPI
- From: glen herrmannsfeldt <gah@xxxxxxxxxxxxxxxx>
- Date: Wed, 30 May 2007 14:20:52 -0800
Jane Smith wrote:
Hi, I am using fortran 90 (PGI) with MPI (mpif90) and I faced a
situation that a scalar argument is passed to the subroutine that
declares the dummy argument as 4-dimensional assumed-shape array.
(snip)
Does anybody know a practical solution to this problem other than
just not using the assumed-shape array (making it all explicit-shaped
by passing the bounds together) ?
Passing a scalar variable (or constant) to an array dummy is
not standard in any version of Fortran, though it is
likely to work except in the assumed shape case.
(Assumed shape arrays are normally passed by descriptor.)
Passing an array element to an assumed size or explicit shape
dummy is legal, where the called routine can reference any array
element from the one specified to the end of the array.
I would say assign to a one element 4-D array and pass that instead.
(and copy back on return).
-- glen
.
- Follow-Ups:
- Re: Fortran assumed-shape array problems with MPI
- From: Jane Smith
- Re: Fortran assumed-shape array problems with MPI
- References:
- Fortran assumed-shape array problems with MPI
- From: Jane Smith
- Fortran assumed-shape array problems with MPI
- Prev by Date: Re: Fortran assumed-shape array problems with MPI
- Next by Date: Re: SALFORD ERROR?
- Previous by thread: Fortran assumed-shape array problems with MPI
- Next by thread: Re: Fortran assumed-shape array problems with MPI
- Index(es):
Relevant Pages
|