[llvm-branch-commits] [llvm] AArch64: Use consistent atomicrmw expansion for FP operations (PR #103702)
Matt Arsenault via llvm-branch-commits
llvm-branch-commits at lists.llvm.org
Thu Aug 22 13:06:50 PDT 2024
================
@@ -27056,21 +27056,35 @@ AArch64TargetLowering::shouldExpandAtomicLoadInIR(LoadInst *LI) const {
: AtomicExpansionKind::LLSC;
}
+// Return true if the atomic operation expansion will lower to use a library
+// call, and is thus ineligible to use an LLSC expansion.
+static bool rmwOpMayLowerToLibcall(const AtomicRMWInst *RMW) {
+ if (!RMW->isFloatingPointOperation())
+ return false;
+ switch (RMW->getType()->getScalarType()->getTypeID()) {
+ case Type::FloatTyID:
+ case Type::DoubleTyID:
+ case Type::HalfTyID:
+ case Type::BFloatTyID:
+ return false;
----------------
arsenm wrote:
Seems to not do anything?
https://github.com/llvm/llvm-project/pull/103702
More information about the llvm-branch-commits
mailing list