texlive[41496] Build/source/libs: gmp 6.1.1

commits+kakuto at tug.org commits+kakuto at tug.org
Sun Jun 19 11:24:37 CEST 2016


Revision: 41496
          http://tug.org/svn/texlive?view=revision&revision=41496
Author:   kakuto
Date:     2016-06-19 11:24:37 +0200 (Sun, 19 Jun 2016)
Log Message:
-----------
gmp 6.1.1

Modified Paths:
--------------
    trunk/Build/source/libs/README
    trunk/Build/source/libs/gmp/ChangeLog
    trunk/Build/source/libs/gmp/configure
    trunk/Build/source/libs/gmp/gmp-PATCHES/ChangeLog
    trunk/Build/source/libs/gmp/gmp-PATCHES/TL-Changes
    trunk/Build/source/libs/gmp/gmp-src/ChangeLog
    trunk/Build/source/libs/gmp/gmp-src/Makefile.am
    trunk/Build/source/libs/gmp/gmp-src/NEWS
    trunk/Build/source/libs/gmp/gmp-src/acinclude.m4
    trunk/Build/source/libs/gmp/gmp-src/config.in
    trunk/Build/source/libs/gmp/gmp-src/configgmp.guess
    trunk/Build/source/libs/gmp/gmp-src/configgmp.sub
    trunk/Build/source/libs/gmp/gmp-src/configure.ac
    trunk/Build/source/libs/gmp/gmp-src/gmp-h.in
    trunk/Build/source/libs/gmp/gmp-src/gmp-impl.h
    trunk/Build/source/libs/gmp/gmp-src/mpn/arm/aorslsh1_n.asm
    trunk/Build/source/libs/gmp/gmp-src/mpn/arm/arm-defs.m4
    trunk/Build/source/libs/gmp/gmp-src/mpn/arm/bdiv_dbm1c.asm
    trunk/Build/source/libs/gmp/gmp-src/mpn/arm/cnd_aors_n.asm
    trunk/Build/source/libs/gmp/gmp-src/mpn/arm/com.asm
    trunk/Build/source/libs/gmp/gmp-src/mpn/arm/copyd.asm
    trunk/Build/source/libs/gmp/gmp-src/mpn/arm/copyi.asm
    trunk/Build/source/libs/gmp/gmp-src/mpn/arm/dive_1.asm
    trunk/Build/source/libs/gmp/gmp-src/mpn/arm/invert_limb.asm
    trunk/Build/source/libs/gmp/gmp-src/mpn/arm/logops_n.asm
    trunk/Build/source/libs/gmp/gmp-src/mpn/arm/lshift.asm
    trunk/Build/source/libs/gmp/gmp-src/mpn/arm/lshiftc.asm
    trunk/Build/source/libs/gmp/gmp-src/mpn/arm/mod_34lsub1.asm
    trunk/Build/source/libs/gmp/gmp-src/mpn/arm/mode1o.asm
    trunk/Build/source/libs/gmp/gmp-src/mpn/arm/rsh1aors_n.asm
    trunk/Build/source/libs/gmp/gmp-src/mpn/arm/rshift.asm
    trunk/Build/source/libs/gmp/gmp-src/mpn/arm/sec_tabselect.asm
    trunk/Build/source/libs/gmp/gmp-src/mpn/arm/udiv.asm
    trunk/Build/source/libs/gmp/gmp-src/mpn/generic/trialdiv.c
    trunk/Build/source/libs/gmp/gmp-src/mpn/x86_64/coreibwl/mul_basecase.asm
    trunk/Build/source/libs/gmp/gmp-src/mpn/x86_64/fat/fat.c
    trunk/Build/source/libs/gmp/gmp-src/printf/doprnt.c
    trunk/Build/source/libs/gmp/native/configure
    trunk/Build/source/libs/gmp/version.ac

Modified: trunk/Build/source/libs/README
===================================================================
--- trunk/Build/source/libs/README	2016-06-19 06:28:20 UTC (rev 41495)
+++ trunk/Build/source/libs/README	2016-06-19 09:24:37 UTC (rev 41496)
@@ -18,7 +18,7 @@
 gd 2.1.1 - checked 14jan15
   https://bitbucket.org/libgd/gd-libgd/downloads/
 
-gmp 6.1.0 - checked 28dec15
+gmp 6.1.1 - checked 19jun16
   http://ftp.gnu.org/gnu/gmp/
 
 graphite2 1.3.8 - checked 31mar16

Modified: trunk/Build/source/libs/gmp/ChangeLog
===================================================================
--- trunk/Build/source/libs/gmp/ChangeLog	2016-06-19 06:28:20 UTC (rev 41495)
+++ trunk/Build/source/libs/gmp/ChangeLog	2016-06-19 09:24:37 UTC (rev 41496)
@@ -1,3 +1,7 @@
+2016-06-19  Akira Kakuto  <kakuto at fuk.kindai.ac.jp>
+
+	Import gmp-6.1.1.
+
 2016-02-15  Karl Berry  <karl at tug.org>
 
 	* gmp-PATCHES: rename from gmp-src-PATCHES.

Modified: trunk/Build/source/libs/gmp/configure
===================================================================
--- trunk/Build/source/libs/gmp/configure	2016-06-19 06:28:20 UTC (rev 41495)
+++ trunk/Build/source/libs/gmp/configure	2016-06-19 09:24:37 UTC (rev 41496)
@@ -1,6 +1,6 @@
 #! /bin/sh
 # Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.69 for gmp (TeX Live) 6.1.0.
+# Generated by GNU Autoconf 2.69 for gmp (TeX Live) 6.1.1.
 #
 # Report bugs to <tex-k at tug.org>.
 #
@@ -580,8 +580,8 @@
 # Identity of this package.
 PACKAGE_NAME='gmp (TeX Live)'
 PACKAGE_TARNAME='gmp--tex-live-'
-PACKAGE_VERSION='6.1.0'
-PACKAGE_STRING='gmp (TeX Live) 6.1.0'
+PACKAGE_VERSION='6.1.1'
+PACKAGE_STRING='gmp (TeX Live) 6.1.1'
 PACKAGE_BUGREPORT='tex-k at tug.org'
 PACKAGE_URL=''
 
@@ -1294,7 +1294,7 @@
   # Omit some internal or obsolete options to make the list less imposing.
   # This message is too long to be a string in the A/UX 3.1 sh.
   cat <<_ACEOF
