[PATCH] D30867: [Builtin][ARM] Try to address error on FreeBSD with r288777
Weiming Zhao via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Sat Mar 11 13:20:09 PST 2017
weimingz updated this revision to Diff 91481.
https://reviews.llvm.org/D30867
Files:
lib/builtins/arm/udivsi3.S
Index: lib/builtins/arm/udivsi3.S
===================================================================
--- lib/builtins/arm/udivsi3.S
+++ lib/builtins/arm/udivsi3.S
@@ -183,15 +183,14 @@
#define IMM #
/* due to the range limit of branch in Thumb1, we have to place the
block closer */
+#if __ARM_ARCH_ISA_THUMB == 1
LOCAL_LABEL(divby0):
movs r0, #0
# if defined(__ARM_EABI__)
bl __aeabi_idiv0 // due to relocation limit, can't use b.
# endif
JMP(lr)
-
-#if __ARM_ARCH_ISA_THUMB == 1
#define block(shift) \
lsls r2, r1, IMM shift; \
cmp r0, r2; \
@@ -252,13 +251,13 @@
JMP(lr)
#endif /* __ARM_ARCH_EXT_IDIV__ */
-#if __ARM_ARCH_EXT_IDIV__
+#if __ARM_ARCH_ISA_THUMB != 1
LOCAL_LABEL(divby0):
- mov r0, #0
+ mov r0, #0
# ifdef __ARM_EABI__
- b __aeabi_idiv0
+ b __aeabi_idiv0
# else
- JMP(lr)
+ JMP(lr)
# endif
#endif
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D30867.91481.patch
Type: text/x-patch
Size: 1079 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20170311/4237dea8/attachment.bin>
More information about the llvm-commits
mailing list