[Gmp-commit] /var/hg/gmp: Move NO_ASM to config.h (from CFLAGS) and remove th...

mercurial at gmplib.org mercurial at gmplib.org
Sun Mar 20 14:55:39 UTC 2016


details:   /var/hg/gmp/rev/a70e6b446199
changeset: 17036:a70e6b446199
user:      Marc Glisse <marc.glisse at inria.fr>
date:      Sun Mar 20 15:55:31 2016 +0100
description:
Move NO_ASM to config.h (from CFLAGS) and remove the redundant WANT_ASSEMBLY.

diffstat:

 ChangeLog    |  6 ++++++
 configure.ac |  7 +------
 tests/misc.c |  4 ++--
 3 files changed, 9 insertions(+), 8 deletions(-)

diffs (58 lines):

diff -r 9d3f0a97a14e -r a70e6b446199 ChangeLog
--- a/ChangeLog	Sun Mar 20 12:14:37 2016 +0100
+++ b/ChangeLog	Sun Mar 20 15:55:31 2016 +0100
@@ -1,3 +1,9 @@
+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.
diff -r 9d3f0a97a14e -r a70e6b446199 configure.ac
--- a/configure.ac	Sun Mar 20 12:14:37 2016 +0100
+++ b/configure.ac	Sun Mar 20 15:55:31 2016 +0100
@@ -142,11 +142,6 @@
 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]]),
@@ -2467,7 +2462,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\"
diff -r 9d3f0a97a14e -r a70e6b446199 tests/misc.c
--- a/tests/misc.c	Sun Mar 20 12:14:37 2016 +0100
+++ b/tests/misc.c	Sun Mar 20 15:55:31 2016 +0100
@@ -501,7 +501,7 @@
 int
 tests_hardware_setround (int mode)
 {
-#if WANT_ASSEMBLY && HAVE_HOST_CPU_FAMILY_x86
+#if ! defined NO_ASM && HAVE_HOST_CPU_FAMILY_x86
   int  rc;
   switch (mode) {
   case 0: rc = 0; break;  /* nearest */
@@ -522,7 +522,7 @@
 int
 tests_hardware_getround (void)
 {
-#if WANT_ASSEMBLY && HAVE_HOST_CPU_FAMILY_x86
+#if ! defined NO_ASM && HAVE_HOST_CPU_FAMILY_x86
   switch ((x86_fstcw () & ~0xC00) >> 10) {
   case 0: return 0; break;  /* nearest */
   case 1: return 3; break;  /* down    */


More information about the gmp-commit mailing list