-
Notifications
You must be signed in to change notification settings - Fork 369
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
cam.buildlib failed on Summit with default IBM XL compiler #3183
Comments
@sarats Could you please try to reproduce this build error on Summit with default XL compiler? You can use a low-res F case (--compset FC5AV1C-H01B --res ne4_ne4). Just test with latest E3SM master branch, and merge jackreeveseyre/cime/sfc_flux_bug_fix to fix a known build issue in shr_flux_mod.F90. |
@dqwu This is interesting. The PR/commit you refer to simply split a function (initmp) into two functions, to allow to easily injecting homme into an app with an already existing arbitrary comm. The inclusion of As for the multiple inclusion of mpif, I'm not sure. That's how it was before, so I didn't want to change it. Since the first inclusion is at module level, I think it "should" be safe to remove the other inclusions. |
Also, homme has always relied on Edit: nvm, the issue is that MPI_MAX_PROCESSOR_NAME before was used only inside an I will submit a quick PR with the bugfix. In the PR I will also experiment the removal of the redundant |
The constant MPI_MAX_PROCESSOR_NAME is only defined if mpi headers are included, so it *must* be used only inside blocks guarded by `#ifdef _MPI` Also, removing redundant inclusion of mpif.h.
@bartgol |
MPI_MAX_PROCESSOR_NAME was used after the inclusion of mpif.h:
When it is used before the inclusion of mpif.h (as in latest code), GNU compiler is OK with it but XL compiler complains "Name given for constant with PARAMETER attribute was defined elsewhere with conflicting attributes" when mpif.h is included. |
@dqwu, I have a branch ready, I can issue a PR right away. Just one question: I have a fix that also allows to use Clang to test homme (with c++, it helps detecting some non-standart compliant bugs). It's a quick fix that fixes how the openmp flags were set when C and F compiler differ. Is it ok if I piggy back that fix onto this one or would you like to keep the PR contained to this issue? |
@bartgol I prefer to have a PR that just fixes this issue. You can issue another PR that allows to use Clang to test homme. |
The constant MPI_MAX_PROCESSOR_NAME is only defined if mpi headers are included, so it *must* be used only inside blocks guarded by `#ifdef _MPI` Also, removing redundant inclusion of mpif.h.
The constant MPI_MAX_PROCESSOR_NAME is only defined if mpi headers are included, so it *must* be used only inside blocks guarded by `#ifdef _MPI` Also, removing redundant inclusion of mpif.h.
The constant MPI_MAX_PROCESSOR_NAME is only defined if mpi headers are included, so it *must* be used only inside blocks guarded by `#ifdef _MPI` Also, removing redundant inclusion of mpif.h.
The constant MPI_MAX_PROCESSOR_NAME is only defined if mpi headers are included, so it must be used only inside blocks guarded by #ifdef _MPI Also, removing redundant inclusion of mpif.h. Fixes #3183
On Summit, after merging pending PR #3153 locally to fix build issue #3105, there is a new build error from cam (reproducible with F case):
ERROR: BUILD FAIL: cam.buildlib failed
The error message in atm.bldlog shows:
Line 63 of mpif-config.h is:
parameter (MPI_MAX_PROCESSOR_NAME=256-1)
With above information we can find out that the failure is caused by PR #3094.
More specifically, by the following code block added in commit 1af9d61
This code block has two build issues:
A proposed fix is like below:
PS, for module parallel_mod, mpif.h is already included at the beginning:
Is there a reason to include it again inside each of the 4 subroutines listed below?
subroutine init_par
subroutine initmp_from_par(par)
subroutine syncmp(par)
subroutine syncmp_comm(comm)
The text was updated successfully, but these errors were encountered: