[numexpr] 01/02: fix test on powerpc and ppc64el
Antonio Valentino
a_valentino-guest at moszumanska.debian.org
Wed Jun 28 20:22:33 UTC 2017
This is an automated email from the git hooks/post-receive script.
a_valentino-guest pushed a commit to branch patch-queue/master
in repository numexpr.
commit 8af2b89fa40514d1cf213f167816f57d9e615ae6
Author: Antonio Valentino <antonio.valentino at tiscali.it>
Date: Sat Nov 26 16:02:27 2016 +0000
fix test on powerpc and ppc64el
See also upstream bug #224 [1]
[1] https://github.com/pydata/numexpr/issues/224
Gbp-Pq: Name 0001-fix-test-on-powerpc-and-ppc64el.patch
---
numexpr/interp_body.cpp | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/numexpr/interp_body.cpp b/numexpr/interp_body.cpp
index 475a89f..cd5bb45 100644
--- a/numexpr/interp_body.cpp
+++ b/numexpr/interp_body.cpp
@@ -271,7 +271,11 @@
case OP_SUB_LLL: VEC_ARG2(l_dest = l1 - l2);
case OP_MUL_LLL: VEC_ARG2(l_dest = l1 * l2);
case OP_DIV_LLL: VEC_ARG2(l_dest = l2 ? (l1 / l2) : 0);
+#if defined _MSC_VER && _MSC_VER < 1800
case OP_POW_LLL: VEC_ARG2(l_dest = (l2 < 0) ? (1 / l1) : (long long)pow((long double)l1, (long double)l2));
+#else
+ case OP_POW_LLL: VEC_ARG2(l_dest = (l2 < 0) ? (1 / l1) : (long long)llround(pow((long double)l1, (long double)l2)));
+#endif
case OP_MOD_LLL: VEC_ARG2(l_dest = l2 ? (l1 % l2) : 0);
case OP_LSHIFT_LLL: VEC_ARG2(l_dest = l1 << l2);
case OP_RSHIFT_LLL: VEC_ARG2(l_dest = l1 >> l2);
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-science/packages/numexpr.git
More information about the debian-science-commits
mailing list