Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/net/entropy Drop "optimisation" that breaks the build ...



details:   https://anonhg.NetBSD.org/pkgsrc/rev/84058248a78b
branches:  trunk
changeset: 432415:84058248a78b
user:      joerg <joerg%pkgsrc.org@localhost>
date:      Fri May 22 01:23:41 2020 +0000

description:
Drop "optimisation" that breaks the build with clang, modern GCC and
clang versions are smart enough for this anyway.

diffstat:

 net/entropy/distinfo                   |   3 +-
 net/entropy/patches/patch-src_bignum.c |  35 ++++++++++++++++++++++++++++++++++
 2 files changed, 37 insertions(+), 1 deletions(-)

diffs (53 lines):

diff -r a177b1c2192d -r 84058248a78b net/entropy/distinfo
--- a/net/entropy/distinfo      Fri May 22 01:18:33 2020 +0000
+++ b/net/entropy/distinfo      Fri May 22 01:23:41 2020 +0000
@@ -1,4 +1,4 @@
-$NetBSD: distinfo,v 1.12 2015/11/04 00:34:59 agc Exp $
+$NetBSD: distinfo,v 1.13 2020/05/22 01:23:41 joerg Exp $
 
 SHA1 (entropy_rsa-0.9.1-439.tgz) = 264ffdfe976c154412abd4171fa8525c40414bbc
 RMD160 (entropy_rsa-0.9.1-439.tgz) = 3548ecb8374b512a365dfd388699ada6596d48f3
@@ -8,3 +8,4 @@
 SHA1 (patch-ab) = 6e5ad3221243cb942b265d664e9833596c7f24c3
 SHA1 (patch-ac) = 356895fa6e9309ac1479ca52a1ec3164f6a1613a
 SHA1 (patch-ad) = 1ccc064bab8aa9d5d87a1f2b063a458a22bd36af
+SHA1 (patch-src_bignum.c) = 85f57372c8b7044dee5f6744c5ffe6fc99669c68
diff -r a177b1c2192d -r 84058248a78b net/entropy/patches/patch-src_bignum.c
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/net/entropy/patches/patch-src_bignum.c    Fri May 22 01:23:41 2020 +0000
@@ -0,0 +1,35 @@
+$NetBSD: patch-src_bignum.c,v 1.1 2020/05/22 01:23:42 joerg Exp $
+
+Don't play with assembler, the compiler knows how to do it anyway.
+
+--- src/bignum.c.orig  2020-05-22 00:32:45.737382942 +0000
++++ src/bignum.c
+@@ -703,20 +703,6 @@ limb_t bn_mul_limb(limb_t w[], limb_t u[
+  */
+ limb_t sl_div(limb_t *q, limb_t *r, limb_t u[2], limb_t v)
+ {
+-#if   ASM_X86
+-      limb_t qq;
+-      limb_t rr;
+-
+-      if (0 == v)
+-              /* division by zero */
+-              return LIMBMASK;
+-      asm volatile(
+-              "divl   %4"
+-              : "=a"(qq), "=d"(rr)
+-              : "a"(u[0]), "d"(u[1]), "g"(v));
+-      *q = qq;
+-      *r = rr;
+-#else
+       dlimb_t dd;
+ 
+       if (0 == v)
+@@ -725,7 +711,6 @@ limb_t sl_div(limb_t *q, limb_t *r, limb
+       dd = ((dlimb_t)u[1] << LIMBBITS) | u[0];
+       *q = dd / v;
+       *r = dd % v;
+-#endif
+       return 0;
+ }
+ 



Home | Main Index | Thread Index | Old Index