From 785fdabd140742339b174a510c77b95213837004 Mon Sep 17 00:00:00 2001 From: law Date: Fri, 20 Apr 2001 01:13:37 +0000 Subject: [PATCH] * config/pa/pa-linux.h (CPLUSPLUS_CPP_SPEC): Undefine. * config/pa/pa.h (CPLUSPLuS_CPP_SPEC): Define. * config/pa/som.h (ASM_OUTPUT_FUNCTION_PREFIX): Truncate subspace name at 32 total characters. (ASM_OUTPUT_SECTION_NAME): Similarly. Also, only support placing functions in named sections -- data items can still go into unique sections, but they have normal names (ie $LIT$ and $DATA$). * config/pa/som.h (SUPPORTS_INIT_PRIORITY): SOM does not support INIT_PRIORITY. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@41436 138bc75d-0d04-0410-961f-82ee72b054a4 --- gcc/ChangeLog | 14 ++++++++++++++ gcc/config/pa/pa-linux.h | 2 ++ gcc/config/pa/pa.h | 11 +++++++++++ gcc/config/pa/som.h | 24 +++++++++++++++--------- 4 files changed, 42 insertions(+), 9 deletions(-) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 73c12a0..e291df9 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,17 @@ +Thu Apr 19 19:15:26 2001 Jeffrey A Law (law@cygnus.com) + + * config/pa/pa-linux.h (CPLUSPLUS_CPP_SPEC): Undefine. + * config/pa/pa.h (CPLUSPLuS_CPP_SPEC): Define. + + * config/pa/som.h (ASM_OUTPUT_FUNCTION_PREFIX): Truncate subspace + name at 32 total characters. + (ASM_OUTPUT_SECTION_NAME): Similarly. Also, only support placing + functions in named sections -- data items can still go into unique + sections, but they have normal names (ie $LIT$ and $DATA$). + + * config/pa/som.h (SUPPORTS_INIT_PRIORITY): SOM does not support + INIT_PRIORITY. + 2001-04-19 DJ Delorie * config/alpha/vms.h: Change OBJECT_SUFFIX and EXECUTABLE_SUFFIX diff --git a/gcc/config/pa/pa-linux.h b/gcc/config/pa/pa-linux.h index baa1cf5..5ed5901 100644 --- a/gcc/config/pa/pa-linux.h +++ b/gcc/config/pa/pa-linux.h @@ -27,6 +27,8 @@ Boston, MA 02111-1307, USA. */ #undef CPP_PREDEFINES #define CPP_PREDEFINES "-D__ELF__ -Dunix -D__hppa__ -Dlinux -Asystem=unix -Asystem=posix -Acpu=hppa -Amachine=hppa -Amachine=bigendian" +#undef CPLUSPLUS_CPP_SPEC + #undef LIB_SPEC #define LIB_SPEC "%{!p:%{!pg:-lc}}%{p:-lc_p}%{pg:-lc_p}" diff --git a/gcc/config/pa/pa.h b/gcc/config/pa/pa.h index 6b3ecee..1ce9794 100644 --- a/gcc/config/pa/pa.h +++ b/gcc/config/pa/pa.h @@ -329,6 +329,17 @@ extern int target_flags; %{!ansi: -D_HPUX_SOURCE -D_HIUX_SOURCE -D__STDC_EXT__} \ %{threads: -D_REENTRANT -D_DCE_THREADS}" +#define CPLUSPLUS_CPP_SPEC "\ +-D_HPUX_SOURCE -D_HIUX_SOURCE -D__STDC_EXT__ \ +%{mpa-risc-1-0:%(cpp_pa10)} \ +%{mpa-risc-1-1:%(cpp_pa11)} \ +%{msnake:%(cpp_pa11)} \ +%{mpa-risc-2-0:%(cpp_pa20)} \ +%{!mpa-risc-1-0:%{!mpa-risc-1-1:%{!mpa-risc-2-0:%{!msnake:%(cpp_cpu_default)}}}} \ +%{m64bit:%(cpp_64bit)} \ +%{!m64bit:%(cpp_64bit_default)} \ +%{threads: -D_REENTRANT -D_DCE_THREADS}" + /* Defines for a K&R CC */ #define CC1_SPEC "%{pg:} %{p:}" diff --git a/gcc/config/pa/som.h b/gcc/config/pa/som.h index 9f688e9..57f69ac 100644 --- a/gcc/config/pa/som.h +++ b/gcc/config/pa/som.h @@ -127,7 +127,7 @@ do { \ fputs ("\t.NSUBSPA $CODE$,QUAD=0,ALIGN=8,ACCESS=44,CODE_ONLY\n", FILE); \ else if (TARGET_GAS) \ fprintf (FILE, \ - "\t.SUBSPA .%s\n", name); \ + "\t.SUBSPA .%.30s\n", name); \ } #define ASM_DECLARE_FUNCTION_NAME(FILE, NAME, DECL) \ @@ -270,23 +270,24 @@ do { \ if (DECL && TREE_CODE (DECL) == FUNCTION_DECL) \ { \ fputs ("\t.SPACE $TEXT$\n", FILE); \ - fprintf (FILE, \ - "\t.SUBSPA %s%s%s,QUAD=0,ALIGN=8,ACCESS=44,CODE_ONLY,SORT=24\n",\ - TARGET_GAS ? "" : "$", NAME, TARGET_GAS ? "" : "$"); \ + if (TARGET_GAS) \ + fprintf (FILE, \ + "\t.NSUBSPA %.31s,QUAD=0,ALIGN=8,ACCESS=44,CODE_ONLY,SORT=24\n", NAME);\ + else \ + fprintf (FILE, \ + "\t.NSUBSPA $%.29s$,QUAD=0,ALIGN=8,ACCESS=44,CODE_ONLY,SORT=24\n", NAME);\ } \ - else if (DECL && DECL_READONLY_SECTION (DECL, RELOC)) \ + else if (!RELOC && DECL && DECL_READONLY_SECTION (DECL, RELOC))\ { \ fputs ("\t.SPACE $TEXT$\n", FILE); \ fprintf (FILE, \ - "\t.SUBSPA %s%s%s,QUAD=0,ALIGN=8,ACCESS=44,SORT=16\n", \ - TARGET_GAS ? "" : "$", NAME, TARGET_GAS ? "" : "$"); \ + "\t.NSUBSPA $LIT$,QUAD=0,ALIGN=8,ACCESS=44,SORT=16\n");\ } \ else \ { \ fputs ("\t.SPACE $PRIVATE$\n", FILE); \ fprintf (FILE, \ - "\t.SUBSPA %s%s%s,QUAD=1,ALIGN=8,ACCESS=31,SORT=16\n", \ - TARGET_GAS ? "" : "$", NAME, TARGET_GAS ? "" : "$"); \ + "\t.NSUBSPA $DATA$,QUAD=1,ALIGN=8,ACCESS=31,SORT=16\n");\ } /* FIXME: HPUX ld generates incorrect GOT entries for "T" fixups @@ -402,3 +403,8 @@ do { \ } while (0) #endif #endif + +/* SOM does not support the init_priority C++ attribute. */ +#undef SUPPORTS_INIT_PRIORITY +#define SUPPORTS_INIT_PRIORITY 0 + -- 2.7.4