-\`configure' configures gmp (TeX Live) 6.1.0 to adapt to many kinds of systems.
+\`configure' configures gmp (TeX Live) 6.1.1 to adapt to many kinds of systems.
 
 Usage: $0 [OPTION]... [VAR=VALUE]...
 
@@ -1364,7 +1364,7 @@
 
 if test -n "$ac_init_help"; then
   case $ac_init_help in
-     short | recursive ) echo "Configuration of gmp (TeX Live) 6.1.0:";;
+     short | recursive ) echo "Configuration of gmp (TeX Live) 6.1.1:";;
    esac
   cat <<\_ACEOF
 
@@ -1461,7 +1461,7 @@
 test -n "$ac_init_help" && exit $ac_status
 if $ac_init_version; then
   cat <<\_ACEOF
-gmp (TeX Live) configure 6.1.0
+gmp (TeX Live) configure 6.1.1
 generated by GNU Autoconf 2.69
 
 Copyright (C) 2012 Free Software Foundation, Inc.
@@ -1976,7 +1976,7 @@
 This file contains any messages produced by compilers while
 running configure, to aid debugging if configure makes a mistake.
 
-It was created by gmp (TeX Live) $as_me 6.1.0, which was
+It was created by gmp (TeX Live) $as_me 6.1.1, which was
 generated by GNU Autoconf 2.69.  Invocation command line was
 
   $ $0 $@
@@ -3899,7 +3899,7 @@
 
 # Define the identity of the package.
  PACKAGE='gmp--tex-live-'
- VERSION='6.1.0'
+ VERSION='6.1.1'
 
 
 cat >>confdefs.h <<_ACEOF
@@ -6148,7 +6148,7 @@
   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
 /* end confdefs.h.  */
 #include "gmp-tmp.h"
-#include "$srcdir/gmp-6.1.0/gmp-impl.h"
+#include "$srcdir/gmp-6.1.1/gmp-impl.h"
 int
 main ()
 {
@@ -7002,7 +7002,7 @@
 # report actual input values of CONFIG_FILES etc. instead of their
 # values after options handling.
 ac_log="
-This file was extended by gmp (TeX Live) $as_me 6.1.0, which was
+This file was extended by gmp (TeX Live) $as_me 6.1.1, which was
 generated by GNU Autoconf 2.69.  Invocation command line was
 
   CONFIG_FILES    = $CONFIG_FILES
@@ -7068,7 +7068,7 @@
 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
 ac_cs_version="\\
-gmp (TeX Live) config.status 6.1.0
+gmp (TeX Live) config.status 6.1.1
 configured by $0, generated by GNU Autoconf 2.69,
   with options \\"\$ac_cs_config\\"
 

Modified: trunk/Build/source/libs/gmp/gmp-PATCHES/ChangeLog
===================================================================
--- trunk/Build/source/libs/gmp/gmp-PATCHES/ChangeLog	2016-06-19 06:28:20 UTC (rev 41495)
+++ trunk/Build/source/libs/gmp/gmp-PATCHES/ChangeLog	2016-06-19 09:24:37 UTC (rev 41496)
@@ -1,3 +1,7 @@
+2016-06-19  Akira Kakuto  <kakuto at fuk.kindai.ac.jp>
+
+	* Import 6.1.1.
+
 2015-12-28  Akira Kakuto  <kakuto at fuk.kindai.ac.jp>
 
 	* patch-01-const: Removed, since it is applied in 6.1.0.

Modified: trunk/Build/source/libs/gmp/gmp-PATCHES/TL-Changes
===================================================================
--- trunk/Build/source/libs/gmp/gmp-PATCHES/TL-Changes	2016-06-19 06:28:20 UTC (rev 41495)
+++ trunk/Build/source/libs/gmp/gmp-PATCHES/TL-Changes	2016-06-19 09:24:37 UTC (rev 41496)
@@ -1,4 +1,4 @@
-Changes applied to the gmp-6.1.0/ tree as obtained from:
+Changes applied to the gmp-6.1.1/ tree as obtained from:
 	http://ftp.gnu.org/gnu/gmp/
 
 Removed:

Modified: trunk/Build/source/libs/gmp/gmp-src/ChangeLog
===================================================================
--- trunk/Build/source/libs/gmp/gmp-src/ChangeLog	2016-06-19 06:28:20 UTC (rev 41495)
+++ trunk/Build/source/libs/gmp/gmp-src/ChangeLog	2016-06-19 09:24:37 UTC (rev 41496)
@@ -1,3 +1,80 @@
+2016-06-18  Torbjörn Granlund  <tg at gmplib.org>
+
+	* Version 6.1.1 released.
+
+2015-03-20  Marc Glisse  <marc.glisse at inria.fr>
+
+	* configure.ac (WANT_ASSEMBLY): Remove.
+	(NO_ASM): Remove from CFLAGS, add to AC_DEFINE.
+	* tests/misc.c: Test NO_ASM instead of WANT_ASSEMBLY.
+
+2016-02-25  Pavel Kopyl  <p.kopyl at samsung.com>
+
+	* acinclude.m4 (GMP_ASM_UNDERSCORE): Tighten gurkmacka detection.
+
+2016-01-04 Marco Bodrato <bodrato at mail.dm.unipi.it>
+
+	* Makefile.am (LIBGMP_LT_*, LIBGMPXX_LT_*): Bump version info.
+	* gmp-h.in: Bump version.
+
+2016-01-01 Marco Bodrato <bodrato at mail.dm.unipi.it>
+
+	* tests/cxx/clocale.c: Do not re-define localeconv for mingw.
+	* tests/misc/t-locale.c: Likewise (Thanks Alexander).
+
+2015-12-26  Torbjörn Granlund  <torbjorng at google.com>
+
+	* tests/misc.c (tests_start): Assert library version.
+
+2015-12-19  Marc Glisse  <marc.glisse at inria.fr>
+
+	* gmp-impl.h (fft_table_nk): Use gmp_uint_least32_t.
+	* mpn/generic/trialdiv.c (gmp_primes_ptab): Likewise.
+
+2015-12-14  Torbjörn Granlund  <torbjorng at google.com>
+
+	* mpn/x86_64/fat/fat.c (gmp_workaround_skylake_cpuid_bug):
+	New function.
+	(__gmpn_cpuvec_init): Handle more BMI2 crippled CPUs.
+
+2015-12-13 Marco Bodrato <bodrato at mail.dm.unipi.it>
+
+	* tests/arm32call.asm: bx->ret to support thumb-less chips 
+	  (thanks Martin Husemann).
+
+2015-12-13  Torbjörn Granlund  <torbjorng at google.com>
+
+	* config.sub: Fix spelling of kabylake.
+	* acinclude.m4: Likewise.
+	* mpn/x86_64/fat/fat.c: Likewise.
+
+2015-12-10 Marco Bodrato <bodrato at mail.dm.unipi.it>
+
+	* tests/misc/t-printf.c: Test a sequence of '%'.
+	* printf/doprnt.c: Avoid buffer overread with long long limbs.
+
+2015-12-06  Torbjörn Granlund  <torbjorng at google.com>
+
+	* configure.ac (arm*): Conditionally define NOTHUMB.
+	Simplify and generalise.
+	* mpn/arm/arm-defs.m4 (ret): New macro, conditional on NOTHUMB.
+	* mpn/arm/*.asm: Use ret.
+
+2015-12-03  Torbjörn Granlund  <torbjorng at google.com>
+
+	* config.guess: Work around skylake cpuid bug.
+	Fix spelling of kabylake.
+
+2015-12-01  Torbjörn Granlund  <torbjorng at google.com>
+
+	* mpn/x86_64/coreibwl/mul_basecase.asm: Add FUNC_EXITs.
+
+2015-11-21 Marco Bodrato <bodrato at mail.dm.unipi.it>
+
+	* gmp-impl.h (MPN_TOOM22_MUL_MINSIZE): Consider ToomX2 limits
+	  (thanks Paul).
+	* tests/mpn/t-toom22.c: Keep on testing small sizes.
+
 2015-11-01 Marco Bodrato <bodrato at mail.dm.unipi.it>
 
 	* Version 6.1.0 released.
@@ -673,7 +750,7 @@
 
 	* tune/tune-gcd-p.c: Add casts for C++ compatibility.
 
-	* tune/tuneup.c:  Add casts for C++ compatibility.
+	* tune/tuneup.c: Add casts for C++ compatibility.
 	(mpn_divrem_1_tune, mpn_mod_1_tune): Mark as extern "C".
 	(INSERT_FFTTAB): Produce sentinels differently to silence compiler.
 
@@ -701,12 +778,12 @@
 
 	* mpn/powerpc32/addmul_1.asm: Avoid negative stack pointer references.
 	* mpn/powerpc32/lshift.asm: Likewise.
-	* mpn/powerpc32/lshiftc.asm:  Likewise.
-	* mpn/powerpc32/p3-p7/aors_n.asm:  Likewise.
-	* mpn/powerpc32/rshift.asm:  Likewise.
-	* mpn/powerpc32/sec_tabselect.asm:  Likewise.
-	* mpn/powerpc32/submul_1.asm:  Likewise.
-	* mpn/powerpc32/vmx/mod_34lsub1.asm:  Likewise.
+	* mpn/powerpc32/lshiftc.asm: Likewise.
+	* mpn/powerpc32/p3-p7/aors_n.asm: Likewise.
+	* mpn/powerpc32/rshift.asm: Likewise.
+	* mpn/powerpc32/sec_tabselect.asm: Likewise.
+	* mpn/powerpc32/submul_1.asm: Likewise.
+	* mpn/powerpc32/vmx/mod_34lsub1.asm: Likewise.
 
 2014-10-13  Torbjörn Granlund  <torbjorng at google.com>
 
@@ -2033,8 +2110,8 @@
 
 	* mpn/powerpc64/mode64/divrem_1.asm: Remove explicit nop after CALL.
 	* mpn/powerpc64/mode64/divrem_2.asm: Likewise.
-	* mpn/powerpc64/mode64/mod_1_1.asm:  Likewise.
-	* mpn/powerpc64/mode64/mod_1_4.asm:  Likewise.
+	* mpn/powerpc64/mode64/mod_1_1.asm: Likewise.
+	* mpn/powerpc64/mode64/mod_1_4.asm: Likewise.
 
 2013-07-13  Torbjorn Granlund  <tege at gmplib.org>
 
@@ -2429,7 +2506,7 @@
 	* mpn/arm/dive_1.asm: New file.
 	* mpn/arm/v6/dive_1.asm: New file.
 
-	* mpn/arm/v6t2/mode1o.asm:  Make trivial change to avoid v6t2...
+	* mpn/arm/v6t2/mode1o.asm: Make trivial change to avoid v6t2...
 	* mpn/arm/v6/mode1o.asm: ...instruction, move file accordingly.
 
 	* mpn/powerpc64/mode64/invert_limb.asm: Put all multiplies low-limb first.
@@ -4777,7 +4854,7 @@
 	Reintroduce previously removed RP argument.
 	* mpn/x86_64/redc_1.asm: Likewise.
 
-	* mpn/generic/redc_2.c:  Remove mpn_sub_n call, return carry from
+	* mpn/generic/redc_2.c: Remove mpn_sub_n call, return carry from
 	mpn_add_n call.
 
 	* gmp-impl.h (mpn_redc_1, mpn_redc_2): Now return an mp_limb_t.

Modified: trunk/Build/source/libs/gmp/gmp-src/Makefile.am
===================================================================
--- trunk/Build/source/libs/gmp/gmp-src/Makefile.am	2016-06-19 06:28:20 UTC (rev 41495)
+++ trunk/Build/source/libs/gmp/gmp-src/Makefile.am	2016-06-19 09:24:37 UTC (rev 41496)
@@ -1,7 +1,7 @@
 ## Process this file with automake to generate Makefile.in
 
 
-# Copyright 1991, 1993, 1994, 1996, 1997, 1999-2004, 2006-2009, 2011-2015 Free
+# Copyright 1991, 1993, 1994, 1996, 1997, 1999-2004, 2006-2009, 2011-2016 Free
 # Software Foundation, Inc.
 #
 #  This file is part of the GNU MP Library.
@@ -87,6 +87,7 @@
 #        5.1.2   11:2:1    7:2:3     -
 #        6.0.0   12:0:2    8:0:4     -
 #        6.1.0   13:0:3    9:0:5     -
+#        6.1.1   13:1:3    9:1:5     -
 #
 # Starting at 3:0:0 is a slight abuse of the versioning system, but it
 # ensures we're past soname libgmp.so.2, which was used on Debian GNU/Linux
@@ -100,11 +101,11 @@
 # libgmpxx.so.3.0.4) incrementing, to make it clear which GMP it's from.
 
 LIBGMP_LT_CURRENT    = 13
-LIBGMP_LT_REVISION   = 0
+LIBGMP_LT_REVISION   = 1
 LIBGMP_LT_AGE        = 3
 
 LIBGMPXX_LT_CURRENT  = 9
-LIBGMPXX_LT_REVISION = 0
+LIBGMPXX_LT_REVISION = 1
 LIBGMPXX_LT_AGE      = 5
 
 

Modified: trunk/Build/source/libs/gmp/gmp-src/NEWS
===================================================================
--- trunk/Build/source/libs/gmp/gmp-src/NEWS	2016-06-19 06:28:20 UTC (rev 41495)
+++ trunk/Build/source/libs/gmp/gmp-src/NEWS	2016-06-19 09:24:37 UTC (rev 41496)
@@ -1,9 +1,20 @@
-Copyright 1996, 1999-2015 Free Software Foundation, Inc.
+Copyright 1996, 1999-2016 Free Software Foundation, Inc.
 
 Verbatim copying and distribution of this entire article is permitted in any
 medium, provided this notice is preserved.
 
 
+Changes between GMP version 6.1.0 and 6.1.1
+
+  BUGS FIXED
+  * Make Intel Broadwell configurations work on Windows.
+
+  FEATURES
+  * Work around faulty cpuid on some recent Intel chips (this allows GMP to run
+    on Skylake Pentiums).
+
+  * Support thumb-less ARM chips.
+
 Changes between GMP version 6.0.* and 6.1.0
 
   BUGS FIXED

Modified: trunk/Build/source/libs/gmp/gmp-src/acinclude.m4
===================================================================
--- trunk/Build/source/libs/gmp/gmp-src/acinclude.m4	2016-06-19 06:28:20 UTC (rev 41495)
+++ trunk/Build/source/libs/gmp/gmp-src/acinclude.m4	2016-06-19 09:24:37 UTC (rev 41496)
@@ -63,7 +63,7 @@
 [[i?86*-*-* | k[5-8]*-*-* | pentium*-*-* | athlon-*-* | viac3*-*-* | geode*-*-* | atom-*-*]])
 
 define(X86_64_PATTERN,
-[[athlon64-*-* | k8-*-* | k10-*-* | bobcat-*-* | jaguar*-*-* | bulldozer*-*-* | piledriver*-*-* | steamroller*-*-* | excavator*-*-* | pentium4-*-* | atom-*-* | silvermont-*-* | goldmont-*-* | core2-*-* | corei*-*-* | x86_64-*-* | nano-*-* | nehalem*-*-* | westmere*-*-* | sandybridge*-*-* | ivybridge*-*-* | haswell*-*-* | broadwell*-*-* | skylake*-*-* | cabylake*-*-*]])
+[[athlon64-*-* | k8-*-* | k10-*-* | bobcat-*-* | jaguar*-*-* | bulldozer*-*-* | piledriver*-*-* | steamroller*-*-* | excavator*-*-* | pentium4-*-* | atom-*-* | silvermont-*-* | goldmont-*-* | core2-*-* | corei*-*-* | x86_64-*-* | nano-*-* | nehalem*-*-* | westmere*-*-* | sandybridge*-*-* | ivybridge*-*-* | haswell*-*-* | broadwell*-*-* | skylake*-*-* | kabylake*-*-*]])
 
 dnl  GMP_FAT_SUFFIX(DSTVAR, DIRECTORY)
 dnl  ---------------------------------
@@ -1754,9 +1754,9 @@
 gmp_compile="$CC $CFLAGS $CPPFLAGS -c conftest.c >&AC_FD_CC"
 if AC_TRY_EVAL(gmp_compile); then
   $NM conftest.$OBJEXT >conftest.out
-  if grep _gurkmacka conftest.out >/dev/null; then
+  if grep "[[ 	]]_gurkmacka" conftest.out >/dev/null; then
     gmp_cv_asm_underscore=yes
-  elif grep gurkmacka conftest.out >/dev/null; then
+  elif grep "[[ 	]]gurkmacka" conftest.out >/dev/null; then
     gmp_cv_asm_underscore=no
   else
     echo "configure: $NM doesn't have gurkmacka:" >&AC_FD_CC

Modified: trunk/Build/source/libs/gmp/gmp-src/config.in
===================================================================
--- trunk/Build/source/libs/gmp/gmp-src/config.in	2016-06-19 06:28:20 UTC (rev 41495)
+++ trunk/Build/source/libs/gmp/gmp-src/config.in	2016-06-19 09:24:37 UTC (rev 41496)
@@ -511,6 +511,9 @@
 /* Define to the sub-directory where libtool stores uninstalled libraries. */
 #undef LT_OBJDIR
 
+/* Define to 1 to disable the use of inline assembly */
+#undef NO_ASM
+
 /* Name of package */
 #undef PACKAGE
 
@@ -565,9 +568,6 @@
 /* Version number of package */
 #undef VERSION
 
-/* Defined to 1 as per --enable-assembly */
-#undef WANT_ASSEMBLY
-
 /* Define to 1 to enable ASSERT checking, per --enable-assert */
 #undef WANT_ASSERT
 

Modified: trunk/Build/source/libs/gmp/gmp-src/configgmp.guess
===================================================================
--- trunk/Build/source/libs/gmp/gmp-src/configgmp.guess	2016-06-19 06:28:20 UTC (rev 41495)
+++ trunk/Build/source/libs/gmp/gmp-src/configgmp.guess	2016-06-19 09:24:37 UTC (rev 41496)
@@ -762,7 +762,49 @@
 extern "C"
 #endif
 unsigned int cpuid (int, char *, char *, int);
+
 int
+gmp_workaround_skylake_cpuid_bug ()
+{
+  char feature_string[49];
+  char processor_name_string[49];
+  static const char *bad_cpus[] = {" G44", " G45", " G39" /* , "6600" */ };
+  int i;
+
+  /* Example strings:                                   */
+  /* "Intel(R) Pentium(R) CPU G4400 @ 3.30GHz"          */
+  /* "Intel(R) Core(TM) i5-6600K CPU @ 3.50GHz"         */
+  /*                  ^               ^               ^ */
+  /*     0x80000002       0x80000003      0x80000004    */
+  /* We match out just the 0x80000003 part here. */
+
+  /* In their infinitive wisdom, Intel decided to use one register order for
+     the vendor string, and another for the processor name string.  We shuffle
+     things about here, rather than write a new variant of our assembly cpuid.
+  */
+
+  unsigned int eax, ebx, ecx, edx;
+  eax = CPUID (feature_string, 0x80000003);
+  ebx = ((unsigned int *)feature_string)[0];
+  edx = ((unsigned int *)feature_string)[1];
+  ecx = ((unsigned int *)feature_string)[2];
+
+  ((unsigned int *) (processor_name_string))[0] = eax;
+  ((unsigned int *) (processor_name_string))[1] = ebx;
+  ((unsigned int *) (processor_name_string))[2] = ecx;
+  ((unsigned int *) (processor_name_string))[3] = edx;
+
+  processor_name_string[16] = 0;
+
+  for (i = 0; i < sizeof (bad_cpus) / sizeof (char *); i++)
+    {
+      if (strstr (processor_name_string, bad_cpus[i]) != 0)
+	return 1;
+    }
+  return 0;
+}
+
+int
 main ()
 {
   char vendor_string[13];
@@ -839,16 +881,19 @@
           else if (model == 0x5c) cpu_64bit = 1,            modelstr = "goldmont";   /* Goldmont */
           else if (model == 0x5e) cpu_64bit = 1, cpu_avx=1, modelstr = "skylake";    /* Skylake */
           else if (model == 0x5f) cpu_64bit = 1,            modelstr = "goldmont";   /* Goldmont */
-          else if (model == 0x8e) cpu_64bit = 1, cpu_avx=1, modelstr = "cabylake";   /* Capylake Y/U */
-          else if (model == 0x9e) cpu_64bit = 1, cpu_avx=1, modelstr = "cabylake";   /* Capylake desktop */
+          else if (model == 0x8e) cpu_64bit = 1, cpu_avx=1, modelstr = "kabylake";   /* Kabylake Y/U */
+          else if (model == 0x9e) cpu_64bit = 1, cpu_avx=1, modelstr = "kabylake";   /* Kabylake desktop */
           else                    cpu_64bit = 1,            modelstr = "nehalem";    /* default */
 
-	  if (strcmp (modelstr, "haswell") == 0)
+	  if (strcmp (modelstr, "haswell") == 0 ||
+	      strcmp (modelstr, "broadwell") == 0 ||
+	      strcmp (modelstr, "skylake") == 0)
 	    {
-	      /* Some Haswells lack BMI2.  Let them appear as Sandybridges for
-		 now.  */
+	      /* Some haswell, broadwell, skylake lack BMI2.  Let them appear
+		 as sandybridge for now.  */
 	      CPUID (feature_string, 7);
-	      if ((feature_string[0 + 8 / 8] & (1 << (8 % 8))) == 0)
+	      if ((feature_string[0 + 8 / 8] & (1 << (8 % 8))) == 0
+		  || gmp_workaround_skylake_cpuid_bug ())
 		modelstr = "sandybridge";
 	    }
 

Modified: trunk/Build/source/libs/gmp/gmp-src/configgmp.sub
===================================================================
--- trunk/Build/source/libs/gmp/gmp-src/configgmp.sub	2016-06-19 06:28:20 UTC (rev 41495)
+++ trunk/Build/source/libs/gmp/gmp-src/configgmp.sub	2016-06-19 09:24:37 UTC (rev 41496)
@@ -102,7 +102,7 @@
   test_cpu=ia64 ;;
 pentium | pentiummmx | pentiumpro | pentium[234m] | k[567] | k6[23] | geode | athlon | viac3*)
   test_cpu=i386 ;;
-athlon64 | atom | silvermont | goldmont | core2 | corei* | opteron | k[89] | k10 | bobcat | jaguar* | bulldozer* | piledriver* | steamroller* | excavator* | nano | nehalem* | westmere* | sandybridge* | ivybridge* | haswell* | broadwell* | skylake* | cabylake* | knightslanding)
+athlon64 | atom | silvermont | goldmont | core2 | corei* | opteron | k[89] | k10 | bobcat | jaguar* | bulldozer* | piledriver* | steamroller* | excavator* | nano | nehalem* | westmere* | sandybridge* | ivybridge* | haswell* | broadwell* | skylake* | kabylake* | knightslanding)
   test_cpu=x86_64 ;;
 power[2-9] | power2sc)
   test_cpu=power ;;

Modified: trunk/Build/source/libs/gmp/gmp-src/configure.ac
===================================================================
--- trunk/Build/source/libs/gmp/gmp-src/configure.ac	2016-06-19 06:28:20 UTC (rev 41495)
+++ trunk/Build/source/libs/gmp/gmp-src/configure.ac	2016-06-19 09:24:37 UTC (rev 41496)
@@ -142,12 +142,7 @@
 esac],
 [enable_assembly=yes])
 
-if test "$enable_assembly" = "yes"; then
-  AC_DEFINE(WANT_ASSEMBLY,1,
-  [Defined to 1 as per --enable-assembly])
-fi
 
-
 AC_ARG_ENABLE(fft,
 AC_HELP_STRING([--enable-fft],[enable FFTs for multiplication [default=yes]]),
 [case $enableval in
@@ -625,36 +620,24 @@
     # either enforce them, or organise to strip paths as the corresponding
     # options fail.
     case $host_cpu in
-      armv7*)
-	path="arm/v6t2 arm/v6 arm/v5 arm"
-	gcc_cflags_arch="-march=armv7-a"
-	;;
-      armv6t2*)
-	path="arm/v6t2 arm/v6 arm/v5 arm"
-	gcc_cflags_arch="-march=armv6t2"
-	;;
-      armv6*)
-	path="arm/v6 arm/v5 arm"
-	gcc_cflags_arch="-march=armv6"
-	;;
-      armsa1 | arm9tdmi | armv4*)
+      armsa1 | arm7t* | arm9t* | armv4t*)
 	path="arm"
 	gcc_cflags_arch="-march=armv4"
 	;;
-      armxscale | arm9te | arm10 | armv5*)
+      armxscale | arm7ej | arm9te | arm9e* | arm10* | armv5*)
 	path="arm/v5 arm"
 	gcc_cflags_arch="-march=armv5"
 	;;
-      arm11mpcore | arm1136 | arm1176*)
+      arm1156 | armv6t2*)
+	path="arm/v6t2 arm/v6 arm/v5 arm"
+	gcc_cflags_arch="-march=armv6t2"
+	;;
+      arm11* | armv6*)
 	path="arm/v6 arm/v5 arm"
 	gcc_cflags_arch="-march=armv6"
 	;;
-      arm1156)
+      armcortexa5 | armv7*)
 	path="arm/v6t2 arm/v6 arm/v5 arm"
-	gcc_cflags_arch="-march=armv6t2"
-	;;
-      armcortexa5)
-	path="arm/v6t2 arm/v6 arm/v5 arm"
 	gcc_cflags_arch="-march=armv7-a"
 	;;
       armcortexa7)
@@ -703,6 +686,8 @@
 	;;
       *)
 	path="arm"
+	gcc_cflags_arch="-march=armv4"
+	GMP_DEFINE_RAW(["define(<NOTHUMB>,1)"])
 	;;
     esac
     ;;
@@ -1800,7 +1785,7 @@
 	path_64="x86_64/coreibwl x86_64/coreihwl x86_64/coreisbr x86_64/coreinhm x86_64/core2 x86_64"
 	# extra_functions_64="missing"	 # enable for bmi2/adx simulation
 	;;
-      skylake | skylakenoavx | cabylake | cabylakenoavx)
+      skylake | skylakenoavx | kabylake | kabylakenoavx)
 	gcc_cflags_cpu="-mtune=skylake -mtune=broadwell -mtune=corei7 -mtune=core2 -mtune=k8"
 	# Don't pass -march=skylake for now as then some compilers emit AVX512.
 	gcc_cflags_arch="-march=broadwell -march=corei7 -march=core2 -march=core2~-mno-sse2 -march=k8 -march=k8~-mno-sse2"
@@ -2470,7 +2455,7 @@
 
 if test "$enable_assembly" = "no"; then
   path="generic"
-  CFLAGS="$CFLAGS -DNO_ASM"
+  AC_DEFINE([NO_ASM],1,[Define to 1 to disable the use of inline assembly])
 #  for abi in $abilist; do
 #    eval unset "path_\$abi"
 #    eval gcc_${abi}_cflags=\"\$gcc_${abi}_cflags -DNO_ASM\"

Modified: trunk/Build/source/libs/gmp/gmp-src/gmp-h.in
===================================================================
--- trunk/Build/source/libs/gmp/gmp-src/gmp-h.in	2016-06-19 06:28:20 UTC (rev 41495)
+++ trunk/Build/source/libs/gmp/gmp-src/gmp-h.in	2016-06-19 09:24:37 UTC (rev 41496)
@@ -1,6 +1,6 @@
 /* Definitions for GNU multiple precision functions.   -*- mode: c -*-
 
-Copyright 1991, 1993-1997, 1999-2015 Free Software Foundation, Inc.
+Copyright 1991, 1993-1997, 1999-2016 Free Software Foundation, Inc.
 
 This file is part of the GNU MP Library.
 
@@ -2326,7 +2326,7 @@
 /* Major version number is the value of __GNU_MP__ too, above and in mp.h. */
 #define __GNU_MP_VERSION            6
 #define __GNU_MP_VERSION_MINOR      1
-#define __GNU_MP_VERSION_PATCHLEVEL 0
+#define __GNU_MP_VERSION_PATCHLEVEL 1
 #define __GNU_MP_RELEASE (__GNU_MP_VERSION * 10000 + __GNU_MP_VERSION_MINOR * 100 + __GNU_MP_VERSION_PATCHLEVEL)
 
 #define __GMP_H__

Modified: trunk/Build/source/libs/gmp/gmp-src/gmp-impl.h
===================================================================
--- trunk/Build/source/libs/gmp/gmp-src/gmp-impl.h	2016-06-19 06:28:20 UTC (rev 41495)
+++ trunk/Build/source/libs/gmp/gmp-src/gmp-impl.h	2016-06-19 09:24:37 UTC (rev 41496)
@@ -1273,7 +1273,9 @@
 #endif
 #define BELOW_THRESHOLD(size,thresh)  (! ABOVE_THRESHOLD (size, thresh))
 
-#define MPN_TOOM22_MUL_MINSIZE    4
+/* The minimal supported value for Toom22 depends also on Toom32 and
+   Toom42 implementations. */
+#define MPN_TOOM22_MUL_MINSIZE    6
 #define MPN_TOOM2_SQR_MINSIZE     4
 
 #define MPN_TOOM33_MUL_MINSIZE   17
@@ -2293,8 +2295,8 @@
 
 struct fft_table_nk
 {
-  unsigned int n:27;
-  unsigned int k:5;
+  gmp_uint_least32_t n:27;
+  gmp_uint_least32_t k:5;
 };
 
 #ifndef FFT_TABLE_ATTRS

Modified: trunk/Build/source/libs/gmp/gmp-src/mpn/arm/aorslsh1_n.asm
===================================================================
--- trunk/Build/source/libs/gmp/gmp-src/mpn/arm/aorslsh1_n.asm	2016-06-19 06:28:20 UTC (rev 41495)
+++ trunk/Build/source/libs/gmp/gmp-src/mpn/arm/aorslsh1_n.asm	2016-06-19 09:24:37 UTC (rev 41496)
@@ -163,5 +163,5 @@
 	REVCY(r12)
 L(rt0):	RETVAL(	r14)
 	pop	{r4-r10r11, r14}
-	bx	r14
+	ret	r14
 EPILOGUE()

Modified: trunk/Build/source/libs/gmp/gmp-src/mpn/arm/arm-defs.m4
===================================================================
--- trunk/Build/source/libs/gmp/gmp-src/mpn/arm/arm-defs.m4	2016-06-19 06:28:20 UTC (rev 41495)
+++ trunk/Build/source/libs/gmp/gmp-src/mpn/arm/arm-defs.m4	2016-06-19 09:24:37 UTC (rev 41496)
@@ -84,6 +84,9 @@
 ')dnl
 ')
 
+define(`ret',`ifdef(`NOTHUMB',`mov	pc, ',`bx')')
+
+
 define(`EPILOGUE_cpu',
 `lea_list
 	SIZE(`$1',.-`$1')')

Modified: trunk/Build/source/libs/gmp/gmp-src/mpn/arm/bdiv_dbm1c.asm
===================================================================
--- trunk/Build/source/libs/gmp/gmp-src/mpn/arm/bdiv_dbm1c.asm	2016-06-19 06:28:20 UTC (rev 41495)
+++ trunk/Build/source/libs/gmp/gmp-src/mpn/arm/bdiv_dbm1c.asm	2016-06-19 09:24:37 UTC (rev 41496)
@@ -109,5 +109,5 @@
 	str	r5, [qp]
 	sbc	r0, r5, r12
 	pop	{r4, r5, r6, r7, r8}
-	bx	lr
+	ret	lr
 EPILOGUE()

Modified: trunk/Build/source/libs/gmp/gmp-src/mpn/arm/cnd_aors_n.asm
===================================================================
--- trunk/Build/source/libs/gmp/gmp-src/mpn/arm/cnd_aors_n.asm	2016-06-19 06:28:20 UTC (rev 41495)
+++ trunk/Build/source/libs/gmp/gmp-src/mpn/arm/cnd_aors_n.asm	2016-06-19 09:24:37 UTC (rev 41496)
@@ -130,5 +130,5 @@
 
 L(end):	RETVAL
 	pop	{r4-r11}
-	bx	r14
+	ret	r14
 EPILOGUE()

Modified: trunk/Build/source/libs/gmp/gmp-src/mpn/arm/com.asm
===================================================================
--- trunk/Build/source/libs/gmp/gmp-src/mpn/arm/com.asm	2016-06-19 06:28:20 UTC (rev 41495)
+++ trunk/Build/source/libs/gmp/gmp-src/mpn/arm/com.asm	2016-06-19 09:24:37 UTC (rev 41496)
@@ -71,5 +71,5 @@
 	bne	L(top)
 
 	ldmfd	sp!, { r7, r8, r9 }		C restore regs from stack
-L(rtn):	bx	lr
+L(rtn):	ret	lr
 EPILOGUE()

Modified: trunk/Build/source/libs/gmp/gmp-src/mpn/arm/copyd.asm
===================================================================
--- trunk/Build/source/libs/gmp/gmp-src/mpn/arm/copyd.asm	2016-06-19 06:28:20 UTC (rev 41495)
+++ trunk/Build/source/libs/gmp/gmp-src/mpn/arm/copyd.asm	2016-06-19 09:24:37 UTC (rev 41496)
@@ -80,5 +80,5 @@
 
 L(end):	stmda	rp, { r3,r4,r5,r12 }
 	pop	{ r4-r5 }
-L(rtn):	bx	lr
+L(rtn):	ret	lr
 EPILOGUE()

Modified: trunk/Build/source/libs/gmp/gmp-src/mpn/arm/copyi.asm
===================================================================
--- trunk/Build/source/libs/gmp/gmp-src/mpn/arm/copyi.asm	2016-06-19 06:28:20 UTC (rev 41495)
+++ trunk/Build/source/libs/gmp/gmp-src/mpn/arm/copyi.asm	2016-06-19 09:24:37 UTC (rev 41496)
@@ -75,5 +75,5 @@
 
 L(end):	stm	rp, { r3,r4,r5,r12 }
 	pop	{ r4-r5 }
-L(rtn):	bx	lr
+L(rtn):	ret	lr
 EPILOGUE()

Modified: trunk/Build/source/libs/gmp/gmp-src/mpn/arm/dive_1.asm
===================================================================
--- trunk/Build/source/libs/gmp/gmp-src/mpn/arm/dive_1.asm	2016-06-19 06:28:20 UTC (rev 41495)
+++ trunk/Build/source/libs/gmp/gmp-src/mpn/arm/dive_1.asm	2016-06-19 09:24:37 UTC (rev 41496)
@@ -112,7 +112,7 @@
 	mul	r9, r4, cy
 	str	r9, [rp]
 	pop	{r4-r9}
-	bx	r14
+	ret	r14
 
 L(unnorm):
 	rsb	tnc, cnt, #32
@@ -136,7 +136,7 @@
 	mul	r9, r4, cy
 	str	r9, [rp]
 	pop	{r4-r9}
-	bx	r14
+	ret	r14
 EPILOGUE()
 
 	RODATA

Modified: trunk/Build/source/libs/gmp/gmp-src/mpn/arm/invert_limb.asm
===================================================================
--- trunk/Build/source/libs/gmp/gmp-src/mpn/arm/invert_limb.asm	2016-06-19 06:28:20 UTC (rev 41495)
+++ trunk/Build/source/libs/gmp/gmp-src/mpn/arm/invert_limb.asm	2016-06-19 09:24:37 UTC (rev 41496)
@@ -52,7 +52,7 @@
 	adds	r1, r12, r0
 	adc	r3, r3, r0
 	rsb	r0, r3, r2
-	bx	lr
+	ret	lr
 EPILOGUE()
 
 	RODATA

Modified: trunk/Build/source/libs/gmp/gmp-src/mpn/arm/logops_n.asm
===================================================================
--- trunk/Build/source/libs/gmp/gmp-src/mpn/arm/logops_n.asm	2016-06-19 06:28:20 UTC (rev 41495)
+++ trunk/Build/source/libs/gmp/gmp-src/mpn/arm/logops_n.asm	2016-06-19 09:24:37 UTC (rev 41496)
@@ -135,5 +135,5 @@
 	pop	{ r4, r5, r6, r7 }	C popping r8-r10 here strangely fails
 
 L(rtn):	pop	{ r8, r9, r10 }
-	bx	r14
+	ret	r14
 EPILOGUE()

Modified: trunk/Build/source/libs/gmp/gmp-src/mpn/arm/lshift.asm
===================================================================
--- trunk/Build/source/libs/gmp/gmp-src/mpn/arm/lshift.asm	2016-06-19 06:28:20 UTC (rev 41495)
+++ trunk/Build/source/libs/gmp/gmp-src/mpn/arm/lshift.asm	2016-06-19 09:24:37 UTC (rev 41496)
@@ -84,5 +84,5 @@
 L(1):	str	r7, [rp, #-4]
 	mov	r0, r4, lsr tnc
 	pop	{r4, r6, r7, r8}
-	bx	r14
+	ret	r14
 EPILOGUE()

Modified: trunk/Build/source/libs/gmp/gmp-src/mpn/arm/lshiftc.asm
===================================================================
--- trunk/Build/source/libs/gmp/gmp-src/mpn/arm/lshiftc.asm	2016-06-19 06:28:20 UTC (rev 41495)
+++ trunk/Build/source/libs/gmp/gmp-src/mpn/arm/lshiftc.asm	2016-06-19 09:24:37 UTC (rev 41496)
@@ -91,5 +91,5 @@
 	str	r7, [rp, #-4]
 	mov	r0, r4, lsr tnc
 	pop	{r4, r6, r7, r8}
-	bx	r14
+	ret	r14
 EPILOGUE()

Modified: trunk/Build/source/libs/gmp/gmp-src/mpn/arm/mod_34lsub1.asm
===================================================================
--- trunk/Build/source/libs/gmp/gmp-src/mpn/arm/mod_34lsub1.asm	2016-06-19 06:28:20 UTC (rev 41495)
+++ trunk/Build/source/libs/gmp/gmp-src/mpn/arm/mod_34lsub1.asm	2016-06-19 09:24:37 UTC (rev 41496)
@@ -106,7 +106,7 @@
 	add	r0, r0, r12, lsr #8
 
 	pop	{ r4, r5, r6, r7 }
-	bx	lr
+	ret	lr
 
 L(le2):	cmn	n, #1
 	bne	L(1)
@@ -117,5 +117,5 @@
 	bic	r0, r2, #0xff000000
 	add	r0, r0, r2, lsr #24
 	pop	{ r4, r5, r6, r7 }
-	bx	lr
+	ret	lr
 EPILOGUE()

Modified: trunk/Build/source/libs/gmp/gmp-src/mpn/arm/mode1o.asm
===================================================================
--- trunk/Build/source/libs/gmp/gmp-src/mpn/arm/mode1o.asm	2016-06-19 06:28:20 UTC (rev 41495)
+++ trunk/Build/source/libs/gmp/gmp-src/mpn/arm/mode1o.asm	2016-06-19 09:24:37 UTC (rev 41496)
@@ -88,5 +88,5 @@
 	addcc	r0, r0, #1
 
 	ldmfd	sp!, {r4, r5}
-	bx	r14
+	ret	r14
 EPILOGUE()

Modified: trunk/Build/source/libs/gmp/gmp-src/mpn/arm/rsh1aors_n.asm
===================================================================
--- trunk/Build/source/libs/gmp/gmp-src/mpn/arm/rsh1aors_n.asm	2016-06-19 06:28:20 UTC (rev 41495)
+++ trunk/Build/source/libs/gmp/gmp-src/mpn/arm/rsh1aors_n.asm	2016-06-19 09:24:37 UTC (rev 41496)
@@ -120,5 +120,5 @@
 	str	r4, [rp, #0]
 	mov	r0, r11
 	pop	{r4-r11}
-	bx	r14
+	ret	r14
 EPILOGUE()

Modified: trunk/Build/source/libs/gmp/gmp-src/mpn/arm/rshift.asm
===================================================================
--- trunk/Build/source/libs/gmp/gmp-src/mpn/arm/rshift.asm	2016-06-19 06:28:20 UTC (rev 41495)
+++ trunk/Build/source/libs/gmp/gmp-src/mpn/arm/rshift.asm	2016-06-19 09:24:37 UTC (rev 41496)
@@ -82,5 +82,5 @@
 L(1):	str	r7, [rp]
 	mov	r0, r4, lsl tnc
 	pop	{r4, r6, r7, r8}
-	bx	r14
+	ret	r14
 EPILOGUE()

Modified: trunk/Build/source/libs/gmp/gmp-src/mpn/arm/sec_tabselect.asm
===================================================================
--- trunk/Build/source/libs/gmp/gmp-src/mpn/arm/sec_tabselect.asm	2016-06-19 06:28:20 UTC (rev 41495)
+++ trunk/Build/source/libs/gmp/gmp-src/mpn/arm/sec_tabselect.asm	2016-06-19 09:24:37 UTC (rev 41496)
@@ -109,7 +109,7 @@
 	bge	L(tp2)
 	stmia	rp, {r8,r9}
 	pop	{r4-r11, r14}
-	bx	lr
+	ret	lr
 
 L(n2):	cmp	j, #-2
 	bne	L(n1)
@@ -127,5 +127,5 @@
 	bge	L(tp1)
 	str	r8, [rp]
 L(n1):	pop	{r4-r11, r14}
-	bx	lr
+	ret	lr
 EPILOGUE()

Modified: trunk/Build/source/libs/gmp/gmp-src/mpn/arm/udiv.asm
===================================================================
--- trunk/Build/source/libs/gmp/gmp-src/mpn/arm/udiv.asm	2016-06-19 06:28:20 UTC (rev 41495)
+++ trunk/Build/source/libs/gmp/gmp-src/mpn/arm/udiv.asm	2016-06-19 09:24:37 UTC (rev 41496)
@@ -61,7 +61,7 @@
 
 	str	n1, [rem_ptr]		C store remainder
 	adc	r0, n0, n0		C quotient: add last carry from divstep
-	bx	lr
+	ret	lr
 
 L(_large_divisor):
 	stmfd	sp!, { r8, lr }

Modified: trunk/Build/source/libs/gmp/gmp-src/mpn/generic/trialdiv.c
===================================================================
--- trunk/Build/source/libs/gmp/gmp-src/mpn/generic/trialdiv.c	2016-06-19 06:28:20 UTC (rev 41495)
+++ trunk/Build/source/libs/gmp/gmp-src/mpn/generic/trialdiv.c	2016-06-19 09:24:37 UTC (rev 41496)
@@ -65,8 +65,8 @@
 struct gmp_primes_ptab {
   mp_limb_t ppp;	/* primes, multiplied together */
   mp_limb_t cps[7];	/* ppp values pre-computed for mpn_mod_1s_4p */
-  unsigned int idx:24;	/* index of  first primes in dtab */
-  unsigned int np :8;	/* number of primes related to this entry */
+  gmp_uint_least32_t idx:24;	/* index of  first primes in dtab */
+  gmp_uint_least32_t np :8;	/* number of primes related to this entry */
 };
 
 

Modified: trunk/Build/source/libs/gmp/gmp-src/mpn/x86_64/coreibwl/mul_basecase.asm
===================================================================
--- trunk/Build/source/libs/gmp/gmp-src/mpn/x86_64/coreibwl/mul_basecase.asm	2016-06-19 06:28:20 UTC (rev 41495)
+++ trunk/Build/source/libs/gmp/gmp-src/mpn/x86_64/coreibwl/mul_basecase.asm	2016-06-19 09:24:37 UTC (rev 41496)
@@ -94,6 +94,7 @@
 
 L(s11):	mov	%rax, (rp)
 	mov	%r9, 8(rp)
+	FUNC_EXIT()
 	ret
 
 L(s2x):	cmp	$2, vn
@@ -105,6 +106,7 @@
 	mov	%rax, (rp)
 	mov	%r9, 8(rp)
 	mov	%r10, 16(rp)
+	FUNC_EXIT()
 	ret
 
 L(s22):	add	%r8, %r9		C 1
@@ -121,6 +123,7 @@
 	mov	%r9, 8(rp)
 	mov	%r10, 16(rp)
 	mov	%rdx, 24(rp)
+	FUNC_EXIT()
 	ret
 
 	ALIGN(16)
@@ -294,6 +297,7 @@
 	pop	%r12
 	pop	%rbp
 	pop	%rbx
+	FUNC_EXIT()
 	ret
 
 L(f2):

Modified: trunk/Build/source/libs/gmp/gmp-src/mpn/x86_64/fat/fat.c
===================================================================
--- trunk/Build/source/libs/gmp/gmp-src/mpn/x86_64/fat/fat.c	2016-06-19 06:28:20 UTC (rev 41495)
+++ trunk/Build/source/libs/gmp/gmp-src/mpn/x86_64/fat/fat.c	2016-06-19 09:24:37 UTC (rev 41496)
@@ -206,6 +206,49 @@
    asm routines only operate correctly up to their own defined threshold,
    not an arbitrary value.  */
 
+static int
+gmp_workaround_skylake_cpuid_bug ()
+{
+  char feature_string[49];
+  char processor_name_string[49];
+  static const char *bad_cpus[] = {" G44", " G45", " G39" /* , "6600" */ };
+  int i;
+
+  /* Example strings:                                   */
+  /* "Intel(R) Pentium(R) CPU G4400 @ 3.30GHz"          */
+  /* "Intel(R) Core(TM) i5-6600K CPU @ 3.50GHz"         */
+  /*                  ^               ^               ^ */
+  /*     0x80000002       0x80000003      0x80000004    */
+  /* We match out just the 0x80000003 part here. */
+
+  /* In their infinitive wisdom, Intel decided to use one register order for
+     the vendor string, and another for the processor name string.  We shuffle
+     things about here, rather than write a new variant of our assembly cpuid.
+  */
+
+  unsigned int eax, ebx, ecx, edx;
+  eax = __gmpn_cpuid (feature_string, 0x80000003);
+  ebx = ((unsigned int *)feature_string)[0];
+  edx = ((unsigned int *)feature_string)[1];
+  ecx = ((unsigned int *)feature_string)[2];
+
+  ((unsigned int *) (processor_name_string))[0] = eax;
+  ((unsigned int *) (processor_name_string))[1] = ebx;
+  ((unsigned int *) (processor_name_string))[2] = ecx;
+  ((unsigned int *) (processor_name_string))[3] = edx;
+
+  processor_name_string[16] = 0;
+
+  for (i = 0; i < sizeof (bad_cpus) / sizeof (char *); i++)
+    {
+      if (strstr (processor_name_string, bad_cpus[i]) != 0)
+	return 1;
+    }
+  return 0;
+}
+
+enum {BMI2_BIT = 8};
+
 void
 __gmpn_cpuvec_init (void)
 {
@@ -311,8 +354,9 @@
 	      /* Some Haswells lack BMI2.  Let them appear as Sandybridges for
 		 now.  */
 	      __gmpn_cpuid (dummy_string, 7);
-	      if ((dummy_string[0 + 8 / 8] & (1 << (8 % 8))) != 0)
-		CPUVEC_SETUP_coreihwl;
+	      if ((dummy_string[0 + BMI2_BIT / 8] & (1 << (BMI2_BIT % 8))) == 0)
+		break;
+	      CPUVEC_SETUP_coreihwl;
 	      break;
 	    case 0x3d:		/* Broadwell */
 	    case 0x47:		/* Broadwell */
@@ -321,6 +365,8 @@
 	      CPUVEC_SETUP_core2;
 	      CPUVEC_SETUP_coreinhm;
 	      CPUVEC_SETUP_coreisbr;
+	      if ((dummy_string[0 + BMI2_BIT / 8] & (1 << (BMI2_BIT % 8))) == 0)
+		break;
 	      CPUVEC_SETUP_coreihwl;
 	      CPUVEC_SETUP_coreibwl;
 	      break;
@@ -327,11 +373,15 @@
 	    case 0x4e:		/* Skylake client */
 	    case 0x55:		/* Skylake server */
 	    case 0x5e:		/* Skylake */
-	    case 0x8e:		/* Cabylake */
-	    case 0x9e:		/* Cabylake */
+	    case 0x8e:		/* Kabylake */
+	    case 0x9e:		/* Kabylake */
 	      CPUVEC_SETUP_core2;
 	      CPUVEC_SETUP_coreinhm;
 	      CPUVEC_SETUP_coreisbr;
+	      if ((dummy_string[0 + BMI2_BIT / 8] & (1 << (BMI2_BIT % 8))) == 0)
+		break;
+	      if (gmp_workaround_skylake_cpuid_bug ())
+		break;
 	      CPUVEC_SETUP_coreihwl;
 	      CPUVEC_SETUP_coreibwl;
 	      CPUVEC_SETUP_skylake;

Modified: trunk/Build/source/libs/gmp/gmp-src/printf/doprnt.c
===================================================================
--- trunk/Build/source/libs/gmp/gmp-src/printf/doprnt.c	2016-06-19 06:28:20 UTC (rev 41495)
+++ trunk/Build/source/libs/gmp/gmp-src/printf/doprnt.c	2016-06-19 09:24:37 UTC (rev 41496)
@@ -160,7 +160,7 @@
 	      const char *orig_fmt, va_list orig_ap)
 {
   va_list  ap, this_ap, last_ap;
-  size_t   alloc_fmt_size;
+  size_t   alloc_fmt_size, orig_fmt_size;
   char     *fmt, *alloc_fmt, *last_fmt, *this_fmt, *gmp_str;
   int      retval = 0;
   int      type, fchar, *value, seen_precision;
@@ -180,7 +180,7 @@
      piece can be null-terminated.  We're not going to be very fast here, so
      use __gmp_allocate_func rather than TMP_ALLOC, to avoid overflowing the
      stack if a long output string is given.  */
-  alloc_fmt_size = strlen (orig_fmt) + 1;
+  alloc_fmt_size = orig_fmt_size = strlen (orig_fmt) + 1;
 #if _LONG_LONG_LIMB
   /* for a long long limb we change %Mx to %llx, so could need an extra 1
      char for every 3 existing */
@@ -188,7 +188,7 @@
 #endif
   alloc_fmt = __GMP_ALLOCATE_FUNC_TYPE (alloc_fmt_size, char);
   fmt = alloc_fmt;
-  memcpy (fmt, orig_fmt, alloc_fmt_size);
+  memcpy (fmt, orig_fmt, orig_fmt_size);
 
   /* last_fmt and last_ap are just after the last output, and hence where
      the next output will begin, when that's done */

Modified: trunk/Build/source/libs/gmp/native/configure
===================================================================
--- trunk/Build/source/libs/gmp/native/configure	2016-06-19 06:28:20 UTC (rev 41495)
+++ trunk/Build/source/libs/gmp/native/configure	2016-06-19 09:24:37 UTC (rev 41496)
@@ -1,6 +1,6 @@
 #! /bin/sh
 # Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.69 for gmp native 6.1.0.
+# Generated by GNU Autoconf 2.69 for gmp native 6.1.1.
 #
 # Report bugs to <tex-k at tug.org>.
 #
@@ -579,8 +579,8 @@
 # Identity of this package.
 PACKAGE_NAME='gmp native'
 PACKAGE_TARNAME='gmp-native'
-PACKAGE_VERSION='6.1.0'
-PACKAGE_STRING='gmp native 6.1.0'
+PACKAGE_VERSION='6.1.1'
+PACKAGE_STRING='gmp native 6.1.1'
 PACKAGE_BUGREPORT='tex-k at tug.org'
 PACKAGE_URL=''
 
@@ -1234,7 +1234,7 @@
   # Omit some internal or obsolete options to make the list less imposing.
   # This message is too long to be a string in the A/UX 3.1 sh.
   cat <<_ACEOF
-\`configure' configures gmp native 6.1.0 to adapt to many kinds of systems.
+\`configure' configures gmp native 6.1.1 to adapt to many kinds of systems.
 
 Usage: $0 [OPTION]... [VAR=VALUE]...
 
@@ -1300,7 +1300,7 @@
 
 if test -n "$ac_init_help"; then
   case $ac_init_help in
-     short | recursive ) echo "Configuration of gmp native 6.1.0:";;
+     short | recursive ) echo "Configuration of gmp native 6.1.1:";;
    esac
   cat <<\_ACEOF
 
@@ -1396,7 +1396,7 @@
 test -n "$ac_init_help" && exit $ac_status
 if $ac_init_version; then
   cat <<\_ACEOF
-gmp native configure 6.1.0
+gmp native configure 6.1.1
 generated by GNU Autoconf 2.69
 
 Copyright (C) 2012 Free Software Foundation, Inc.
@@ -1497,7 +1497,7 @@
 This file contains any messages produced by compilers while
 running configure, to aid debugging if configure makes a mistake.
 
-It was created by gmp native $as_me 6.1.0, which was
+It was created by gmp native $as_me 6.1.1, which was
 generated by GNU Autoconf 2.69.  Invocation command line was
 
   $ $0 $@
@@ -3420,7 +3420,7 @@
 
 # Define the identity of the package.
  PACKAGE='gmp-native'
- VERSION='6.1.0'
+ VERSION='6.1.1'
 
 
 cat >>confdefs.h <<_ACEOF
@@ -4974,7 +4974,7 @@
 # report actual input values of CONFIG_FILES etc. instead of their
 # values after options handling.
 ac_log="
-This file was extended by gmp native $as_me 6.1.0, which was
+This file was extended by gmp native $as_me 6.1.1, which was
 generated by GNU Autoconf 2.69.  Invocation command line was
 
   CONFIG_FILES    = $CONFIG_FILES
@@ -5040,7 +5040,7 @@
 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
 ac_cs_version="\\
-gmp native config.status 6.1.0
+gmp native config.status 6.1.1
 configured by $0, generated by GNU Autoconf 2.69,
   with options \\"\$ac_cs_config\\"
 

Modified: trunk/Build/source/libs/gmp/version.ac
===================================================================
--- trunk/Build/source/libs/gmp/version.ac	2016-06-19 06:28:20 UTC (rev 41495)
+++ trunk/Build/source/libs/gmp/version.ac	2016-06-19 09:24:37 UTC (rev 41496)
@@ -8,4 +8,4 @@
 dnl --------------------------------------------------------
 dnl
 dnl  m4-include this file to define the current gmp version
-m4_define([gmp_version], [6.1.0])
+m4_define([gmp_version], [6.1.1])



More information about the tex-live-commits mailing list