[MPIWG Fortran] INTENT and ASYNCHRONOUS

Jeff Squyres (jsquyres) jsquyres at cisco.com
Wed Jun 6 10:41:46 CDT 2018


Yeah, we haven't had any other reports about this issue (it's specifically complaining about MPI_ACCUMULATE), and I don't think Open MPI's code has changed here in quite a while.  I should note that Open MPI's definition of MPI_ACCUMULATE agrees with what is in MPI-3.1.  I wanted to check to ensure that we didn't accidentally have a bug in MPI-3.1 that somehow worked in Open MPI with a variety of compilers for years, but was technically incorrect.



> On Jun 6, 2018, at 11:37 AM, Jeff Hammond <jeff.science at gmail.com> wrote:
> 
> This works with other compilers as well...
> 
> 
> $ for fc in ifort gfortran-8 pgfortran ; do ${fc} -c f08-intent-async.f90 && echo SUCCESS with $fc || echo FAILURE with $fc ; done
> SUCCESS with ifort
> SUCCESS with gfortran-8
> SUCCESS with pgfortran
> 
> $ cat f08-intent-async.f90
>         Subroutine csub (x)
>             real,intent(inout),asynchronous :: x
>         end Subroutine csub
>  
> 
> 
> On Wed, Jun 6, 2018 at 8:29 AM, Bill Long <longb at cray.com> wrote:
> 
> > On Jun 6, 2018, at 10:08 AM, Jeff Squyres (jsquyres) <jsquyres at cisco.com> wrote:
> > 
> > Fortran gurus --
> > 
> > We just got a problem report in Open MPI (https://www.mail-archive.com/users@lists.open-mpi.org/msg32381.html) for a Fortran compile failure:
> > 
> > -----
> >  OMPI_FORTRAN_IGNORE_TKR_TYPE, INTENT(IN), ASYNCHRONOUS :: origin_addr
> >                                            ^
> > "../../../../../openmpi-master-201806060243-64a5baa/ompi/mpi/fortran/use-mpi-f08/accumulate_f08.F90", Line = 16, Column = 46: ERROR: Attributes ASYNCHRONOUS and INTENT must not appear in the same attribute list.
> > -----
> > 
> > Is that Fortran compiler correct?  I.e., does Fortran forbid the use of INTENT and ASYNCHRONOUS in the same attribute list?
> 
> I don’t see a restriction like that, at least in F2018.  I tried this:
> 
>    Subroutine csub (x) 
>      real,intent(inout),asynchronous :: x
>    end Subroutine csub
> 
> with maximum diagnostics and got no messages with the Cray compiler which is quite good at testing conformance. 
> 
> 
> > Or is this a compiler bug?
> > 
> 
> It would appear to be the case.  It might be the case that the usage in the routine is incompatible with INTENT(IN), but that message should be differently worded.   Of course, OMPI_FORTRAN_IGNORE_TKR_TYPE is certainly not a valid type declaration.  I assume they intend TYPE(*). 
> 
> Cheers,
> Bill
> 
> 
> 
> 
> > -- 
> > Jeff Squyres
> > jsquyres at cisco.com
> > 
> > _______________________________________________
> > mpiwg-fortran mailing list
> > mpiwg-fortran at lists.mpi-forum.org
> > https://lists.mpi-forum.org/mailman/listinfo/mpiwg-fortran
> 
> Bill Long                                                                       longb at cray.com
> Principal Engineer, Fortran Technical Support &   voice:  651-605-9024
> Bioinformatics Software Development                      fax:  651-605-9143
> Cray Inc./ 2131 Lindau Lane/  Suite 1000/  Bloomington, MN  55425
> 
> 
> _______________________________________________
> mpiwg-fortran mailing list
> mpiwg-fortran at lists.mpi-forum.org
> https://lists.mpi-forum.org/mailman/listinfo/mpiwg-fortran
> 
> 
> 
> -- 
> Jeff Hammond
> jeff.science at gmail.com
> http://jeffhammond.github.io/
> _______________________________________________
> mpiwg-fortran mailing list
> mpiwg-fortran at lists.mpi-forum.org
> https://lists.mpi-forum.org/mailman/listinfo/mpiwg-fortran


-- 
Jeff Squyres
jsquyres at cisco.com



More information about the mpiwg-fortran mailing list