Commit 1d400f7a authored by Rafaël Carré's avatar Rafaël Carré

contrib: gmp: fix thumb2 build

parent e4b10641
......@@ -10,6 +10,7 @@ $(TARBALLS)/gmp-$(GMP_VERSION).tar.bz2:
gmp: gmp-$(GMP_VERSION).tar.bz2 .sum-gmp
$(UNPACK)
$(APPLY) $(SRC)/gmp/thumb.patch
$(MOVE)
.gmp: gmp
......
--- gmp/mpn/generic/div_qr_1n_pi1.c.orig 2014-03-28 16:11:23.648263232 +0100
+++ gmp/mpn/generic/div_qr_1n_pi1.c 2014-03-28 16:22:29.376932722 +0100
@@ -131,10 +131,19 @@
#endif
#if defined (__arm__) && W_TYPE_SIZE == 32
+#ifdef __thumb2__
+#define itcc "it cc\n\t"
+#define itcs "it cs\n\t"
+#else
+#define itcc
+#define itcs
+#endif
#define add_mssaaaa(m, sh, sl, ah, al, bh, bl) \
__asm__ ( "adds %2, %5, %6\n\t" \
"adcs %1, %3, %4\n\t" \
+ itcc \
"movcc %0, #0\n\t" \
+ itcs \
"movcs %0, #-1" \
: "=r" (m), "=r" (sh), "=&r" (sl) \
: "r" (ah), "rI" (bh), "%r" (al), "rI" (bl) __CLOBBER_CC)
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment