[PATCH] D104837: [PowerPC] Add XL compat __compare_and_swap builtins
Jinsong Ji via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Thu Jun 24 18:09:01 PDT 2021
jsji added inline comments.
================
Comment at: clang/test/CodeGen/builtins-ppc-xlcompat-cas.c:19
+// CHECK-NEXT: [[TMP2:%.*]] = cmpxchg weak volatile i32* [[A]], i32 [[TMP1]], i32 [[TMP0]] monotonic monotonic, align 4
+// CHECK-NEXT: [[TMP3:%.*]] = extractvalue { i32, i1 } [[TMP2]], 0
+// CHECK-NEXT: [[TMP4:%.*]] = extractvalue { i32, i1 } [[TMP2]], 1
----------------
w2yehia wrote:
> i dont think we need to check for the extractvalue instructions, they can be optimized away in theory.
Yes, but this is autogenerated for easier maintenance. Also, clang tests won't turn on optimization by default, so they won't be optimized away.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D104837/new/
https://reviews.llvm.org/D104837
More information about the cfe-commits
mailing list