[llvm-branch-commits] [llvm] ARM: Remove fake entries for divrem libcalls (PR #143832)
via llvm-branch-commits
llvm-branch-commits at lists.llvm.org
Wed Jun 11 21:58:35 PDT 2025
llvmbot wrote:
<!--LLVM PR SUMMARY COMMENT-->
@llvm/pr-subscribers-backend-arm
Author: Matt Arsenault (arsenm)
<details>
<summary>Changes</summary>
This was defining aliases of the i32 divrem functions for the i8
and i16 cases. This is unnecessary and was unused. The divrem
candidate cases wouldn't have formed with illegal types in the
first place, so codegen wouldn't even query these.
---
Full diff: https://github.com/llvm/llvm-project/pull/143832.diff
1 Files Affected:
- (modified) llvm/lib/IR/RuntimeLibcalls.cpp (-10)
``````````diff
diff --git a/llvm/lib/IR/RuntimeLibcalls.cpp b/llvm/lib/IR/RuntimeLibcalls.cpp
index 331b319511aed..d84c56f0af5c6 100644
--- a/llvm/lib/IR/RuntimeLibcalls.cpp
+++ b/llvm/lib/IR/RuntimeLibcalls.cpp
@@ -41,13 +41,8 @@ static void setARMLibcallNames(RuntimeLibcallsInfo &Info, const Triple &TT) {
const char *const Name;
const CallingConv::ID CC;
} LibraryCalls[] = {
- {RTLIB::SDIVREM_I8, "__rt_sdiv", CallingConv::ARM_AAPCS},
- {RTLIB::SDIVREM_I16, "__rt_sdiv", CallingConv::ARM_AAPCS},
{RTLIB::SDIVREM_I32, "__rt_sdiv", CallingConv::ARM_AAPCS},
{RTLIB::SDIVREM_I64, "__rt_sdiv64", CallingConv::ARM_AAPCS},
-
- {RTLIB::UDIVREM_I8, "__rt_udiv", CallingConv::ARM_AAPCS},
- {RTLIB::UDIVREM_I16, "__rt_udiv", CallingConv::ARM_AAPCS},
{RTLIB::UDIVREM_I32, "__rt_udiv", CallingConv::ARM_AAPCS},
{RTLIB::UDIVREM_I64, "__rt_udiv64", CallingConv::ARM_AAPCS},
};
@@ -62,13 +57,8 @@ static void setARMLibcallNames(RuntimeLibcallsInfo &Info, const Triple &TT) {
const char *const Name;
const CallingConv::ID CC;
} LibraryCalls[] = {
- {RTLIB::SDIVREM_I8, "__aeabi_idivmod", CallingConv::ARM_AAPCS},
- {RTLIB::SDIVREM_I16, "__aeabi_idivmod", CallingConv::ARM_AAPCS},
{RTLIB::SDIVREM_I32, "__aeabi_idivmod", CallingConv::ARM_AAPCS},
{RTLIB::SDIVREM_I64, "__aeabi_ldivmod", CallingConv::ARM_AAPCS},
-
- {RTLIB::UDIVREM_I8, "__aeabi_uidivmod", CallingConv::ARM_AAPCS},
- {RTLIB::UDIVREM_I16, "__aeabi_uidivmod", CallingConv::ARM_AAPCS},
{RTLIB::UDIVREM_I32, "__aeabi_uidivmod", CallingConv::ARM_AAPCS},
{RTLIB::UDIVREM_I64, "__aeabi_uldivmod", CallingConv::ARM_AAPCS},
};
``````````
</details>
https://github.com/llvm/llvm-project/pull/143832
More information about the llvm-branch-commits
mailing list