diff options
author | law <law@138bc75d-0d04-0410-961f-82ee72b054a4> | 1999-08-09 07:17:32 +0000 |
---|---|---|
committer | law <law@138bc75d-0d04-0410-961f-82ee72b054a4> | 1999-08-09 07:17:32 +0000 |
commit | edd8be624994536e7250ccb16256683b41a47380 (patch) | |
tree | 4f0aa5ad10436cc2b3783c1678911db4080c6611 /gcc/config | |
parent | 9f0588525060a5e31dcddee1137f1e4d34670b33 (diff) | |
download | gcc-edd8be624994536e7250ccb16256683b41a47380.tar.gz |
Mon Aug 9 01:15:24 1999 Jeffrey A Law (law@cygnus.com)
* pa.h (SELECT_SECTION): Define.
* som.h (SELECT_SECTION): Delete.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@28617 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/config')
-rw-r--r-- | gcc/config/pa/pa.h | 20 | ||||
-rw-r--r-- | gcc/config/pa/som.h | 20 |
2 files changed, 20 insertions, 20 deletions
diff --git a/gcc/config/pa/pa.h b/gcc/config/pa/pa.h index 7ea6bdb6009..d0bc5b2abd8 100644 --- a/gcc/config/pa/pa.h +++ b/gcc/config/pa/pa.h @@ -1586,6 +1586,26 @@ extern struct rtx_def *hppa_legitimize_address (); else \ readonly_data_section (); +/* On hpux10, the linker will give an error if we have a reference + in the read-only data section to a symbol defined in a shared + library. Therefore, expressions that might require a reloc can + not be placed in the read-only data section. */ +#define SELECT_SECTION(EXP,RELOC) \ + if (TREE_CODE (EXP) == VAR_DECL \ + && TREE_READONLY (EXP) \ + && !TREE_THIS_VOLATILE (EXP) \ + && DECL_INITIAL (EXP) \ + && (DECL_INITIAL (EXP) == error_mark_node \ + || TREE_CONSTANT (DECL_INITIAL (EXP))) \ + && !RELOC) \ + readonly_data_section (); \ + else if (TREE_CODE_CLASS (TREE_CODE (EXP)) == 'c' \ + && !(TREE_CODE (EXP) == STRING_CST && flag_writable_strings) \ + && !RELOC) \ + readonly_data_section (); \ + else \ + data_section (); + /* Define this macro if references to a symbol must be treated differently depending on something about the variable or function named by the symbol (such as what section it is in). diff --git a/gcc/config/pa/som.h b/gcc/config/pa/som.h index f9c7682d2ea..291faee9454 100644 --- a/gcc/config/pa/som.h +++ b/gcc/config/pa/som.h @@ -51,26 +51,6 @@ Boston, MA 02111-1307, USA. */ fprintf (FILE, \ "\t.stabs \"\",%d,0,0,L$text_end0000\nL$text_end0000:\n", N_SO) -/* On hpux10, the linker will give an error if we have a reference - in the read-only data section to a symbol defined in a shared - library. Therefore, expressions that might require a reloc can - not be placed in the read-only data section. */ -#define SELECT_SECTION(EXP,RELOC) \ - if (TREE_CODE (EXP) == VAR_DECL \ - && TREE_READONLY (EXP) \ - && !TREE_THIS_VOLATILE (EXP) \ - && DECL_INITIAL (EXP) \ - && (DECL_INITIAL (EXP) == error_mark_node \ - || TREE_CONSTANT (DECL_INITIAL (EXP))) \ - && !RELOC) \ - readonly_data_section (); \ - else if (TREE_CODE_CLASS (TREE_CODE (EXP)) == 'c' \ - && !(TREE_CODE (EXP) == STRING_CST && flag_writable_strings) \ - && !RELOC) \ - readonly_data_section (); \ - else \ - data_section (); - /* HPUX has a program 'chatr' to list the dependencies of dynamically linked executables and shared libraries. */ #define LDD_SUFFIX "chatr" |