[llvm] [NFC ]Add a helper function isTailCall for getting libcall in SelectionDAG (PR #155256)
zhijian lin via llvm-commits
llvm-commits at lists.llvm.org
Mon Sep 8 12:15:24 PDT 2025
================
@@ -9012,6 +9012,14 @@ static void checkAddrSpaceIsValidForLibcall(const TargetLowering *TLI,
}
}
+static bool isTailCall(const CallInst *CI, const SelectionDAG *SelDAG,
+ bool IsLowerToLibCall) {
+ bool ReturnsFirstArg = CI && funcReturnsFirstArgOfCall(*CI);
+ return CI && CI->isTailCall() &&
+ isInTailCallPosition(*CI, SelDAG->getTarget(),
+ ReturnsFirstArg && IsLowerToLibCall);
----------------
diggerlin wrote:
thanks for explain to me in person, I add TODO comment as your suggestion.
https://github.com/llvm/llvm-project/pull/155256
More information about the llvm-commits
mailing list