diff --git a/Force-alignment-of-opal_atomic_int128_t-to-be-16B.patch b/Force-alignment-of-opal_atomic_int128_t-to-be-16B.patch new file mode 100644 index 0000000..a34eeb6 --- /dev/null +++ b/Force-alignment-of-opal_atomic_int128_t-to-be-16B.patch @@ -0,0 +1,28 @@ +commit d9a5f9d9db092cc5b4d8fd563a834183b2e9b301 +Author: Joseph Schuchart +Date: Wed May 28 10:11:58 2025 -0400 + + Force alignment of opal_atomic_int128_t to be 16B + + Some architectures will align 128bit integer on 8B but require 16B alignment + for 128bit CAS instructions and otherwise fall back to a lock-based + atomicity model. By forcing 16bit alignment we can ensure that the variables + are properly aligned and the fall-back is not triggered. + + Thanks to Ulrich Weigand for the analysis and proposed fix in https://github.com/open-mpi/ompi/issues/10988#issuecomment-2913388506. + + Signed-off-by: Joseph Schuchart + +diff --git opal/include/opal_stdatomic.h opal/include/opal_stdatomic.h +index 354375512088..f7dd8353d3b6 100644 +--- opal/include/opal_stdatomic.h ++++ opal/include/opal_stdatomic.h +@@ -72,7 +72,7 @@ typedef _Atomic opal_int128_t opal_atomic_int128_t; + + # else + +-typedef volatile opal_int128_t opal_atomic_int128_t; ++typedef volatile opal_int128_t opal_atomic_int128_t __opal_attribute_aligned__(16); + + # endif + diff --git a/openmpi5.changes b/openmpi5.changes index 33083e8..b577b62 100644 --- a/openmpi5.changes +++ b/openmpi5.changes @@ -1,3 +1,10 @@ +------------------------------------------------------------------- +Mon May 26 15:52:53 UTC 2025 - Nicolas Morey + +- Fix bad git_ver appearing in VERSION +- Add Force-alignment-of-opal_atomic_int128_t-to-be-16B.patch to fix a 128b CAS issue on + s390x (bsc#1243680) + ------------------------------------------------------------------- Tue Apr 15 11:18:46 UTC 2025 - Nicolas Morey diff --git a/openmpi5.spec b/openmpi5.spec index 86526a8..5a12211 100644 --- a/openmpi5.spec +++ b/openmpi5.spec @@ -88,6 +88,7 @@ Source5: mpivars.csh Patch1: romio341-backport-fixes-from-mpich.patch Patch2: mtl-ofi-fix-missing-definition-of-container_of.patch Patch3: Fix-type-mismatch-error.patch +Patch4: Force-alignment-of-opal_atomic_int128_t-to-be-16B.patch Provides: mpi BuildRoot: %{_tmppath}/%{name}-%{version}-build # Exclude 32b archs @@ -310,7 +311,7 @@ echo FLAVOR %{flavor} %autosetup -p0 -n openmpi-%{version} # Live patch the VERSION file -sed -i -e 's/^greek=.*$/greek=%{git_ver}/' -e 's/^repo_rev=.*$/repo_rev=%{version}%{git_ver}/' \ +sed -i -e 's/^greek=.*$/greek=/' -e 's/^repo_rev=.*$/repo_rev=%{version}/' \ -e 's/^date=.*$/date="OpenMPI %{version} Distribution for SUSE"/' VERSION #############################################################################