diff options
author | Alexandre Oliva <aoliva@redhat.com> | 2000-07-28 02:17:26 +0000 |
---|---|---|
committer | Alexandre Oliva <aoliva@gcc.gnu.org> | 2000-07-28 02:17:26 +0000 |
commit | 9d98a69423a0bf6d7f6c33f1f05f70c74282d65b (patch) | |
tree | ef8a8d9eb4fda8faa814cb484ce4a1e01ef25372 /gcc/config/avr/avr.c | |
parent | b87487b66a26b2db805a02e59b25bffb9438fb14 (diff) | |
download | gcc-9d98a69423a0bf6d7f6c33f1f05f70c74282d65b.zip gcc-9d98a69423a0bf6d7f6c33f1f05f70c74282d65b.tar.gz gcc-9d98a69423a0bf6d7f6c33f1f05f70c74282d65b.tar.bz2 |
Makefile.in (INSN_ATTR_H): New macro.
* Makefile.in (INSN_ATTR_H): New macro. Replace all dependencies
on insn-attr.h with it.
* genattr.c: Generate `#include "insn-addr.h"' if HAVE_ATTR_length.
* insn-addr.h: New header.
(insn_addresses_): Renamed from insn_addresses.
(INSN_ADDRESSES_DEFN, INSN_ADDRESSES, INSN_ADDRESSES_ALLOC,
INSN_ADDRESSES_FREE, INSN_ADDRESSES_SET_P, INSN_ADDRESSES_SIZE,
INSN_ADDRESSES_NEW): New macros.
* genattrtab.c (write_test_expr): Use new macros.
* final.c (insn_addresses, init_insn_lengths): Likewise.
(align_fuzz, shorten_branches): Likewise.
(final): Likewise. Do not reject new insns if their addresses
have been added to INSN_ADDRESSES.
* config/arm/arm.c, config/avr/avr.c: Use new macros.
* config/h8300/h8300.c, config/i370/i370.c: Likewise.
* config/m88k/m88k.c, config/pa/pa.c, config/pa/pa.md: Likewise.
* config/sparc/sparc.c, config/sparc/sparc.md: Likewise.
* config/sh/sh.c: Likewise.
(output_branchy_insn): Use INSN_ADDRESSES_NEW.
From-SVN: r35307
Diffstat (limited to 'gcc/config/avr/avr.c')
-rw-r--r-- | gcc/config/avr/avr.c | 23 |
1 files changed, 12 insertions, 11 deletions
diff --git a/gcc/config/avr/avr.c b/gcc/config/avr/avr.c index ac07707..14ea8a9 100644 --- a/gcc/config/avr/avr.c +++ b/gcc/config/avr/avr.c @@ -605,8 +605,8 @@ function_epilogue (FILE *file, int size) signal_func_p = signal_function_p (current_function_decl); leaf_func_p = leaf_function_p (); main_p = ! strcmp ("main", current_function_name); - function_size = (insn_addresses[INSN_UID (get_last_insn ())] - - insn_addresses[INSN_UID (get_insns ())]); + function_size = (INSN_ADDRESSES (INSN_UID (get_last_insn ())) + - INSN_ADDRESSES (INSN_UID (get_insns ()))); live_seq = sequent_regs_live (); minimize = (TARGET_CALL_PROLOGUES && !interrupt_func_p && !signal_func_p && live_seq); @@ -1089,9 +1089,9 @@ avr_jump_mode (x,insn) rtx x; /* jump operand */ rtx insn; /* jump insn */ { - int dest_addr = insn_addresses[INSN_UID (GET_MODE (x) == LABEL_REF - ? XEXP (x, 0) : x)]; - int cur_addr = insn_addresses[INSN_UID (insn)]; + int dest_addr = INSN_ADDRESSES (INSN_UID (GET_MODE (x) == LABEL_REF + ? XEXP (x, 0) : x)); + int cur_addr = INSN_ADDRESSES (INSN_UID (insn)); int jump_distance = cur_addr - dest_addr; if (-63 <= jump_distance && jump_distance <= 62) @@ -1212,11 +1212,12 @@ final_prescan_insn (insn, operand, num_operands) if (TARGET_INSN_SIZE_DUMP || TARGET_ALL_DEBUG) { - fprintf (asm_out_file, "/*DEBUG: 0x%x\t\t%d\t%d */\n", insn_addresses[uid], - insn_addresses[uid] - last_insn_address, - rtx_cost (PATTERN (insn),INSN)); + fprintf (asm_out_file, "/*DEBUG: 0x%x\t\t%d\t%d */\n", + INSN_ADDRESSES (uid), + INSN_ADDRESSES (uid) - last_insn_address, + rtx_cost (PATTERN (insn), INSN)); } - last_insn_address = insn_addresses[uid]; + last_insn_address = INSN_ADDRESSES (uid); if (TARGET_RTL_DUMP) { @@ -3999,8 +4000,8 @@ jump_over_one_insn_p (insn, dest) int uid = INSN_UID (GET_CODE (dest) == LABEL_REF ? XEXP (dest, 0) : dest); - int jump_addr = insn_addresses[INSN_UID (insn)]; - int dest_addr = insn_addresses[uid]; + int jump_addr = INSN_ADDRESSES (INSN_UID (insn)); + int dest_addr = INSN_ADDRESSES (uid); return dest_addr - jump_addr == 2; } |