[libmath-prime-util-perl] 01/05: Add more limitations on __int128 use

Partha P. Mukherjee ppm-guest at moszumanska.debian.org
Thu May 21 18:49:20 UTC 2015


This is an automated email from the git hooks/post-receive script.

ppm-guest pushed a commit to annotated tag v0.31
in repository libmath-prime-util-perl.

commit b2f802250209b286143dadb496d08752d6ea1b83
Author: Dana Jacobsen <dana at acm.org>
Date:   Tue Aug 6 10:05:41 2013 -0700

    Add more limitations on __int128 use
---
 Changes                       |  3 +--
 examples/parallel_fibprime.pl | 12 ++++++++++++
 mulmod.h                      |  5 +++--
 3 files changed, 16 insertions(+), 4 deletions(-)

diff --git a/Changes b/Changes
index ea29786..5f8cfe5 100644
--- a/Changes
+++ b/Changes
@@ -1,9 +1,8 @@
 Revision history for Perl module Math::Prime::Util
 
-0.30
+0.30  2013-08-06
 
     [API Changes]
-
       - Primality proofs now use the new "MPU Certificate" format, which is
         text rather than a nested Perl data structure.  This is much better
         for external interaction, especially with non-Perl tools.  It is
diff --git a/examples/parallel_fibprime.pl b/examples/parallel_fibprime.pl
index 22a51d6..138d3e5 100755
--- a/examples/parallel_fibprime.pl
+++ b/examples/parallel_fibprime.pl
@@ -28,6 +28,18 @@ $| = 1;
 #    31   37511            432.10713
 #    32   50833           1151.85562
 #
+# Using 60 cores of a Power 7 machine (each one slower than the x86 above)
+#    27   14431             14.23748
+#    28   25561             81.95451
+#    29   30757            117.95914
+#    30   35999            224.14832
+#    31   37511            267.01445
+#    32   50833            677.61661
+#    33   81839           3230.63871
+#    34  104911           7861.65752
+#    35  130021          16170.56098
+#    36  148091          24841.65174
+#
 # Though not as pretty as the Haskell solution on haskell.org, it is a
 # different way of solving the problem that is faster and more scalable.
 
diff --git a/mulmod.h b/mulmod.h
index 3e072a6..061ebba 100644
--- a/mulmod.h
+++ b/mulmod.h
@@ -63,9 +63,10 @@
   }
   #define addmod(a,b,n) _addmod(a,b,n)
 
-#elif BITS_PER_WORD == 64 && __GNUC__ == 4 && __GNUC_MINOR__ >= 4 && (defined(__LP64__) || defined(__x86_64__) || defined(__powerpc64__) || defined(_M_X64) || defined(_M_IX86))
+#elif BITS_PER_WORD == 64 && __GNUC__ == 4 && __GNUC_MINOR__ >= 4 && (defined(__x86_64__) || defined(__powerpc64__))
 
-  /* We're 64-bit, using a modern gcc, and the target has some 128-bit type */
+  /* We're 64-bit, using a modern gcc, and the target has some 128-bit type.
+   * The actual number of targets that have this implemented are limited. */
 
   #if __GNUC__ == 4 && __GNUC_MINOR__ >= 4 && __GNUC_MINOR__ < 6
     typedef unsigned int uint128_t __attribute__ ((__mode__ (TI)));

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-perl/packages/libmath-prime-util-perl.git



More information about the Pkg-perl-cvs-commits mailing list