From 195d2dec10a7faef45e9f5b4002ed44b1f6627be Mon Sep 17 00:00:00 2001 From: Daniel Dunbar Date: Sat, 10 Apr 2010 18:56:24 +0000 Subject: [PATCH] configure: Fix default value for optimize_option, I messed up the test condition in r86005 and unintentionally changed the default from -O3 to -O2. - It's odd the things automated perf testing turns up! :) - Also, the configure diff is messed up slightly. It looks like someone either didn't regenerate configure correctly (or I didn't), or autoconf has some funnyness in it. Eric, any ideas? This has been at -O2 for so long, that I am slightly nervous that this change will uncover miscompiles of LLVM on other systems. If that is the case, I think we should just set the default universally at -O3, and let developers/vendors use -O3 if they want it and have tested it. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100941 91177308-0d34-0410-b5e6-96231b3b80d8 --- autoconf/configure.ac | 4 ++-- configure | 15 +++++++++++---- 2 files changed, 13 insertions(+), 6 deletions(-) diff --git a/autoconf/configure.ac b/autoconf/configure.ac index bd85577bcbd..ff5804b27dc 100644 --- a/autoconf/configure.ac +++ b/autoconf/configure.ac @@ -728,8 +728,8 @@ AC_MSG_CHECKING([optimization flags]) case "$withval" in default) case "$llvm_cv_os_type" in - MingW) optimize_option=-O3 ;; - *) optimize_option=-O2 ;; + MingW) optimize_option=-O2 ;; + *) optimize_option=-O3 ;; esac ;; *) optimize_option="$withval" ;; esac diff --git a/configure b/configure index cb8b274c157..82aaccdb04d 100755 --- a/configure +++ b/configure @@ -14,7 +14,7 @@ ## M4sh Initialization. ## ## --------------------- ## -# Be Bourne compatible. +# Be Bourne compatible if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then emulate sh NULLCMD=: @@ -2166,6 +2166,11 @@ else llvm_cv_no_link_all_option="-Wl,-noall_load" llvm_cv_os_type="Darwin" llvm_cv_platform_type="Unix" ;; + *-*-minix*) + llvm_cv_link_all_option="-Wl,-all_load" + llvm_cv_no_link_all_option="-Wl,-noall_load" + llvm_cv_os_type="Minix" + llvm_cv_platform_type="Unix" ;; *-*-freebsd*) llvm_cv_link_all_option="-Wl,--whole-archive" llvm_cv_no_link_all_option="-Wl,--no-whole-archive" @@ -2260,6 +2265,8 @@ else llvm_cv_target_os_type="Cygwin" ;; *-*-darwin*) llvm_cv_target_os_type="Darwin" ;; + *-*-minix*) + llvm_cv_target_os_type="Minix" ;; *-*-freebsd*) llvm_cv_target_os_type="FreeBSD" ;; *-*-openbsd*) @@ -5162,8 +5169,8 @@ echo $ECHO_N "checking optimization flags... $ECHO_C" >&6; } case "$withval" in default) case "$llvm_cv_os_type" in - MingW) optimize_option=-O3 ;; - *) optimize_option=-O2 ;; + MingW) optimize_option=-O2 ;; + *) optimize_option=-O3 ;; esac ;; *) optimize_option="$withval" ;; esac @@ -11156,7 +11163,7 @@ else lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 lt_status=$lt_dlunknown cat > conftest.$ac_ext <