[llvm-branch-commits] [libcxx] 198edf0 - [libc++] XFAIL align.pass.cpp for PowerPC LE

Louis Dionne via llvm-branch-commits llvm-branch-commits at lists.llvm.org
Thu Aug 26 10:23:11 PDT 2021


Author: Louis Dionne
Date: 2021-08-26T13:22:50-04:00
New Revision: 198edf09f58e19ae912206f871207af3ceace192

URL: https://github.com/llvm/llvm-project/commit/198edf09f58e19ae912206f871207af3ceace192
DIFF: https://github.com/llvm/llvm-project/commit/198edf09f58e19ae912206f871207af3ceace192.diff

LOG: [libc++] XFAIL align.pass.cpp for PowerPC LE

This patch XFAILs the `align.pass.cpp` for PowerPC (LE).

It appears that this test will fail on Power for the `LLIArr2` and `Padding` structs within the test,
as the `assert` for `alignof(AtomicImpl) >= sizeof(AtomicImpl)` will be false. In this case, these structs
presumably should not be lock-free, so we currently XFAIL this for now.

The failure was discovered after D97913 was committed. It looks like `alignof(AtomicImpl) < sizeof(AtomicImpl)`,
even prior to this commit, but this test began running on Power after D97913, whereas we were
not running `align.pass.cpp` before.

This patch addresses https://bugs.llvm.org/show_bug.cgi?id=51548 by temporarily XFAILing the test
in order to investigate it further.

Differential Revision: https://reviews.llvm.org/D108668

(cherry picked from commit f640c31e4b12e6d12d2fc540451e07bf49dba257)

Added: 
    

Modified: 
    libcxx/test/libcxx/atomics/atomics.align/align.pass.cpp

Removed: 
    


################################################################################
diff  --git a/libcxx/test/libcxx/atomics/atomics.align/align.pass.cpp b/libcxx/test/libcxx/atomics/atomics.align/align.pass.cpp
index 279fc090244f0..3735bb50367b8 100644
--- a/libcxx/test/libcxx/atomics/atomics.align/align.pass.cpp
+++ b/libcxx/test/libcxx/atomics/atomics.align/align.pass.cpp
@@ -20,6 +20,12 @@
 // std::atomic when used with __attribute__((vector(X))).
 // XFAIL: gcc
 
+// This fails on PowerPC, as the LLIArr2 and Padding structs do not have
+// adequate alignment, despite these types returning true for the query of
+// being lock-free. This is an issue that occurs when linking in the
+// PowerPC GNU libatomic library into the test.
+// XFAIL: target=powerpc{{.*}}le-unknown-linux-gnu
+
 // <atomic>
 
 // Verify that the content of atomic<T> is properly aligned if the type is


        


More information about the llvm-branch-commits mailing list