aboutsummaryrefslogtreecommitdiff
path: root/gcc/configure.ac
diff options
context:
space:
mode:
authorDavid Edelsohn <dje.gcc@gmail.com>2012-11-14 16:41:21 +0000
committerDavid Edelsohn <dje.gcc@gmail.com>2012-11-14 16:41:21 +0000
commit6007f4ccd163e63585a45d9e16f5a497b7264c52 (patch)
treec71692baa6ca664efa39787ea6398cc4fcbb3ed8 /gcc/configure.ac
parent754e9eb2b15b19c361dab9ee1463abfff93e5778 (diff)
* configure.ac (HAVE_LD_LARGE_TOC): Add AIX test.
* configure: Regenerated. * config/rs6000/aix61.h (SUBTARGET_OVERRIDE_OPTIONS): Warn if other toc options used with cmodel. Disable TARGET_NO_FP_IN_TOC and TARGET_NO_SUM_IN_TOC if not CMODEL_SMALL. CMODEL_MEDIUM means CMODEL_LARGE on AIX. (ASM_SPEC): -mvsx implies -mpwr6. Add -many. (ASM_DEFAULT_SPEC): Use -mpwr4. (TARGET_CMODEL): Define. (SET_CMODEL): Define. * config/rs6000/rs6000.md (largetoc_high_aix<mode>): New. (largetoc_high_plus_aix<mode>): New. (largetoc_low<mode>): Change to mode iterator. Test TARGET_TOC instead of TARGET_ELF. (tocref): Remove TARGET_ELF test. * config/rs6000/rs6000.c (output_toc): Use [TE] for large TOC symbols on AIX. * config/rs6000/aix64.opt (mcmodel): New. git-svn-id: https://gcc.gnu.org/svn/gcc/trunk@193502 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/configure.ac')
-rw-r--r--gcc/configure.ac29
1 files changed, 29 insertions, 0 deletions
diff --git a/gcc/configure.ac b/gcc/configure.ac
index e0e12c0c4e0..efddb7a46b3 100644
--- a/gcc/configure.ac
+++ b/gcc/configure.ac
@@ -4496,6 +4496,35 @@ EOF
;;
esac
+case "$target" in
+ *-*-aix*)
+ AC_CACHE_CHECK(linker large toc support,
+ gcc_cv_ld_large_toc,
+ [gcc_cv_ld_large_toc=no
+ if test x$gcc_cv_as != x ; then
+ cat > conftest.s <<EOF
+ .toc
+LC..1:
+ .tc a[[TC]],a[[RW]]
+ .extern a[[RW]]
+ .csect .text[[PR]]
+.largetoctest:
+ addis 9,LC..1@u(2)
+ ld 3,LC..1@l(9)
+EOF
+ if $gcc_cv_as -a64 -o conftest.o conftest.s > /dev/null 2>&1; then
+ gcc_cv_ld_large_toc=yes
+ fi
+ rm -f conftest conftest.o conftest.s
+ fi
+ ])
+ if test x"$gcc_cv_ld_large_toc" = xyes; then
+ AC_DEFINE(HAVE_LD_LARGE_TOC, 1,
+ [Define if your AIX linker supports a large TOC.])
+ fi
+ ;;
+esac
+
AC_CACHE_CHECK(linker --build-id support,
gcc_cv_ld_buildid,
[gcc_cv_ld_buildid=no