E3SM wrapper: parallel build, out of source, install, gated gcc flags - #162
Merged
Conversation
…#156) Wave B item 10. E3SM-IO upstream is autotools-only, so we keep the ExternalProject_Add wrapper, but clean up four long-standing issues: 1. Drop BUILD_COMMAND "make -j 1". Replace with BUILD_COMMAND $(MAKE) so the outer make's jobserver forwards -jN into the E3SM build. CI invokes the outer build with `make -j 2`; until now every job on the matrix was serialising the ~30+ TU E3SM tree. 2. BUILD_IN_SOURCE 0 + explicit BINARY_DIR. Keeps object files, Makefiles, config.log, etc. out of the submodule worktree. autoreconf still writes configure / Makefile.in into the source tree - that's an autotools limitation, not something we can fix in CMake. 3. Only pass CFLAGS=-fno-var-tracking-assignments (and the matching CXXFLAGS) when CMAKE_C_COMPILER_ID is GNU. That flag is a gcc-only debug-info-slowdown workaround; Clang warns or ignores it. 4. Add install(PROGRAMS ${CMAKE_BINARY_DIR}/h5bench_e3sm DESTINATION bin). Previously the INSTALL_COMMAND only copied the binary into the CMake build dir; `cmake --install` (or `make install`) left the E3SM binary behind. CI tests happen to run from the build dir so they masked this gap. Pinning the e3sm submodule to a specific upstream tag is the separate item 12 and covers all four submodules together. Verified locally (CMake 4.3.1, clang) that configure still succeeds and the baseline + exerciser + metadata targets build unchanged; the generated h5bench_e3sm build step now uses cmake -Dmake=$(MAKE) -P h5bench_e3sm-build-Release.cmake so the jobserver handoff is literal-$(MAKE)-as-expected.
jeanbez
force-pushed
the
redo-e3sm-wrapper
branch
from
June 29, 2026 00:20
51d0cf3 to
eb855d4
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Re-applies the content of #156, which was squash-merged into the now-deleted
wave-b-cmakebranch and did not propagate todevelop.Summary
BUILD_COMMAND make -j 1in favour of$(MAKE)so the outer Make jobserver forwards-jNinto the E3SM-IO build.BUILD_IN_SOURCE 0with an explicitBINARY_DIR, keepinge3sm/clean of object files and Makefiles (autoreconf still writes back into the source tree, an autotools limitation).CFLAGS=-fno-var-tracking-assignmentsonCMAKE_C_COMPILER_ID STREQUAL "GNU"so Clang does not warn or ignore it.install(PROGRAMS ${CMAKE_BINARY_DIR}/h5bench_e3sm DESTINATION bin)socmake --installactually ships the binary.Test plan
-DH5BENCH_E3SM=ONand confirm the build still succeeds.cmake --installand confirmh5bench_e3smends up in the installbin/.Recovery PR. Original squash commit: 83695ea. The E3SM block conflicted with develop's older version, resolved by taking the updated wrapper.