Skip to content

[5.0.x] Force alignment of opal_atomic_int128_t to be 16B #13282

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

Open
wants to merge 1 commit into
base: v5.0.x
Choose a base branch
from

Conversation

devreal
Copy link
Contributor

@devreal devreal commented May 28, 2025

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 #10988 (comment).

Backport of #13281 to v5.0.x

(cherry picked from commit d5c84ea)

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 open-mpi#10988 (comment).

Signed-off-by: Joseph Schuchart <joseph.schuchart@stonybrook.edu>
(cherry picked from commit d5c84ea)
@devreal devreal requested a review from bosilca May 28, 2025 20:36
@github-actions github-actions bot added this to the v5.0.8 milestone May 28, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants