[compiler-rt] r211032 - compiler-rt: prefer thumb over ARM

Joerg Sonnenberger joerg at britannica.bec.de
Thu Jul 17 02:15:12 PDT 2014


On Thu, Jul 17, 2014 at 12:47:36AM -0700, Stephen Hines wrote:
> This patch actually breaks umodsi3 on devices with CLZ, but without IDIV.
> In umodsi3, there is a computed jump (based on 4 byte ARM instructions),
> which ends up overshooting the end of the function for small inputs (in my
> case a 17 % 2 ended up crashing LLVM compilation on an ARM device). I am
> going to post a revert for this patch (and the related "add it blocks for
> Thumb-2") until someone wants to rewrite umodsi3 in a thumb/thumb2 friendly
> way.

For Thumb mode, you have to adjust the factor, correct. Should be
trivial to do, also applies to the other div functions.

Joerg



More information about the llvm-commits mailing list