[llvm] RuntimeLibcalls: Emit all available impls for a libcall, not just one (PR #210915)
Matt Arsenault via llvm-commits
llvm-commits at lists.llvm.org
Wed Jul 29 11:51:44 PDT 2026
https://github.com/arsenm updated https://github.com/llvm/llvm-project/pull/210915
>From 45ed54cbc7a9e712493222717bd86eaec82e2753 Mon Sep 17 00:00:00 2001
From: Matt Arsenault <Matthew.Arsenault at amd.com>
Date: Tue, 21 Jul 2026 11:06:15 +0200
Subject: [PATCH 1/3] RuntimeLibcalls: Emit all available impls for a libcall,
not just one
The intent is RuntimeLibcalls should represent all functions that are
callable from the module, which may have contextually selectable alternatives.
Previously we had this warning since there was no mechanism to select which
one you want, and as a workaround the library call sets avoided adding the
variants which should nto be selected.
Now targets can use initLibcallLoweringInfo, so remove the warning to unblock
more libcall cleanups. Eventually initLibcallLoweringInfo should also be tablegen
driven.
Co-authored-by: Claude (Claude-Opus-4.8) <noreply at anthropic.com>
---
...> RuntimeLibcallEmitter-multiple-impls.td} | 17 ++++++-----
.../TableGen/Basic/RuntimeLibcallsEmitter.cpp | 28 ++-----------------
2 files changed, 13 insertions(+), 32 deletions(-)
rename llvm/test/TableGen/{RuntimeLibcallEmitter-conflict-warning.td => RuntimeLibcallEmitter-multiple-impls.td} (84%)
diff --git a/llvm/test/TableGen/RuntimeLibcallEmitter-conflict-warning.td b/llvm/test/TableGen/RuntimeLibcallEmitter-multiple-impls.td
similarity index 84%
rename from llvm/test/TableGen/RuntimeLibcallEmitter-conflict-warning.td
rename to llvm/test/TableGen/RuntimeLibcallEmitter-multiple-impls.td
index 7b88483c3673a..76182bd572e42 100644
--- a/llvm/test/TableGen/RuntimeLibcallEmitter-conflict-warning.td
+++ b/llvm/test/TableGen/RuntimeLibcallEmitter-multiple-impls.td
@@ -1,8 +1,11 @@
// RUN: llvm-tblgen -gen-runtime-libcalls -I %p/../../include %s 2> %t.err | FileCheck %s
-// RUN: FileCheck -check-prefix=ERR %s < %t.err
+// RUN: count 0 < %t.err
// Check behavior of libcall emission when multiple RuntimeLibcallImpl
-// implementations provide the same RuntimeLibcall
+// implementations provide the same RuntimeLibcall. This table records which
+// implementations are available, not which one is selected, so all of the
+// implementations are emitted; selection of the preferred one is a separate
+// concern handled by LibcallLoweringInfo. No diagnostic is emitted.
include "llvm/IR/RuntimeLibcallsImpl.td"
@@ -37,6 +40,7 @@ def dup1 : RuntimeLibcallImpl<ANOTHER_DUP>;
// CHECK-NEXT: static const RTLIB::LibcallImpl LibraryCalls[] = {
// CHECK-NEXT: RTLIB::impl_func_b, // func_b
+// CHECK-NEXT: RTLIB::impl_func_a, // func_a
// CHECK-NEXT: };
// CHECK-EMPTY:
// CHECK-NEXT: for (const RTLIB::LibcallImpl Impl : LibraryCalls) {
@@ -46,7 +50,6 @@ def dup1 : RuntimeLibcallImpl<ANOTHER_DUP>;
// CHECK-NEXT: return;
// CHECK-NEXT: }
-// ERR: :[[@LINE+1]]:5: warning: conflicting implementations for libcall SOME_FUNC: func_b, func_a
def TheSystemLibraryA : SystemRuntimeLibrary<isTargetArchA,
(add func_b, func_a)
>;
@@ -60,6 +63,7 @@ def TheSystemLibraryA : SystemRuntimeLibrary<isTargetArchA,
// CHECK-NEXT: static const RTLIB::LibcallImpl LibraryCalls[] = {
// CHECK-NEXT: RTLIB::impl_other_func, // other_func
// CHECK-NEXT: RTLIB::impl_func_a, // func_a
+// CHECK-NEXT: RTLIB::impl_func_b, // func_b
// CHECK-NEXT: };
// CHECK-EMPTY:
// CHECK-NEXT: for (const RTLIB::LibcallImpl Impl : LibraryCalls) {
@@ -69,7 +73,6 @@ def TheSystemLibraryA : SystemRuntimeLibrary<isTargetArchA,
// CHECK-NEXT: return;
// CHECK-NEXT: }
-// ERR: :[[@LINE+1]]:5: warning: conflicting implementations for libcall SOME_FUNC: func_a, func_b
def TheSystemLibraryB : SystemRuntimeLibrary<isTargetArchB,
(add func_a, other_func, func_b)
>;
@@ -82,8 +85,11 @@ def TheSystemLibraryB : SystemRuntimeLibrary<isTargetArchB,
// CHECK-EMPTY:
// CHECK-NEXT: static const RTLIB::LibcallImpl LibraryCalls[] = {
// CHECK-NEXT: RTLIB::impl_dup1, // dup1
+// CHECK-NEXT: RTLIB::impl_dup0, // dup0
// CHECK-NEXT: RTLIB::impl_other_func, // other_func
// CHECK-NEXT: RTLIB::impl_func_a, // func_a
+// CHECK-NEXT: RTLIB::impl_func_b, // func_b
+// CHECK-NEXT: RTLIB::impl_func_c, // func_c
// CHECK-NEXT: };
// CHECK-EMPTY:
// CHECK-NEXT: for (const RTLIB::LibcallImpl Impl : LibraryCalls) {
@@ -93,9 +99,6 @@ def TheSystemLibraryB : SystemRuntimeLibrary<isTargetArchB,
// CHECK-NEXT: return;
// CHECK-NEXT: }
-// ERR: :[[@LINE+3]]:5: warning: conflicting implementations for libcall ANOTHER_DUP: dup1, dup0
-// ERR: :[[@LINE+2]]:5: warning: conflicting implementations for libcall SOME_FUNC: func_a, func_b
-// ERR: :[[@LINE+1]]:5: warning: conflicting implementations for libcall SOME_FUNC: func_a, func_c
def TheSystemLibraryC : SystemRuntimeLibrary<isTargetArchC,
(add func_a, dup1, other_func, func_b, func_c, dup0)
>;
diff --git a/llvm/utils/TableGen/Basic/RuntimeLibcallsEmitter.cpp b/llvm/utils/TableGen/Basic/RuntimeLibcallsEmitter.cpp
index e8746c6dcfcdb..7a0bd4228117c 100644
--- a/llvm/utils/TableGen/Basic/RuntimeLibcallsEmitter.cpp
+++ b/llvm/utils/TableGen/Basic/RuntimeLibcallsEmitter.cpp
@@ -476,36 +476,14 @@ void RuntimeLibcallEmitter::emitSystemRuntimeLibrarySetCalls(
std::vector<const RuntimeLibcallImpl *> &Funcs = FuncsWithCC.LibcallImpls;
- // Ensure we only emit a unique implementation per libcall in the
- // selection table.
- //
- // FIXME: We need to generate separate functions for
- // is-libcall-available and should-libcall-be-used to avoid this.
- //
- // This also makes it annoying to make use of the default set, since the
- // entries from the default set may win over the replacements unless
- // they are explicitly removed.
+ // This table records which implementations are available, not which one
+ // is selected, so a libcall may legitimately have more than one available
+ // implementation
stable_sort(Funcs, [](const RuntimeLibcallImpl *A,
const RuntimeLibcallImpl *B) {
return A->getProvides()->getEnumVal() < B->getProvides()->getEnumVal();
});
- auto UniqueI = llvm::unique(
- Funcs, [&](const RuntimeLibcallImpl *A, const RuntimeLibcallImpl *B) {
- if (A->getProvides() == B->getProvides()) {
- PrintWarning(R->getLoc(),
- Twine("conflicting implementations for libcall " +
- A->getProvides()->getName() + ": " +
- A->getLibcallFuncName() + ", " +
- B->getLibcallFuncName()));
- return true;
- }
-
- return false;
- });
-
- Funcs.erase(UniqueI, Funcs.end());
-
OS << indent(IndentDepth + 2)
<< "static const RTLIB::LibcallImpl LibraryCalls";
SubsetPredicate.emitTableVariableNameSuffix(OS);
>From 67578f96fd367d35cd589fd402ad18def4cd36ff Mon Sep 17 00:00:00 2001
From: Matt Arsenault <Matthew.Arsenault at amd.com>
Date: Mon, 27 Jul 2026 09:54:32 +0200
Subject: [PATCH 2/3] MSP430: Mark more generic libgcc functions as available
(#210962)
The generic soft-float, conversion, comparison and integer helper
routines (__addsf3, __divli's __divsi3, __ashlsi3, ...) exist in the MSP430
libgcc port alongside the preferred __mspabi_* variants. They were previously
removed to force selection of the __mspabi_* names, back when only one
implementation per libcall could be recorded.
Stop hiding them: only __lshrsi3 stays excluded, since the MSP430 libgcc
port provides the 32-bit logical right shift solely under __mspabi_srll and
never defines a generic __lshrsi3.
Co-authored-by: Claude (Claude-Opus-4.8) <noreply at anthropic.com>
---
llvm/include/llvm/IR/RuntimeLibcalls.td | 15 ++---
llvm/lib/Target/MSP430/MSP430Subtarget.cpp | 67 ++++++++++++++++++++++
2 files changed, 71 insertions(+), 11 deletions(-)
diff --git a/llvm/include/llvm/IR/RuntimeLibcalls.td b/llvm/include/llvm/IR/RuntimeLibcalls.td
index 1af3344023627..4b3e3b2ae76ea 100644
--- a/llvm/include/llvm/IR/RuntimeLibcalls.td
+++ b/llvm/include/llvm/IR/RuntimeLibcalls.td
@@ -2962,18 +2962,11 @@ def __mspabi_mpyll : RuntimeLibcallImpl<MUL_I64>;
def isMSP430 : RuntimeLibcallAvailability<(all_of IsMSP430)>;
+// msp430 libgcc provides the 32-bit logical right shift only under
+// the __mspabi_srll name. Everything else in the default list
+// coexists in msp430 libgcc alongside its __mspabi_* variant.
defvar MSP430DefaultOptOut = [
- __addsf3, __divsf3, __extendsfdf2, __truncdfsf2, __fixsfsi,
- __fixsfdi, __fixunssfsi, __mulsf3, __eqsf2, __gesf2, __gtsf2,
- __divhi3, __divsi3, __ashlsi3, __floatsidf, __floatsisf,
- __ashrsi3, __modhi3, __udivsi3, __fixdfsi, __fixunssfdi,
- __udivhi3, __umodsi3, __nesf2, __lesf2, __floatundisf,
- __fixdfdi, __fixunsdfsi, __modsi3, __floatunsisf,
- __fixunsdfdi, __ltsf2, __floatdisf, __floatdidf,
- __lshrsi3, __subsf3, __umodhi3, __floatunsidf,
- __floatundidf, __gtdf2, __eqdf2, __gedf2, __ltdf2, __ledf2,
- __adddf3, __divdf3, __divdi3, __moddi3,
- __muldf3, __subdf3, __udivdi3, __umoddi3
+ __lshrsi3
];
// EABI Libcalls - EABI Section 6.2
diff --git a/llvm/lib/Target/MSP430/MSP430Subtarget.cpp b/llvm/lib/Target/MSP430/MSP430Subtarget.cpp
index 386f2a0fa8f47..7e575864f4027 100644
--- a/llvm/lib/Target/MSP430/MSP430Subtarget.cpp
+++ b/llvm/lib/Target/MSP430/MSP430Subtarget.cpp
@@ -131,4 +131,71 @@ void MSP430Subtarget::initLibcallLoweringInfo(LibcallLoweringInfo &Info) const {
Info.setLibcallImpl(LC.Op, LC.Impl);
}
}
+
+ // The generic soft-float/integer helper routines (__addsf3, __divli, ...)
+ // exist in msp430 libgcc alongside the __mspabi_* variants, so both are
+ // available. The __mspabi_* variants are the one that should be used.
+ static const struct {
+ const RTLIB::Libcall Op;
+ const RTLIB::LibcallImpl Impl;
+ } EABISelected[] = {
+ // Floating point conversions - EABI Table 6.
+ {RTLIB::FPROUND_F64_F32, RTLIB::impl___mspabi_cvtdf},
+ {RTLIB::FPEXT_F32_F64, RTLIB::impl___mspabi_cvtfd},
+ {RTLIB::FPTOSINT_F64_I32, RTLIB::impl___mspabi_fixdli},
+ {RTLIB::FPTOSINT_F64_I64, RTLIB::impl___mspabi_fixdlli},
+ {RTLIB::FPTOUINT_F64_I32, RTLIB::impl___mspabi_fixdul},
+ {RTLIB::FPTOUINT_F64_I64, RTLIB::impl___mspabi_fixdull},
+ {RTLIB::FPTOSINT_F32_I32, RTLIB::impl___mspabi_fixfli},
+ {RTLIB::FPTOSINT_F32_I64, RTLIB::impl___mspabi_fixflli},
+ {RTLIB::FPTOUINT_F32_I32, RTLIB::impl___mspabi_fixful},
+ {RTLIB::FPTOUINT_F32_I64, RTLIB::impl___mspabi_fixfull},
+ {RTLIB::SINTTOFP_I32_F64, RTLIB::impl___mspabi_fltlid},
+ {RTLIB::SINTTOFP_I64_F64, RTLIB::impl___mspabi_fltllid},
+ {RTLIB::UINTTOFP_I32_F64, RTLIB::impl___mspabi_fltuld},
+ {RTLIB::UINTTOFP_I64_F64, RTLIB::impl___mspabi_fltulld},
+ {RTLIB::SINTTOFP_I32_F32, RTLIB::impl___mspabi_fltlif},
+ {RTLIB::SINTTOFP_I64_F32, RTLIB::impl___mspabi_fltllif},
+ {RTLIB::UINTTOFP_I32_F32, RTLIB::impl___mspabi_fltulf},
+ {RTLIB::UINTTOFP_I64_F32, RTLIB::impl___mspabi_fltullf},
+ // Floating point comparisons - EABI Table 7.
+ {RTLIB::OEQ_F64, RTLIB::impl___mspabi_cmpd__oeq},
+ {RTLIB::OGE_F64, RTLIB::impl___mspabi_cmpd__oge},
+ {RTLIB::OLT_F64, RTLIB::impl___mspabi_cmpd__olt},
+ {RTLIB::OLE_F64, RTLIB::impl___mspabi_cmpd__ole},
+ {RTLIB::OGT_F64, RTLIB::impl___mspabi_cmpd__ogt},
+ {RTLIB::OEQ_F32, RTLIB::impl___mspabi_cmpf__oeq},
+ {RTLIB::UNE_F32, RTLIB::impl___mspabi_cmpf__une},
+ {RTLIB::OGE_F32, RTLIB::impl___mspabi_cmpf__oge},
+ {RTLIB::OLT_F32, RTLIB::impl___mspabi_cmpf__olt},
+ {RTLIB::OLE_F32, RTLIB::impl___mspabi_cmpf__ole},
+ {RTLIB::OGT_F32, RTLIB::impl___mspabi_cmpf__ogt},
+ // Floating point arithmetic - EABI Table 8.
+ {RTLIB::ADD_F64, RTLIB::impl___mspabi_addd},
+ {RTLIB::SUB_F64, RTLIB::impl___mspabi_subd},
+ {RTLIB::MUL_F64, RTLIB::impl___mspabi_mpyd},
+ {RTLIB::DIV_F64, RTLIB::impl___mspabi_divd},
+ {RTLIB::ADD_F32, RTLIB::impl___mspabi_addf},
+ {RTLIB::SUB_F32, RTLIB::impl___mspabi_subf},
+ {RTLIB::MUL_F32, RTLIB::impl___mspabi_mpyf},
+ {RTLIB::DIV_F32, RTLIB::impl___mspabi_divf},
+ // Universal Integer Operations - EABI Table 9.
+ {RTLIB::SDIV_I16, RTLIB::impl___mspabi_divi},
+ {RTLIB::SDIV_I32, RTLIB::impl___mspabi_divli},
+ {RTLIB::SDIV_I64, RTLIB::impl___mspabi_divlli},
+ {RTLIB::UDIV_I16, RTLIB::impl___mspabi_divu},
+ {RTLIB::UDIV_I32, RTLIB::impl___mspabi_divul},
+ {RTLIB::UDIV_I64, RTLIB::impl___mspabi_divull},
+ {RTLIB::SREM_I16, RTLIB::impl___mspabi_remi},
+ {RTLIB::SREM_I32, RTLIB::impl___mspabi_remli},
+ {RTLIB::SREM_I64, RTLIB::impl___mspabi_remlli},
+ {RTLIB::UREM_I16, RTLIB::impl___mspabi_remu},
+ {RTLIB::UREM_I32, RTLIB::impl___mspabi_remul},
+ {RTLIB::UREM_I64, RTLIB::impl___mspabi_remull},
+ // Bitwise Operations - EABI Table 10.
+ {RTLIB::SHL_I32, RTLIB::impl___mspabi_slll},
+ {RTLIB::SRA_I32, RTLIB::impl___mspabi_sral},
+ };
+ for (const auto &LC : EABISelected)
+ Info.setLibcallImpl(LC.Op, LC.Impl);
}
>From 15fc39d9059f804b506ceb2109695077e15f0290 Mon Sep 17 00:00:00 2001
From: Matt Arsenault <Matthew.Arsenault at amd.com>
Date: Mon, 27 Jul 2026 11:08:43 +0200
Subject: [PATCH 3/3] Revert "MSP430: Mark more generic libgcc functions as
available (#210962)"
This reverts commit a7543e65d6b24ff4ea2d8bee1cc676980f4bf76c.
---
llvm/include/llvm/IR/RuntimeLibcalls.td | 15 +++--
llvm/lib/Target/MSP430/MSP430Subtarget.cpp | 67 ----------------------
2 files changed, 11 insertions(+), 71 deletions(-)
diff --git a/llvm/include/llvm/IR/RuntimeLibcalls.td b/llvm/include/llvm/IR/RuntimeLibcalls.td
index 4b3e3b2ae76ea..1af3344023627 100644
--- a/llvm/include/llvm/IR/RuntimeLibcalls.td
+++ b/llvm/include/llvm/IR/RuntimeLibcalls.td
@@ -2962,11 +2962,18 @@ def __mspabi_mpyll : RuntimeLibcallImpl<MUL_I64>;
def isMSP430 : RuntimeLibcallAvailability<(all_of IsMSP430)>;
-// msp430 libgcc provides the 32-bit logical right shift only under
-// the __mspabi_srll name. Everything else in the default list
-// coexists in msp430 libgcc alongside its __mspabi_* variant.
defvar MSP430DefaultOptOut = [
- __lshrsi3
+ __addsf3, __divsf3, __extendsfdf2, __truncdfsf2, __fixsfsi,
+ __fixsfdi, __fixunssfsi, __mulsf3, __eqsf2, __gesf2, __gtsf2,
+ __divhi3, __divsi3, __ashlsi3, __floatsidf, __floatsisf,
+ __ashrsi3, __modhi3, __udivsi3, __fixdfsi, __fixunssfdi,
+ __udivhi3, __umodsi3, __nesf2, __lesf2, __floatundisf,
+ __fixdfdi, __fixunsdfsi, __modsi3, __floatunsisf,
+ __fixunsdfdi, __ltsf2, __floatdisf, __floatdidf,
+ __lshrsi3, __subsf3, __umodhi3, __floatunsidf,
+ __floatundidf, __gtdf2, __eqdf2, __gedf2, __ltdf2, __ledf2,
+ __adddf3, __divdf3, __divdi3, __moddi3,
+ __muldf3, __subdf3, __udivdi3, __umoddi3
];
// EABI Libcalls - EABI Section 6.2
diff --git a/llvm/lib/Target/MSP430/MSP430Subtarget.cpp b/llvm/lib/Target/MSP430/MSP430Subtarget.cpp
index 7e575864f4027..386f2a0fa8f47 100644
--- a/llvm/lib/Target/MSP430/MSP430Subtarget.cpp
+++ b/llvm/lib/Target/MSP430/MSP430Subtarget.cpp
@@ -131,71 +131,4 @@ void MSP430Subtarget::initLibcallLoweringInfo(LibcallLoweringInfo &Info) const {
Info.setLibcallImpl(LC.Op, LC.Impl);
}
}
-
- // The generic soft-float/integer helper routines (__addsf3, __divli, ...)
- // exist in msp430 libgcc alongside the __mspabi_* variants, so both are
- // available. The __mspabi_* variants are the one that should be used.
- static const struct {
- const RTLIB::Libcall Op;
- const RTLIB::LibcallImpl Impl;
- } EABISelected[] = {
- // Floating point conversions - EABI Table 6.
- {RTLIB::FPROUND_F64_F32, RTLIB::impl___mspabi_cvtdf},
- {RTLIB::FPEXT_F32_F64, RTLIB::impl___mspabi_cvtfd},
- {RTLIB::FPTOSINT_F64_I32, RTLIB::impl___mspabi_fixdli},
- {RTLIB::FPTOSINT_F64_I64, RTLIB::impl___mspabi_fixdlli},
- {RTLIB::FPTOUINT_F64_I32, RTLIB::impl___mspabi_fixdul},
- {RTLIB::FPTOUINT_F64_I64, RTLIB::impl___mspabi_fixdull},
- {RTLIB::FPTOSINT_F32_I32, RTLIB::impl___mspabi_fixfli},
- {RTLIB::FPTOSINT_F32_I64, RTLIB::impl___mspabi_fixflli},
- {RTLIB::FPTOUINT_F32_I32, RTLIB::impl___mspabi_fixful},
- {RTLIB::FPTOUINT_F32_I64, RTLIB::impl___mspabi_fixfull},
- {RTLIB::SINTTOFP_I32_F64, RTLIB::impl___mspabi_fltlid},
- {RTLIB::SINTTOFP_I64_F64, RTLIB::impl___mspabi_fltllid},
- {RTLIB::UINTTOFP_I32_F64, RTLIB::impl___mspabi_fltuld},
- {RTLIB::UINTTOFP_I64_F64, RTLIB::impl___mspabi_fltulld},
- {RTLIB::SINTTOFP_I32_F32, RTLIB::impl___mspabi_fltlif},
- {RTLIB::SINTTOFP_I64_F32, RTLIB::impl___mspabi_fltllif},
- {RTLIB::UINTTOFP_I32_F32, RTLIB::impl___mspabi_fltulf},
- {RTLIB::UINTTOFP_I64_F32, RTLIB::impl___mspabi_fltullf},
- // Floating point comparisons - EABI Table 7.
- {RTLIB::OEQ_F64, RTLIB::impl___mspabi_cmpd__oeq},
- {RTLIB::OGE_F64, RTLIB::impl___mspabi_cmpd__oge},
- {RTLIB::OLT_F64, RTLIB::impl___mspabi_cmpd__olt},
- {RTLIB::OLE_F64, RTLIB::impl___mspabi_cmpd__ole},
- {RTLIB::OGT_F64, RTLIB::impl___mspabi_cmpd__ogt},
- {RTLIB::OEQ_F32, RTLIB::impl___mspabi_cmpf__oeq},
- {RTLIB::UNE_F32, RTLIB::impl___mspabi_cmpf__une},
- {RTLIB::OGE_F32, RTLIB::impl___mspabi_cmpf__oge},
- {RTLIB::OLT_F32, RTLIB::impl___mspabi_cmpf__olt},
- {RTLIB::OLE_F32, RTLIB::impl___mspabi_cmpf__ole},
- {RTLIB::OGT_F32, RTLIB::impl___mspabi_cmpf__ogt},
- // Floating point arithmetic - EABI Table 8.
- {RTLIB::ADD_F64, RTLIB::impl___mspabi_addd},
- {RTLIB::SUB_F64, RTLIB::impl___mspabi_subd},
- {RTLIB::MUL_F64, RTLIB::impl___mspabi_mpyd},
- {RTLIB::DIV_F64, RTLIB::impl___mspabi_divd},
- {RTLIB::ADD_F32, RTLIB::impl___mspabi_addf},
- {RTLIB::SUB_F32, RTLIB::impl___mspabi_subf},
- {RTLIB::MUL_F32, RTLIB::impl___mspabi_mpyf},
- {RTLIB::DIV_F32, RTLIB::impl___mspabi_divf},
- // Universal Integer Operations - EABI Table 9.
- {RTLIB::SDIV_I16, RTLIB::impl___mspabi_divi},
- {RTLIB::SDIV_I32, RTLIB::impl___mspabi_divli},
- {RTLIB::SDIV_I64, RTLIB::impl___mspabi_divlli},
- {RTLIB::UDIV_I16, RTLIB::impl___mspabi_divu},
- {RTLIB::UDIV_I32, RTLIB::impl___mspabi_divul},
- {RTLIB::UDIV_I64, RTLIB::impl___mspabi_divull},
- {RTLIB::SREM_I16, RTLIB::impl___mspabi_remi},
- {RTLIB::SREM_I32, RTLIB::impl___mspabi_remli},
- {RTLIB::SREM_I64, RTLIB::impl___mspabi_remlli},
- {RTLIB::UREM_I16, RTLIB::impl___mspabi_remu},
- {RTLIB::UREM_I32, RTLIB::impl___mspabi_remul},
- {RTLIB::UREM_I64, RTLIB::impl___mspabi_remull},
- // Bitwise Operations - EABI Table 10.
- {RTLIB::SHL_I32, RTLIB::impl___mspabi_slll},
- {RTLIB::SRA_I32, RTLIB::impl___mspabi_sral},
- };
- for (const auto &LC : EABISelected)
- Info.setLibcallImpl(LC.Op, LC.Impl);
}
More information about the llvm-commits
mailing list