[llvm] [X86][GlobalISel] Enable G_LROUND/G_LLROUND with libcall mapping (PR #125096)
via llvm-commits
llvm-commits at lists.llvm.org
Fri Jan 31 07:58:30 PST 2025
================
@@ -99,6 +99,18 @@ X86LegalizerInfo::X86LegalizerInfo(const X86Subtarget &STI,
.widenScalarToNextPow2(0, /*Min=*/8)
.clampScalar(0, s8, sMaxScalar);
+ getActionDefinitionsBuilder(G_LROUND)
+ .libcallIf([=](const LegalityQuery &Query) -> bool {
+ return (typeInSet(0, {s32, s64})(Query) &&
+ typeInSet(1, {s32, s64, s80})(Query));
+ });
+
+ getActionDefinitionsBuilder(G_LLROUND)
+ .libcallIf([=](const LegalityQuery &Query) -> bool {
+ return (typeIs(0, s64)(Query) &&
+ typeInSet(1, {s32, s64, s80})(Query));
+ });
----------------
JaydeepChauhan14 wrote:
Done
https://github.com/llvm/llvm-project/pull/125096
More information about the llvm-commits
mailing list