Intel® MPI Library
Get help with building, analyzing, optimizing, and scaling high-performance computing (HPC) applications.
2229 Discussions

Bug in Intel MPI MPI_Allreduce "use mpi" implementation

Matt_Thompson
Novice
1,486 Views

I believe there is a bug in the Intel MPI MPI_AllReduce implementation when using "use mpi". To wit, a simple reproducer:

program test_allreduce
use mpi
implicit none

integer :: status, rank

call MPI_Init(ierror=status)
call MPI_COMM_RANK(MPI_COMM_WORLD,rank,ierror=status)
call MPI_ALLReduce(MPI_IN_PLACE,rank,1,MPI_INTEGER,MPI_MAX,MPI_COMM_WORLD,ierror=status)
call MPI_Finalize(ierror=status)

end program

And when you compile:

$ mpirun -V
Intel(R) MPI Library for Linux* OS, Version 2021.10 Build 20230619 (id: c2e19c2f3e)
Copyright 2003-2023, Intel Corporation.
$ mpiifort allreduce_bug.use_mpi.F90
allreduce_bug.use_mpi.F90(9): error #6632: Keyword arguments are invalid without an explicit interface.   [IERROR]
call MPI_ALLReduce(MPI_IN_PLACE,rank,1,MPI_INTEGER,MPI_MAX,MPI_COMM_WORLD,ierror=status)
--------------------------------------------------------------------------^
compilation aborted for allreduce_bug.use_mpi.F90 (code 1)

This seems similar to a bug I reported to MPICH (https://github.com/pmodels/mpich/issues/6693).

If you move to "use mpi_f08" it does seem to compile, so it looks to be a bug just in the "use mpi" implementation.

Note that Open MPI seems happy with it:

$ mpirun -V
mpirun (Open MPI) 4.1.5

Report bugs to http://www.open-mpi.org/community/help/
$ mpifort allreduce_bug.use_mpi.F90
$ echo $?
0

 

0 Kudos
4 Replies
VeenaJ_Intel
Moderator
1,422 Views

Hi,

 

Thank you for posting in Intel Communities

 

We were able to reproduce the issue. and we are investigating at our end.

 

Regards,

Veena

 

0 Kudos
VeenaJ_Intel
Moderator
1,394 Views

Hi,

 

We do not provide explicit interfaces for MPI_ALLREDUCE, which is complaint to the MPI standard:

 

https://www.mpi-forum.org/docs/mpi-3.1/mpi31-report/node410.htm

 

Provide explicit interfaces according to the Fortran routine interface specifications. This module therefore guarantees compile-time argument checking and allows positional and keyword-based argument lists. If an implementation is paired with a compiler that either does not support TYPE(*), DIMENSION(..) from TS 29113, or is otherwise unable to ignore the types of choice buffers, then the implementation must provide explicit interfaces only for MPI routines with no choice buffer arguments. See Section MPI for Different Fortran Standard Versions for more details.

 

Please feel free to reach out if you have any further queries.

 

Regards,

Veena

 

 

 

 

 

 

 

0 Kudos
VeenaJ_Intel
Moderator
1,334 Views

Hi,

 

We have not heard back from you.  Could you kindly confirm whether the explanation provided addresses your question?

 

Regards,

Veena

 

 

0 Kudos
VeenaJ_Intel
Moderator
1,261 Views

Hi,

 

I assume that your issue is resolved. If you need any additional information, please post a new question as this thread will no longer be monitored by Intel.

 

Regards,

Veena

 

0 Kudos
Reply