-
Notifications
You must be signed in to change notification settings - Fork 143
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
NCEP libraries: gfortran 10.2.0 and the argument-mismatch #158
Comments
i'll give you some history on why it is how it is. the prepbufr libraries are downloaded from NCEP. they have been updated over the years but the original code is very old. we decided to make as few changes as possible so when a new version was downloaded it wouldn't require redoing a lot of work that would again get lost in the next update. install.sh is what comes with the libs, and the strange directory structure and filename convention (bob.x for executables) is all theirs. the prepbufr obs converter itself is very much based on a dump program that is distributed with the library. having said that, yes, i snuck some code into install.sh to try to use the "current" compiler if running in a higher level script. i'm not sure if any of the other FFLAGS we set in mkmf.template will cause the libs to not compile. if not, then sure, the same process can be extended, i'd think. users may still want to build just the ncep libs, so install.sh needs to be able to work standalone and not only in a testing environment. i'll caution people not to try to "fix" the lib code itself unless it won't build. as long as it's working, no one cares and anything done there will be overwritten if a new version is downloaded. if you don't look, you won't be horrified. |
So I am 'discovering' this problem again. Just to recap and to help aid in any possible searches, here is an example of the error:
Fixing
fixes that for the NCEP libraries - easy. However - in addition to the NCEP prepbufr libraries, our mpi_utilities_mod.f90 is (still) throwing the errors and requires the |
i sent this by email to a couple people but really i should have made the comment here so all the discussion is in one place: i just looked at this code. i'm a bit confused about what gfortran is unhappy about. the arguments to our sum_across_tasks_real() routine are scalar, but they're moved into rank 1 arrays to be passed to MPI_AllReduce because that's what the interface is documented to require. i'd try to fix the code if i understood what problem it is complaining about. |
Tim - what is the code you are building that is getting the error? I can not reproduce the error. I'm using gfortran version: I'm going to build 10.2.0 to see if it is a problem with 10.2.0. |
Seriously?!
I am using GNU Fortran (MacPorts gcc10 10.2.0_5) 10.2.0
the 'standard' mkmf.template.gfortran
with the lorenz_96 quickbuild.csh -mpi
*0[1131]**cam-fv_even_sphere **~/<3>lorenz_96/work * % mpif90 --version
GNU Fortran (MacPorts gcc10 10.2.0_5) 10.2.0
Copyright (C) 2020 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
And I'm relatively certain I installed it with:
port select --list mpi
sudo port select --set mpi mpich-mp-fortran
Can you build the NCEP libraries without the switch? That should absolve
the mpi portion of the equation, in any event.
|
Ok, I was using openmpi |
I think the mpi_utilities errors are mpich using f77 bindings when you hello.f90.txt The f08 mpi module or short term solution: |
closing this since:
|
GNU Fortran (MacPorts gcc10 10.2.0_5) 10.2.0 is very strict about rank mismatches and such. Putting
-fallow-argument-mismatch
in the FFLAGS allows the compiler to proceed - but it still throws a ton of warnings, which is a bit of unnecessary chatter in the output log.Worse ... the NCEP libraries do not build without manual intervention, because they do not use the mkmf.template - they use the
NCEP/prep_bufr/install.sh
script to build - which does not dynamically use the FFLAGS from themkmf.template
.The
obs_converters/run_tests.csh
script queries themkmf.template
for the compiler and then sets some variables that are used byinstall.sh
... perhaps this can be extended to use theFFLAGS
as well.The text was updated successfully, but these errors were encountered: