[llvm] ARM: Remove check for isAAPCS_ABI when enabling various aeabi calls (PR #152108)

Renato Golin via llvm-commits llvm-commits at lists.llvm.org
Thu Aug 7 01:48:16 PDT 2025


rengolin wrote:

The folks I remember were using and working in this area were @compnerd @jroelofs @kraj 

> I don't really see any path in here I would call the "GNU side", but this condition doesn't touch any __gnu calls. [The only references to those are below under `else if !TT.isOSBinFormatMachO())`](https://github.com/llvm/llvm-project/blob/0cddf803a3250f8b1589fb73bfcee65e9b8d6559/llvm/lib/Target/ARM/ARMISelLowering.cpp#L747)

There is a confusion between `gnueabi` and `eabi` because both support both calls in a way. This was a side-effect of having two, and no one really knowing which one to call, to GNU emulated EABI and ARMCC emulated GNU.

In most cases, the only difference is the function name, so both compilers had the additional symbols in some fashion. Some calls like `divrem` have different ABIs, so there's a wrapper on either side to move the return value (EABI returns in regs, GNU in the stack).

Technically, asking for `eabi` or `gnueabi` shouldn't make a huge difference when compiling, because both (should) provide the same functionality, but you may get linking errors. And we did. For a long time.

Now that the linking errors stopped (AFAIK, of course), I'm assuming whatever is the state, is "stable", but not correct. It may never be correct. Removing `-mabi` may be a step too far, for people using LLVM on embedded targets. @smithp35 can comment on that, probably.

https://github.com/llvm/llvm-project/pull/152108


More information about the llvm-commits mailing list