[flint] 01/02: Extend asm_volatile_div to cover i386 and signed division.
Ximin Luo
infinity0 at debian.org
Thu Nov 9 10:39:24 UTC 2017
This is an automated email from the git hooks/post-receive script.
infinity0 pushed a commit to branch master
in repository flint.
commit 728ebb9cd804872c85ad1047138d7ea975e31fe8
Author: Ximin Luo <infinity0 at debian.org>
Date: Thu Nov 9 11:13:54 2017 +0100
Extend asm_volatile_div to cover i386 and signed division.
---
debian/changelog | 8 ++++++++
debian/patches/asm_volatile_div.patch | 32 ++++++++++++++++++++++++++------
2 files changed, 34 insertions(+), 6 deletions(-)
diff --git a/debian/changelog b/debian/changelog
index 486e688..b3e8ed3 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,11 @@
+flint (2.5.2-17) UNRELEASED; urgency=medium
+
+ * Team upload.
+ * Extend asm_volatile_div.patch to i386 as flint-arb tests are failing there
+ as well. Also cover signed division, for good measure. (Closes: #881236)
+
+ -- Ximin Luo <infinity0 at debian.org> Thu, 09 Nov 2017 11:08:08 +0100
+
flint (2.5.2-16) unstable; urgency=medium
* Bump standards-version to 4.1.1.
diff --git a/debian/patches/asm_volatile_div.patch b/debian/patches/asm_volatile_div.patch
index dcdaa8a..d500a0a 100644
--- a/debian/patches/asm_volatile_div.patch
+++ b/debian/patches/asm_volatile_div.patch
@@ -1,22 +1,21 @@
Description: Add __volatile__ to asm(div)
- This fixes the flint-arb issue on x86-64. If that appears on other
+ This fixes the flint-arb issue on amd64 and i386. If that appears on other
architectures, then we need to also patch the asm(div)s for other arches.
.
See the GCC bug for a detailed explanation of this patch.
.
A more complete version of this patch is being discussed with GMP devs,
- which will need to be upstreamed to FLINT when finalised. Their ML is slow
- but hopefully it will appear here soon:
- .
- https://gmplib.org/list-archives/gmp-bugs/2017-October/thread.html
+ which will need to be upstreamed to FLINT when finalised:
Author: Ximin Luo <infinity0 at debian.org>
Bug: https://github.com/fredrik-johansson/arb/issues/194
Bug: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=82677#c9
+Bug: https://gmplib.org/list-archives/gmp-bugs/2017-October/004231.html
+Bug: https://gmplib.org/list-archives/gmp-bugs/2017-November/004235.html
---
This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
--- a/longlong.h
+++ b/longlong.h
-@@ -65,7 +65,7 @@
+@@ -65,12 +65,12 @@
: "%0" ((mp_limb_t)(u)), "rm" ((mp_limb_t)(v)))
#define udiv_qrnnd(q, r, n1, n0, dx) \
@@ -25,3 +24,24 @@ This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
: "=a" (q), "=d" (r) \
: "0" ((mp_limb_t)(n0)), "1" ((mp_limb_t)(n1)), "rm" ((mp_limb_t)(dx)))
+ #define sdiv_qrnnd(q, r, n1, n0, dx) \
+- __asm__ ("idivq %4" \
++ __asm__ __volatile__ ("idivq %4" \
+ : "=a" (q), "=d" (r) \
+ : "0" ((mp_limb_t)(n0)), "1" ((mp_limb_t)(n1)), "rm" ((mp_limb_t)(dx)))
+
+@@ -122,12 +122,12 @@
+ : "%0" ((mp_limb_t)(u)), "rm" ((mp_limb_t)(v)))
+
+ #define udiv_qrnnd(q, r, n1, n0, dx) \
+- __asm__ ("divl %4" \
++ __asm__ __volatile__ ("divl %4" \
+ : "=a" (q), "=d" (r) \
+ : "0" ((mp_limb_t)(n0)), "1" ((mp_limb_t)(n1)), "rm" ((mp_limb_t)(dx)))
+
+ #define sdiv_qrnnd(q, r, n1, n0, dx) \
+- __asm__ ("idivl %4" \
++ __asm__ __volatile__ ("idivl %4" \
+ : "=a" (q), "=d" (r) \
+ : "0" ((mp_limb_t)(n0)), "1" ((mp_limb_t)(n1)), "rm" ((mp_limb_t)(dx)))
+
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-science/packages/flint.git
More information about the debian-science-commits
mailing list