diff options
-rw-r--r-- | gcc/ChangeLog | 16 | ||||
-rw-r--r-- | gcc/Makefile.in | 13 | ||||
-rw-r--r-- | gcc/config.gcc | 10 | ||||
-rw-r--r-- | gcc/config/pa/pa-700.h | 24 | ||||
-rw-r--r-- | gcc/config/pa/pa-7100.h | 24 | ||||
-rwxr-xr-x | gcc/configure | 4 | ||||
-rw-r--r-- | gcc/configure.in | 1 | ||||
-rw-r--r-- | gcc/doc/install.texi | 11 | ||||
-rw-r--r-- | gcc/mkconfig.sh | 15 |
9 files changed, 50 insertions, 68 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index b190a54807e..b4eb108b6c9 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,19 @@ +2002-06-15 John David Anglin <dave@hiauly1.hia.nrc.ca> + + * Makefile.in (tm_defines): New configuration variable. + (cs-config.h, cs-hconfig.h, cs-tconfig.h): Rename DEFINES to XM_DEFINES. + Pass tm_defines in TM_DEFINES. + (cs-tm_p.h): Rename DEFINES to XM_DEFINES. Pass TM_DEFINES. + * config.gcc (tm_defines): New configuration variable. + (hppa*-*-* | parisc*-*-*): Use tm_defines instead of pa-700.h and + pa-7100.h headers. Change hppa1* scheduling default to 7100LC. + * configure.in: Substitute tm_defines. + * configure: Rebuilt. + * mkconfig.sh: Rename DEFINES to XM_DEFINES. Output TM_DEFINES. + * doc/install.texi: Update. + * pa/pa-700.h: Delete file. + * pa/pa-7100.h: Delete file. + 2002-06-15 Roger Sayle <roger@eyesopen.com> * fold-const.c (comparison_to_compcode): New function to convert diff --git a/gcc/Makefile.in b/gcc/Makefile.in index 7f4e42a8bd5..dfa18f5e161 100644 --- a/gcc/Makefile.in +++ b/gcc/Makefile.in @@ -259,6 +259,7 @@ tmake_file=@dep_tmake_file@ out_file=$(srcdir)/config/@out_file@ out_object_file=@out_object_file@ md_file=$(srcdir)/config/@md_file@ +tm_defines=@tm_defines@ tm_p_file_list=@tm_p_file_list@ tm_p_file=@tm_p_file@ build_xm_file_list=@build_xm_file_list@ @@ -845,22 +846,26 @@ tconfig.h: cs-tconfig.h ; @true tm_p.h: cs-tm_p.h ; @true cs-config.h: Makefile - HEADERS="$(host_xm_file)" DEFINES="$(host_xm_defines)" \ + TM_DEFINES="$(tm_defines)" \ + HEADERS="$(host_xm_file)" XM_DEFINES="$(host_xm_defines)" \ TARGET_CPU_DEFAULT="$(target_cpu_default)" \ $(SHELL) $(srcdir)/mkconfig.sh config.h cs-hconfig.h: Makefile - HEADERS="$(build_xm_file)" DEFINES="$(build_xm_defines)" \ + TM_DEFINES="$(tm_defines)" \ + HEADERS="$(build_xm_file)" XM_DEFINES="$(build_xm_defines)" \ TARGET_CPU_DEFAULT="$(target_cpu_default)" \ $(SHELL) $(srcdir)/mkconfig.sh hconfig.h cs-tconfig.h: Makefile - HEADERS="$(xm_file)" DEFINES="$(xm_defines)" \ + TM_DEFINES="$(tm_defines)" \ + HEADERS="$(xm_file)" XM_DEFINES="$(xm_defines)" \ TARGET_CPU_DEFAULT="" \ $(SHELL) $(srcdir)/mkconfig.sh tconfig.h cs-tm_p.h: Makefile - HEADERS="$(tm_p_file)" DEFINES="" TARGET_CPU_DEFAULT="" \ + TM_DEFINES="" \ + HEADERS="$(tm_p_file)" XM_DEFINES="" TARGET_CPU_DEFAULT="" \ $(SHELL) $(srcdir)/mkconfig.sh tm_p.h # Don't automatically run autoconf, since configure.in might be accidentally diff --git a/gcc/config.gcc b/gcc/config.gcc index 38b7adc3be3..16b701160bc 100644 --- a/gcc/config.gcc +++ b/gcc/config.gcc @@ -45,6 +45,8 @@ # # cpu_type The name of the cpu, if different from machine. # +# tm_defines List of target macros to define for all compilations. +# # tm_file A list of target macro files, if different from # "$cpu_type/$cpu_type.h". Usually it's constructed # per target in a way like this: @@ -188,6 +190,7 @@ extra_host_objs= extra_gcc_objs= c_target_objs= cxx_target_objs= +tm_defines= xm_defines= float_format= # Set this to force installation and use of collect2. @@ -2850,11 +2853,8 @@ hppa*-*-* | parisc*-*-*) target_cpu_default2="MASK_GAS|MASK_JUMP_IN_DELAY" fi case $machine in - hppa1.0* | parisc1.0*) - tm_file="pa/pa-700.h ${tm_file}" - ;; - hppa1.1* | parisc1.1*) - tm_file="pa/pa-7100.h ${tm_file}" + hppa1* | parisc1*) + tm_defines="TARGET_SCHED_DEFAULT=\\\"7100LC\\\"" ;; esac ;; diff --git a/gcc/config/pa/pa-700.h b/gcc/config/pa/pa-700.h deleted file mode 100644 index 3529a299e96..00000000000 --- a/gcc/config/pa/pa-700.h +++ /dev/null @@ -1,24 +0,0 @@ -/* Definitions of target machine for GNU compiler, for HPs using the - PA700 scheduling model. - Copyright (C) 2002 Free Software Foundation, Inc. - -This file is part of GNU CC. - -GNU CC is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 2, or (at your option) -any later version. - -GNU CC is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License -along with GNU CC; see the file COPYING. If not, write to -the Free Software Foundation, 59 Temple Place - Suite 330, -Boston, MA 02111-1307, USA. */ - -#ifndef TARGET_SCHED_DEFAULT -#define TARGET_SCHED_DEFAULT "700" -#endif diff --git a/gcc/config/pa/pa-7100.h b/gcc/config/pa/pa-7100.h deleted file mode 100644 index 7f450a41659..00000000000 --- a/gcc/config/pa/pa-7100.h +++ /dev/null @@ -1,24 +0,0 @@ -/* Definitions of target machine for GNU compiler, for HPs using the - PA7100 scheduling model. - Copyright (C) 2002 Free Software Foundation, Inc. - -This file is part of GNU CC. - -GNU CC is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 2, or (at your option) -any later version. - -GNU CC is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License -along with GNU CC; see the file COPYING. If not, write to -the Free Software Foundation, 59 Temple Place - Suite 330, -Boston, MA 02111-1307, USA. */ - -#ifndef TARGET_SCHED_DEFAULT -#define TARGET_SCHED_DEFAULT "7100" -#endif diff --git a/gcc/configure b/gcc/configure index f3fc015b2fe..c414fcf82d1 100755 --- a/gcc/configure +++ b/gcc/configure @@ -2244,7 +2244,7 @@ EOF fi # Find some useful tools -for ac_prog in gawk mawk nawk awk +for ac_prog in mawk gawk nawk awk do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 @@ -8373,6 +8373,7 @@ ${CONFIG_SHELL-/bin/sh} $srcdir/configure.frag $srcdir "$subdirs" "$dep_host_xma + # Echo that links are built if test x$host = x$target then @@ -8684,6 +8685,7 @@ s%@symbolic_link@%$symbolic_link%g s%@thread_file@%$thread_file%g s%@tm_file_list@%$tm_file_list%g s%@tm_file@%$tm_file%g +s%@tm_defines@%$tm_defines%g s%@tm_p_file_list@%$tm_p_file_list%g s%@tm_p_file@%$tm_p_file%g s%@xm_file@%$xm_file%g diff --git a/gcc/configure.in b/gcc/configure.in index d6316d2fcbe..355f174448b 100644 --- a/gcc/configure.in +++ b/gcc/configure.in @@ -2595,6 +2595,7 @@ AC_SUBST(symbolic_link) AC_SUBST(thread_file) AC_SUBST(tm_file_list) AC_SUBST(tm_file) +AC_SUBST(tm_defines) AC_SUBST(tm_p_file_list) AC_SUBST(tm_p_file) AC_SUBST(xm_file) diff --git a/gcc/doc/install.texi b/gcc/doc/install.texi index 9f0a1ab236f..c087bdfa62d 100644 --- a/gcc/doc/install.texi +++ b/gcc/doc/install.texi @@ -1997,12 +1997,11 @@ If you wish to use pa-risc 2.0 architecture support, you must use either the HP assembler, gas/binutils 2.11 or a recent @uref{ftp://sources.redhat.com/pub/binutils/snapshots,,snapshot of gas}. -There are three default scheduling models for instructions. They -are PROCESSOR_700, PROCESSOR_7100 and PROCESSOR_8000. They are selected -based on the the pa-risc architecture specified for the target machine -when configuring. PROCESSOR_8000 is the default model. PROCESSOR_700 -and PROCESSOR_7100 are selected by specifying either @samp{hppa1.0} or -@samp{hppa1.1}, respectively. +There are two default scheduling models for instructions. These are +PROCESSOR_7100LC and PROCESSOR_8000. They are selected from the pa-risc +architecture specified for the target machine when configuring. +PROCESSOR_8000 is the default. PROCESSOR_7100LC is selected when +the target is a @samp{hppa1*} machine. The PROCESSOR_8000 model is not well suited to older processors. Thus, it is important to completely specify the machine architecture when diff --git a/gcc/mkconfig.sh b/gcc/mkconfig.sh index 5b86b79f8b9..cc87ccb37e8 100644 --- a/gcc/mkconfig.sh +++ b/gcc/mkconfig.sh @@ -2,11 +2,11 @@ # Generate gcc's config.h, which is not your normal autoconf-generated # config.h (that's auto-(host|build).h). $1 is the file to generate. -# HEADERS, DEFINES, and possibly TARGET_CPU_DEFAULT are expected to be -# set in the environment. +# TM_DEFINES, HEADERS, XM_DEFINES, and possibly TARGET_CPU_DEFAULT are +# expected to be set in the environment. if [ -z "$1" ]; then - echo "Usage: HEADERS='list' DEFINES='list' mkconfig.sh FILE" >&2 + echo "Usage: TM_DEFINES='list' HEADERS='list' XM_DEFINES='list' mkconfig.sh FILE" >&2 exit 1 fi @@ -19,6 +19,13 @@ if [ "$TARGET_CPU_DEFAULT" != "" ]; then echo "#define TARGET_CPU_DEFAULT ($TARGET_CPU_DEFAULT)" >> ${output}T fi +# Provide defines for other target machine macros to be used everywhere. +for def in $TM_DEFINES; do + echo "#ifndef $def" | sed 's/=.*//' >> ${output}T + echo "# define $def" | sed 's/=/ /' >> ${output}T + echo "#endif" >> ${output}T +done + # The first entry in HEADERS may be auto-host.h or auto-build.h; # it wants to be included even when not -DIN_GCC. if [ -n "$HEADERS" ]; then @@ -63,7 +70,7 @@ if [ -n "$HEADERS" ]; then echo '#endif' >> ${output}T fi -for def in $DEFINES; do +for def in $XM_DEFINES; do echo "#ifndef $def" | sed 's/=.*//' >> ${output}T echo "# define $def" | sed 's/=/ /' >> ${output}T echo "#endif" >> ${output}T |