diff options
author | Lynn Boger <laboger@linux.vnet.ibm.com> | 2015-09-30 18:06:11 -0500 |
---|---|---|
committer | Ian Lance Taylor <ian@gcc.gnu.org> | 2015-09-30 23:06:11 +0000 |
commit | 402565b61f9783473472fcfd729efa8c1e355d2b (patch) | |
tree | 37eb8b2f85d9a656044717d6a82ffa026692d05c /gcc/configure | |
parent | 7dc396e20f0efa59cad65d95d53ff1541d9ae807 (diff) | |
download | gcc-402565b61f9783473472fcfd729efa8c1e355d2b.zip gcc-402565b61f9783473472fcfd729efa8c1e355d2b.tar.gz gcc-402565b61f9783473472fcfd729efa8c1e355d2b.tar.bz2 |
re PR go/66870 (split stack issues on ppc64le and ppc64)
PR target/66870
* config/rs6000/sysv4.h (TARGET_CAN_SPLIT_STACK_64BIT): Define.
* configure.ac: Define HAVE_GOLD_ALTERNATE_SPLIT_STACK on Power
based on gold linker version.
* gcc.c: Add -fuse-ld=gold to STACK_SPLIT_SPEC if
HAVE_GOLD_ALTERNATE_SPLIT_STACK defined.
* configure, config.in: Regenerate.
go:
* gospec.c (lang_specific_driver): Set appropriate split stack
options for 64 bit compiles based on TARGET_CAN_SPLIT_STACK_64BIT.
From-SVN: r228311
Diffstat (limited to 'gcc/configure')
-rwxr-xr-x | gcc/configure | 39 |
1 files changed, 39 insertions, 0 deletions
diff --git a/gcc/configure b/gcc/configure index c2b630e..f6ae9906 100755 --- a/gcc/configure +++ b/gcc/configure @@ -22015,6 +22015,45 @@ fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_is_gold" >&5 $as_echo "$ld_is_gold" >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking gold linker with split stack support as non default" >&5 +$as_echo_n "checking gold linker with split stack support as non default... " >&6; } +# Check to see if default ld is not gold, but gold is +# available and has support for split stack. If gcc was configured +# with gold then no checking is done. +# +if test x$ld_is_gold = xno && which ${gcc_cv_ld}.gold >/dev/null 2>&1; then + +# For platforms other than powerpc64*, enable as appropriate. + + gold_non_default=no + ld_gold=`which ${gcc_cv_ld}.gold` +# Make sure this gold has minimal split stack support + if $ld_gold --help 2>/dev/null | grep split-stack-adjust-size >/dev/null 2>&1; then + ld_vers=`$ld_gold --version | sed 1q` + gold_vers=`echo $ld_vers | sed -n \ + -e 's,^[^)]*[ ]\([0-9][0-9]*\.[0-9][0-9]*[^)]*\)) .*$,\1,p'` + case $target in +# check that the gold version contains the complete split stack support +# on powerpc64 big and little endian + powerpc64*-*-*) + case "$gold_vers" in + 2.25.[1-9]*|2.2[6-9][.0-9]*|2.[3-9][.0-9]*|[3-9].[.0-9]*) gold_non_default=yes + ;; + *) gold_non_default=no + ;; + esac + ;; + esac + fi + if test $gold_non_default = yes; then + +$as_echo "#define HAVE_GOLD_NON_DEFAULT_SPLIT_STACK 1" >>confdefs.h + + fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gold_non_default" >&5 +$as_echo "$gold_non_default" >&6; } + ORIGINAL_LD_FOR_TARGET=$gcc_cv_ld case "$ORIGINAL_LD_FOR_TARGET" in |