Skip to content

Commit d47954a

Browse files
committed
Guard the 'struct kmp_base_tas_lock' member fliping with macro __LP64__ instead of KMP_ARCH_PPC64.
1 parent b40be72 commit d47954a

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

openmp/runtime/src/kmp_lock.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -120,9 +120,9 @@ extern void __kmp_validate_locks(void);
120120

121121
struct kmp_base_tas_lock {
122122
// KMP_LOCK_FREE(tas) => unlocked; locked: (gtid+1) of owning thread
123-
#if __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__ && KMP_ARCH_PPC64
124-
// Swap the high and low 32-bit words to be consistent with the layout of
125-
// a 64-bit address in big-endian.
123+
#if __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__ && __LP64__
124+
// Flip the ordering of the high and low 32-bit member to be consistent
125+
// with the memory layout of the address in 64-bit big-endian.
126126
kmp_int32 depth_locked; // depth locked, for nested locks only
127127
std::atomic<kmp_int32> poll;
128128
#else

0 commit comments

Comments
 (0)