[LLVMdev] [cfe-dev] ARM EABI and modulo

Renato Golin renato.golin at linaro.org
Mon Dec 9 05:58:29 PST 2013


On 9 December 2013 11:51, Joerg Sonnenberger <joerg at britannica.bec.de> wrote:
> Part of the concern is that the same code using / does call __aeabi_idiv
> and __aeabi_uidiv.

Hi Joerg,

I can see the error, and it's just a bad selection of choices. I was
wrong in assuming that the "eabi" at the end would always force it:

$ clang -target arm-elf-eabi -S mod.c -o - | grep mod
.file "mod.c"
bl __modsi3
bl __umodsi3

$ clang -target arm-none-eabi -S mod.c -o - | grep mod
.file "mod.c"
bl __aeabi_idivmod
bl __aeabi_uidivmod

This is clearly a bug and should be fixed. Please file a bug in
bugzilla and I'll have a look at it.

cheers,
--renato



More information about the llvm-dev mailing list