diff options
author | Richard Henderson <rth@redhat.com> | 2012-10-30 21:46:20 -0700 |
---|---|---|
committer | Richard Henderson <rth@gcc.gnu.org> | 2012-10-30 21:46:20 -0700 |
commit | 07d3b5c8c0d446ffb57d73d821dcf8156b12bf5d (patch) | |
tree | d14c657f9fcd9e62f20fcf5786a4d5d2d485b224 /libitm/configure | |
parent | d0a54439c14c34e38ab13d6ba1e4de8b35d1fbb9 (diff) | |
download | gcc-07d3b5c8c0d446ffb57d73d821dcf8156b12bf5d.zip gcc-07d3b5c8c0d446ffb57d73d821dcf8156b12bf5d.tar.gz gcc-07d3b5c8c0d446ffb57d73d821dcf8156b12bf5d.tar.bz2 |
Detect assembler support for RTM
* acinclude.m4 (LIBITM_CHECK_AS_RTM): New.
* configure.ac: Use it.
* config.h.in, configure: Rebuild.
* testsuite/Makefile.in: Rebuild.
From-SVN: r193017
Diffstat (limited to 'libitm/configure')
-rw-r--r-- | libitm/configure | 60 |
1 files changed, 51 insertions, 9 deletions
diff --git a/libitm/configure b/libitm/configure index 4b547ab..d985cf7 100644 --- a/libitm/configure +++ b/libitm/configure @@ -667,6 +667,7 @@ CXX am__fastdepCC_FALSE am__fastdepCC_TRUE CCDEPMODE +am__nodep AMDEPBACKSLASH AMDEP_FALSE AMDEP_TRUE @@ -3318,11 +3319,11 @@ MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"} # We need awk for the "check" target. The system "awk" is bad on # some platforms. -# Always define AMTAR for backward compatibility. +# Always define AMTAR for backward compatibility. Yes, it's still used +# in the wild :-( We should find a proper way to deprecate it ... +AMTAR='$${TAR-tar}' -AMTAR=${AMTAR-"${am_missing_run}tar"} - -am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -' +am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -' @@ -4220,6 +4221,7 @@ fi if test "x$enable_dependency_tracking" != xno; then am_depcomp="$ac_aux_dir/depcomp" AMDEPBACKSLASH='\' + am__nodep='_no' fi if test "x$enable_dependency_tracking" != xno; then AMDEP_TRUE= @@ -4244,6 +4246,7 @@ else # instance it was reported that on HP-UX the gcc test will end up # making a dummy file named `D' -- because `-MD' means `put the output # in D'. + rm -rf conftest.dir mkdir conftest.dir # Copy depcomp to subdir because otherwise we won't find it if we're # using a relative directory. @@ -4303,7 +4306,7 @@ else break fi ;; - msvisualcpp | msvcmsys) + msvc7 | msvc7msys | msvisualcpp | msvcmsys) # This compiler won't grok `-c -o', but also, the minuso test has # not run yet. These depmodes are late enough in the game, and # so weak that their functioning should not be impacted. @@ -4628,6 +4631,7 @@ else # instance it was reported that on HP-UX the gcc test will end up # making a dummy file named `D' -- because `-MD' means `put the output # in D'. + rm -rf conftest.dir mkdir conftest.dir # Copy depcomp to subdir because otherwise we won't find it if we're # using a relative directory. @@ -4687,7 +4691,7 @@ else break fi ;; - msvisualcpp | msvcmsys) + msvc7 | msvc7msys | msvisualcpp | msvcmsys) # This compiler won't grok `-c -o', but also, the minuso test has # not run yet. These depmodes are late enough in the game, and # so weak that their functioning should not be impacted. @@ -4762,6 +4766,7 @@ else # instance it was reported that on HP-UX the gcc test will end up # making a dummy file named `D' -- because `-MD' means `put the output # in D'. + rm -rf conftest.dir mkdir conftest.dir # Copy depcomp to subdir because otherwise we won't find it if we're # using a relative directory. @@ -4819,7 +4824,7 @@ else break fi ;; - msvisualcpp | msvcmsys) + msvc7 | msvc7msys | msvisualcpp | msvcmsys) # This compiler won't grok `-c -o', but also, the minuso test has # not run yet. These depmodes are late enough in the game, and # so weak that their functioning should not be impacted. @@ -11779,7 +11784,7 @@ else lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 lt_status=$lt_dlunknown cat > conftest.$ac_ext <<_LT_EOF -#line 11782 "configure" +#line 11787 "configure" #include "confdefs.h" #if HAVE_DLFCN_H @@ -11885,7 +11890,7 @@ else lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 lt_status=$lt_dlunknown cat > conftest.$ac_ext <<_LT_EOF -#line 11888 "configure" +#line 11893 "configure" #include "confdefs.h" #if HAVE_DLFCN_H @@ -17327,6 +17332,43 @@ $as_echo "#define HAVE_AS_AVX 1" >>confdefs.h ;; esac +case "${target_cpu}" in +i[34567]86 | x86_64) + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the assembler supports RTM" >&5 +$as_echo_n "checking if the assembler supports RTM... " >&6; } +if test "${libitm_cv_as_rtm+set}" = set; then : + $as_echo_n "(cached) " >&6 +else + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ +asm("1: xbegin 1b; xend"); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + libitm_cv_as_rtm=yes +else + libitm_cv_as_rtm=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libitm_cv_as_rtm" >&5 +$as_echo "$libitm_cv_as_rtm" >&6; } + if test x$libitm_cv_as_rtm = xyes; then + +$as_echo "#define HAVE_AS_RTM 1" >>confdefs.h + + fi + ;; +esac + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether weak refs work like ELF" >&5 $as_echo_n "checking whether weak refs work like ELF... " >&6; } |