diff options
author | Zack Weinberg <zack@gcc.gnu.org> | 2003-04-20 18:20:39 +0000 |
---|---|---|
committer | Zack Weinberg <zack@gcc.gnu.org> | 2003-04-20 18:20:39 +0000 |
commit | c6a2438aaf2ceeb137d21d67b00edf27a92104c0 (patch) | |
tree | 6af2bc9bef24c55c4233dbdc955842df62042749 /gcc/config/mips/mips.c | |
parent | 8c7d377fa2a94ea39f7eb38df8aeb776452f49f0 (diff) | |
download | gcc-c6a2438aaf2ceeb137d21d67b00edf27a92104c0.zip gcc-c6a2438aaf2ceeb137d21d67b00edf27a92104c0.tar.gz gcc-c6a2438aaf2ceeb137d21d67b00edf27a92104c0.tar.bz2 |
target.h (encode_section_info): Add new argument carrying the RTL to be modified by the hook.
* target.h (encode_section_info): Add new argument carrying
the RTL to be modified by the hook.
* varasm.c (make_decl_rtl, output_constant_def): Update calls
to encode_section_info.
(default_encode_section_info): Take and use RTL argument,
don't use TREE_CST_RTL or DECL_RTL.
* output.h: Update prototype of default_encode_section_info.
* config/darwin.h (ASM_DECLARE_OBJECT_NAME)
(ASM_DECLARE_FUNCTION_NAME, ASM_OUTPUT_ALIGNED_DECL_LOCAL):
Update calls to encode_section_info.
* config/darwin.c, config/arm/arm.c, config/arm/pe.c
* config/h8300/h8300.c, config/i386/winnt.c, config/m32r/m32r.c
* config/m68hc11/m68hc11.c, config/m88k/m88k.c, config/mcore/mcore.c
* config/mips/mips.c, config/mmix/mmix.c, config/pa/pa.c
* config/romp/romp.c, config/rs6000/rs6000.c, config/s390/s390.c
* config/v850/v850.c (TARGET_ENCODE_SECTION_INFO definitions):
Take and use RTL argument, don't use TREE_CST_RTL or DECL_RTL,
except for PE dllimport/dllexport. Update calls to
default_encode_section_info.
* config/darwin-protos.h, config/arm/arm-protos.h, config/i386-protos.h:
Update prototypes.
* doc/tm.texi (TARGET_ENCODE_SECTION_INFO): Update.
From-SVN: r65859
Diffstat (limited to 'gcc/config/mips/mips.c')
-rw-r--r-- | gcc/config/mips/mips.c | 21 |
1 files changed, 11 insertions, 10 deletions
diff --git a/gcc/config/mips/mips.c b/gcc/config/mips/mips.c index 5ef92f0..0c4238e 100644 --- a/gcc/config/mips/mips.c +++ b/gcc/config/mips/mips.c @@ -154,7 +154,7 @@ static void mips_unique_section PARAMS ((tree, int)) static void mips_select_rtx_section PARAMS ((enum machine_mode, rtx, unsigned HOST_WIDE_INT)); static int mips_use_dfa_pipeline_interface PARAMS ((void)); -static void mips_encode_section_info PARAMS ((tree, int)); +static void mips_encode_section_info PARAMS ((tree, rtx, int)); static bool mips_rtx_costs PARAMS ((rtx, int, int, int *)); static int mips_address_cost PARAMS ((rtx)); @@ -8521,8 +8521,9 @@ mips_select_section (decl, reloc, align) is why the DECL_INITIAL macros differ from mips_select_section. */ static void -mips_encode_section_info (decl, first) +mips_encode_section_info (decl, rtl, first) tree decl; + rtx rtl; int first; { if (TARGET_MIPS16) @@ -8545,7 +8546,7 @@ mips_encode_section_info (decl, first) { rtx symref; - symref = XEXP (TREE_CST_RTL (decl), 0); + symref = XEXP (rtl, 0); mips16_strings = alloc_EXPR_LIST (0, symref, mips16_strings); SYMBOL_REF_FLAG (symref) = 1; mips_string_length += TREE_STRING_LENGTH (decl); @@ -8558,20 +8559,20 @@ mips_encode_section_info (decl, first) && (!DECL_INITIAL (decl) || TREE_CONSTANT (DECL_INITIAL (decl)))) { - SYMBOL_REF_FLAG (XEXP (DECL_RTL (decl), 0)) = 0; + SYMBOL_REF_FLAG (XEXP (rtl, 0)) = 0; } else if (TARGET_EMBEDDED_PIC) { if (TREE_CODE (decl) == VAR_DECL) - SYMBOL_REF_FLAG (XEXP (DECL_RTL (decl), 0)) = 1; + SYMBOL_REF_FLAG (XEXP (rtl, 0)) = 1; else if (TREE_CODE (decl) == FUNCTION_DECL) - SYMBOL_REF_FLAG (XEXP (DECL_RTL (decl), 0)) = 0; + SYMBOL_REF_FLAG (XEXP (rtl, 0)) = 0; else if (TREE_CODE (decl) == STRING_CST && ! flag_writable_strings) - SYMBOL_REF_FLAG (XEXP (TREE_CST_RTL (decl), 0)) = 0; + SYMBOL_REF_FLAG (XEXP (rtl, 0)) = 0; else - SYMBOL_REF_FLAG (XEXP (TREE_CST_RTL (decl), 0)) = 1; + SYMBOL_REF_FLAG (XEXP (rtl, 0)) = 1; } else if (TREE_CODE (decl) == VAR_DECL @@ -8581,7 +8582,7 @@ mips_encode_section_info (decl, first) || 0 == strcmp (TREE_STRING_POINTER (DECL_SECTION_NAME (decl)), ".sbss"))) { - SYMBOL_REF_FLAG (XEXP (DECL_RTL (decl), 0)) = 1; + SYMBOL_REF_FLAG (XEXP (rtl, 0)) = 1; } /* We can not perform GP optimizations on variables which are in @@ -8597,7 +8598,7 @@ mips_encode_section_info (decl, first) int size = int_size_in_bytes (TREE_TYPE (decl)); if (size > 0 && size <= mips_section_threshold) - SYMBOL_REF_FLAG (XEXP (DECL_RTL (decl), 0)) = 1; + SYMBOL_REF_FLAG (XEXP (rtl, 0)) = 1; } } |