Re: OpenMPI Fortran: 'Error reading module mpi' and unexpected but silent termination



In article <fg82mo$rto$1@xxxxxxxxxxxxxxxx>,
Koen Poppe<MyFirstName.MyLastName@xxxxxxxxxxxxxxxxxxx> writes:

I'm encountering very strange behaviour with the very basic MPI/Fortran
program listed at the end of the message on a system running KUbuntu and
with the following compilers:
- gcc (GCC) 4.1.2 (Ubuntu 4.1.2-0ubuntu4)
- GNU-Fortran compiler, 4.3.0 20071002 (experimental)
- OpenMPI 1.1-2.3

Did you compile 0pen MPI with gcc and gfortran 4.1.2 as bundled
with Ubuntu, and now you're trying to use gfortran 4.3.0?


Compiling the program with the only "USE MPI" statement uncommented and
compiling with the "mpif90" wrapper resulted in this output:
> mpif90 foo.f90 --showme
gfortran -pthread -I/usr/lib foo.f90 -lmpi_f90 -lmpi -lorte -lopal -ldl
-Wl,--export-dynamic -lnsl -lutil -lm -ldl Fatal Error: Reading module mpi at line 110 column 31: Expected string

The module file is present at "/usr/lib/mpi.mod" but there seems to be a
problem while reading (the following) line 110:
(273 'impi_client_color' 'mpi' 1 ((PARAMETER UNKNOWN-INTENT
UNKNOWN-PROC UNKNOWN) (INTEGER 4 ()) 0 0 () (CONSTANT (INTEGER 4 ()) 0 '11') () 0 ()
())

It's not easy to understand the "*.o" file format for me. Note that this
"mpi.mod" file looks to be generated with the same compiler, as is
indicated by it's first line:
GFORTRAN module created from mpi.f90 on Fri Jan 26 16:06:27 2007

This version was abandoned as we couldn't fine a way to solve this...

This suggests that you may be using a module compiled with
gfortran 4.1.2 with gfortran 4.3.0 (or vice-versa). What does

mpif90 --version show?
what are the top 2 lines of /usr/lib/mpi.mod?

I'll note that I just built my code that use Open MPI with
gfortran without any problems. The resulting program was
used to run several simulations.

--
Steve
http://troutmask.apl.washington.edu/~kargl/
.



Relevant Pages

  • Re: Compilation problem with gfortran
    ... I'm trying to compile some code of mine with gfortran. ... Argument 'dydx' of pure subroutine 'rkckcontrolstep' at must ... Sun compilers accept this, but I appreciate that that isn't a definitive ...
    (comp.lang.fortran)
  • Re: Suspicious Gfortran
    ... Fortran 77 compilers that exist, and thus doesn't mean anything in this ... problem is coming from a bug in your code, rather than a bug in gfortran. ...
    (comp.lang.fortran)
  • Re: Suspicious Gfortran
    ... gfortran 4.2: endless loop. ... the code is imperfect but works under f77, ... Thus, I would say that chances are quite good that your infinite loop problem is coming from a bug in your code, rather than a bug in gfortran. ... At the very least, gfortran is certainly stable enough that it would be unwise to dismiss this as a probable compiler bug without trying to track it down -- there are all sorts of bugs that can cause "looks right, but is subtly wrong" behavior on some compilers and cause "doesn't work at all" on other compilers, and this could quite easily be one of those. ...
    (comp.lang.fortran)
  • Re: Suspicious Gfortran
    ... If it is the latter then attempting to install it is pointless. ... Following wise advice I updated the gfortran alternative from 4.0.x to ... you can report a bug in bugzilla or email the gfortran list at fortran ... I also suggest getting trial versions of commercial compilers, ...
    (comp.lang.fortran)
  • Re: Which Standard Libraries for gfortran?
    ... I'd much rather see the g95/gfortran folk put their energy into ... If they build quality compilers, ... The discussion arose (in the gfortran work group) about whether MATMUL ... Scott Robert Ladd ...
    (comp.lang.fortran)