sourceryinstitute / OpenCoarrays

A parallel application binary interface for Fortran 2018 compilers.
http://www.opencoarrays.org
BSD 3-Clause "New" or "Revised" License
246 stars 55 forks source link

OpenCoarrays fail with mpich-4.1.2 + gcc-13.2.0 on macOS #781

Open mkowsiak opened 1 year ago

mkowsiak commented 1 year ago

OpenCoarrays fail with MPICH-4.1.2 compiled with GNU-13.2.0

> caf -o hello_world hello_world.f90
> cafrun -np 2 ./hello_world
 Hello world from            1 of           2
 Hello world from            2 of           2
Abort(5328655) on node 0 (rank 0 in comm 0): Fatal error in internal_Comm_free: Other MPI error, error stack:
internal_Comm_free(87).........: MPI_Comm_free(comm=0x1083962b8) failed
MPIR_Comm_free_impl(809).......:
MPIR_Comm_delete_internal(1224): Communicator (handle=84000002) being freed has 1 unmatched message(s)
Abort(407981839) on node 1 (rank 1 in comm 0): Fatal error in internal_Comm_free: Other MPI error, error stack:
internal_Comm_free(87).........: MPI_Comm_free(comm=0x100d842b8) failed
MPIR_Comm_free_impl(809).......:
MPIR_Comm_delete_internal(1224): Communicator (handle=84000001) being freed has 1 unmatched message(s)
Error: Command:
   `$HOME/opt/usr/local/mpich/mpich-4.1.2-gcc-13.2.0/bin/mpiexec -n 2 ./hello_world`
failed to run.

OpenCoarrays version

OpenCoarrays Coarray Fortran Compiler Wrapper (caf version 2.10.1)
Copyright (C) 2015-2022 Sourcery Institute
Copyright (C) 2015-2022 Archaeologic Inc.

OpenCoarrays comes with NO WARRANTY, to the extent permitted by law.
You may redistribute copies of OpenCoarrays under the terms of the
BSD 3-Clause License.  For more information about these matters, see
the file named LICENSE that is distributed with OpenCoarrays.

MPICH version

mpiexec --version
HYDRA build details:
    Version:                                 4.1.2
    Release Date:                            Wed Jun  7 15:22:45 CDT 2023
    CC:                              $HOME/opt/usr/local/gcc/gcc-13.2.0/bin/gcc-13.2.0
    Configure options:                       '--disable-option-checking' '--prefix=$HOME/opt/usr/local/mpich/mpich-4.1.2-gcc-13.2.0' '--with-hwloc=embedded' 'CC=$HOME/opt/usr/local/gcc/gcc-13.2.0/bin/gcc-13.2.0' 'CXX=$HOME/opt/usr/local/gcc/gcc-13.2.0/bin/g++-13.2.0' 'FC=$HOME/opt/usr/local/gcc/gcc-13.2.0/bin/gfortran-13.2.0' '--cache-file=/dev/null' '--srcdir=.' 'CFLAGS= -fno-common -O2' 'LDFLAGS=' 'LIBS=' 'CPPFLAGS= -DNETMOD_INLINE=__netmod_inline_ofi__ -I$HOME/opt/src/mpich-4.1.2/src/mpl/include -I$HOME/opt/src/mpich-4.1.2/modules/json-c -I$HOME/opt/src/mpich-4.1.2/modules/hwloc/include -D_REENTRANT -I$HOME/opt/src/mpich-4.1.2/src/mpi/romio/include -I$HOME/opt/src/mpich-4.1.2/src/pmi/include -I$HOME/opt/src/mpich-4.1.2/modules/yaksa/src/frontend/include -I$HOME/opt/src/mpich-4.1.2/modules/libfabric/include'
    Process Manager:                         pmi
    Launchers available:                     ssh rsh fork slurm ll lsf sge manual persist
    Topology libraries available:            hwloc
    Resource management kernels available:   user slurm ll lsf sge pbs cobalt
    Demux engines available:                 poll select

Source code

> cat hello_world.f90
program hello_world
implicit none
  write(*,*) 'Hello world from ', &
   this_image() , 'of', num_images()
end program hello_world
mkowsiak commented 1 year ago

I have built everything using following steps: https://www.owsiak.org/building-opencoarrays-on-macos-everything-from-the-sources-gcc-13-2-0/

IT – Philosophically Speaking » Blog Archive » Building OpenCoarrays on macOS– everything from the sources – gcc-13.2.0
rouson commented 4 months ago

@mkowsiak in case you're still interested, I just completed an installation using GCC 14.1.0 and MPICH 4.2.2. I'll do some more testing and update the OpenCoarrays installation scripts to use these versions. For now, my steps are described here.