Skip to content

Build: CMake 4.x compatibility, selectable C++ standard, GCC 16 / Clang 22 CI - #282

Merged
balay merged 5 commits into
masterfrom
balay/ci-clang-22-ucx-fix
Oct 15, 2026
Merged

balay merged 5 commits into
masterfrom
balay/ci-clang-22-ucx-fix

Conversation

@balay

@balay balay commented Oct 12, 2026 •

Copy link
Copy Markdown
Contributor

Used opencode/meta-muse-spark-1.3 initially, and claude/opus-5 to review/fix

@balay
balay force-pushed the balay/ci-clang-22-ucx-fix branch from 936f357 to ed1b404 Compare October 12, 2026 18:55
@balay

balay commented Oct 12, 2026

Copy link
Copy Markdown
Contributor Author

https://github.com/elemental/Elemental/actions/runs/38292005372/job/114954066492

this job likely needs fixes from #281 - will merge to test.

probably good to also add in gcc-16 test here. Ok pushed.

@balay balay changed the title CI: pin jobs to Ubuntu version and add Clang 22 on 26.04 CI: pin jobs to Ubuntu version and add Clang-22 Gcc-16 on 26.04 Oct 12, 2026
@balay
balay force-pushed the balay/ci-clang-22-ucx-fix branch 3 times, most recently from 369ccf4 to 98b160a Compare October 12, 2026 19:24
@balay

balay commented Oct 12, 2026

Copy link
Copy Markdown
Contributor Author

this job likely needs fixes from #281 - will merge to test.

https://github.com/elemental/Elemental/actions/runs/38297445428/job/114971842007

So this worked with the cmake fixes. will retest 'master' without the above PR.

@balay
balay force-pushed the balay/ci-clang-22-ucx-fix branch 3 times, most recently from 620927e to 38a383c Compare October 12, 2026 21:50
@balay balay changed the title CI: pin jobs to Ubuntu version and add Clang-22 Gcc-16 on 26.04 Build: CMake 4.x compatibility, selectable C++ standard, GCC 16 / Clang 22 CI Oct 12, 2026
@balay
balay force-pushed the balay/ci-clang-22-ucx-fix branch 2 times, most recently from 31b846c to 997f98f Compare October 12, 2026 22:52
@balay

balay commented Oct 13, 2026

Copy link
Copy Markdown
Contributor Author

This PR started off as:

  • fix UCX error in CI
  • update CI to newer version of compilers

But then - it triggered:

  • using latest Ubuntu version
  • fix build failure with cmake-4.x in ubuntu-26.04
  • Add cxx-17 and cxx-20 jobs to CI

But then this triggered

  • update to use CMAKE_CXX_STANDARD support from newer cmake versions

But then this triggered

  • deletion of current cmake/cxx config files. i.e a huge diff.

Maybe this is a good thing?

Any objections to merging this @andreasnoack, @prj-?

@balay

balay commented Oct 13, 2026

Copy link
Copy Markdown
Contributor Author

well, I assumed the fixes would also help in petsc CI - when we update to newer OS/compilers/cmake

@elemental elemental deleted a comment from prj- Oct 13, 2026
@balay
balay force-pushed the balay/ci-clang-22-ucx-fix branch from 997f98f to fa18422 Compare October 13, 2026 20:50
balay added 5 commits October 13, 2026 16:27
Pass CMAKE_POLICY_VERSION_MINIMUM=3.5 to ParMETIS/METIS/ScaLAPACK/BLIS
ExternalProjects, bump language_support_v2 to 3.5 so no top-level flag
is needed
Default to C++14, preserving previous behavior; override with
-DCMAKE_CXX_STANDARD=17 (or 20). GNU uses extended mode
(-std=gnu++XX, needed for libquadmath literals); other compilers
use strict mode.

Set before detect/CXX so CMP0067 propagates the standard into the
configure-time feature checks. Also append the flag to CXX_FLAGS,
which is what gets exported via Elemental_COMPILE_FLAGS and ElVars.

This leaves FindCXXFeatures.cmake as dead weight, so drop it:

- CXX14_COMPILER_FLAGS has no consumer left.
- CXX11_COMPILER_FLAGS only reached the module's own try_compile()s,
  adding a second -std that CMP0067 already supplies.
- Nothing read the CXXFeatures_*_FOUND results.
- CMAKE_CXX<N>_{STANDARD,EXTENSION}_COMPILE_OPTION already covers
  every standard per compiler, so there is no 17/20 variant to add.

The compiler_bugs/MSVC/constexpr reproducer reached the module via
external/cmake/, which no longer exists; switch it to
CMAKE_CXX_STANDARD.

config.h is unchanged at both C++14 and C++20.
- gcc-12 unavailable on 26.04
- Use per-OS runner to allow mixed-OS matrix
- Include OS in ccache key
Add gcc-16 and clang-22 jobs on ubuntu-26.04 alongside the existing
jobs. GCC 16 builds with C++17 and C++20 via CMAKE_CXX_STANDARD, and
Clang 22 with C++20, so the newest standard is exercised by both
compilers. C++14 remains covered by the GCC 14 and Clang 18 jobs, and
the GCC 12 job omits the flag to exercise the default (C++14) path.
@balay
balay force-pushed the balay/ci-clang-22-ucx-fix branch from fa18422 to 5740442 Compare October 13, 2026 21:38
@prj-

prj- commented Oct 14, 2026

Copy link
Copy Markdown
Contributor

Do you want to merge this before we update PETSc hash? Or just tag HEAD and we use it in BuildSystem?

@balay

balay commented Oct 14, 2026

Copy link
Copy Markdown
Contributor Author

I'm not sure if anyone in @elemental/developers are interested in reviewing this PR. Maybe I'll merge this in a few days (if no feedback)

I can check on PETSc changes after that. [we can always use this branch-head-HASH in petsc - if need - sure tag will also work - but I don't think its needed]

@prj-

prj- commented Oct 14, 2026

Copy link
Copy Markdown
Contributor

we can always use this branch-head-HASH in petsc

That’s what I did.

@balay
balay merged commit beebefe into master Oct 15, 2026
6 checks passed
@balay
balay deleted the balay/ci-clang-22-ucx-fix branch October 15, 2026 16:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants