Commit 7080f735 by Andreas Jaeger Committed by Andreas Jaeger

cse.c: Convert prototypes to ISO C90.

	* cse.c: Convert prototypes to ISO C90.
	* cselib.c: Likewise.
	* cselib.h: Likewise.
	* dbxout.c: Likewise.
	* debug.c: Likewise.
	* df.c: Likewise.
	* df.h: Likewise.
	* dojump.c: Likewise.
	* doloop.c: Likewise.
	* dominance.c: Likewise.
	* dwarf2asm.c: Likewise.
	* dwarf2out.c: Likewise.
	* dwarf2out.h: Likewise.
	* dwarfout.c: Likewise.

From-SVN: r68673
parent f9da5064
2003-06-29 Andreas Jaeger <aj@suse.de>
* cse.c: Convert prototypes to ISO C90.
* cselib.c: Likewise.
* cselib.h: Likewise.
* dbxout.c: Likewise.
* debug.c: Likewise.
* df.c: Likewise.
* df.h: Likewise.
* dojump.c: Likewise.
* doloop.c: Likewise.
* dominance.c: Likewise.
* dwarf2asm.c: Likewise.
* dwarf2out.c: Likewise.
* dwarf2out.h: Likewise.
* dwarfout.c: Likewise.
2003-06-29 Kazu Hirata <kazu@cs.umass.edu> 2003-06-29 Kazu Hirata <kazu@cs.umass.edu>
* alloc-pool.c: Fix comment formatting. * alloc-pool.c: Fix comment formatting.
......
...@@ -596,76 +596,74 @@ struct cse_basic_block_data ...@@ -596,76 +596,74 @@ struct cse_basic_block_data
} *path; } *path;
}; };
static bool fixed_base_plus_p PARAMS ((rtx x)); static bool fixed_base_plus_p (rtx x);
static int notreg_cost PARAMS ((rtx, enum rtx_code)); static int notreg_cost (rtx, enum rtx_code);
static int approx_reg_cost_1 PARAMS ((rtx *, void *)); static int approx_reg_cost_1 (rtx *, void *);
static int approx_reg_cost PARAMS ((rtx)); static int approx_reg_cost (rtx);
static int preferrable PARAMS ((int, int, int, int)); static int preferrable (int, int, int, int);
static void new_basic_block PARAMS ((void)); static void new_basic_block (void);
static void make_new_qty PARAMS ((unsigned int, enum machine_mode)); static void make_new_qty (unsigned int, enum machine_mode);
static void make_regs_eqv PARAMS ((unsigned int, unsigned int)); static void make_regs_eqv (unsigned int, unsigned int);
static void delete_reg_equiv PARAMS ((unsigned int)); static void delete_reg_equiv (unsigned int);
static int mention_regs PARAMS ((rtx)); static int mention_regs (rtx);
static int insert_regs PARAMS ((rtx, struct table_elt *, int)); static int insert_regs (rtx, struct table_elt *, int);
static void remove_from_table PARAMS ((struct table_elt *, unsigned)); static void remove_from_table (struct table_elt *, unsigned);
static struct table_elt *lookup PARAMS ((rtx, unsigned, enum machine_mode)), static struct table_elt *lookup (rtx, unsigned, enum machine_mode);
*lookup_for_remove PARAMS ((rtx, unsigned, enum machine_mode)); static struct table_elt *lookup_for_remove (rtx, unsigned, enum machine_mode);
static rtx lookup_as_function PARAMS ((rtx, enum rtx_code)); static rtx lookup_as_function (rtx, enum rtx_code);
static struct table_elt *insert PARAMS ((rtx, struct table_elt *, unsigned, static struct table_elt *insert (rtx, struct table_elt *, unsigned,
enum machine_mode)); enum machine_mode);
static void merge_equiv_classes PARAMS ((struct table_elt *, static void merge_equiv_classes (struct table_elt *, struct table_elt *);
struct table_elt *)); static void invalidate (rtx, enum machine_mode);
static void invalidate PARAMS ((rtx, enum machine_mode)); static int cse_rtx_varies_p (rtx, int);
static int cse_rtx_varies_p PARAMS ((rtx, int)); static void remove_invalid_refs (unsigned int);
static void remove_invalid_refs PARAMS ((unsigned int)); static void remove_invalid_subreg_refs (unsigned int, unsigned int,
static void remove_invalid_subreg_refs PARAMS ((unsigned int, unsigned int, enum machine_mode);
enum machine_mode)); static void rehash_using_reg (rtx);
static void rehash_using_reg PARAMS ((rtx)); static void invalidate_memory (void);
static void invalidate_memory PARAMS ((void)); static void invalidate_for_call (void);
static void invalidate_for_call PARAMS ((void)); static rtx use_related_value (rtx, struct table_elt *);
static rtx use_related_value PARAMS ((rtx, struct table_elt *)); static unsigned canon_hash (rtx, enum machine_mode);
static unsigned canon_hash PARAMS ((rtx, enum machine_mode)); static unsigned canon_hash_string (const char *);
static unsigned canon_hash_string PARAMS ((const char *)); static unsigned safe_hash (rtx, enum machine_mode);
static unsigned safe_hash PARAMS ((rtx, enum machine_mode)); static int exp_equiv_p (rtx, rtx, int, int);
static int exp_equiv_p PARAMS ((rtx, rtx, int, int)); static rtx canon_reg (rtx, rtx);
static rtx canon_reg PARAMS ((rtx, rtx)); static void find_best_addr (rtx, rtx *, enum machine_mode);
static void find_best_addr PARAMS ((rtx, rtx *, enum machine_mode)); static enum rtx_code find_comparison_args (enum rtx_code, rtx *, rtx *,
static enum rtx_code find_comparison_args PARAMS ((enum rtx_code, rtx *, rtx *,
enum machine_mode *, enum machine_mode *,
enum machine_mode *)); enum machine_mode *);
static rtx fold_rtx PARAMS ((rtx, rtx)); static rtx fold_rtx (rtx, rtx);
static rtx equiv_constant PARAMS ((rtx)); static rtx equiv_constant (rtx);
static void record_jump_equiv PARAMS ((rtx, int)); static void record_jump_equiv (rtx, int);
static void record_jump_cond PARAMS ((enum rtx_code, enum machine_mode, static void record_jump_cond (enum rtx_code, enum machine_mode, rtx, rtx,
rtx, rtx, int)); int);
static void cse_insn PARAMS ((rtx, rtx)); static void cse_insn (rtx, rtx);
static int addr_affects_sp_p PARAMS ((rtx)); static int addr_affects_sp_p (rtx);
static void invalidate_from_clobbers PARAMS ((rtx)); static void invalidate_from_clobbers (rtx);
static rtx cse_process_notes PARAMS ((rtx, rtx)); static rtx cse_process_notes (rtx, rtx);
static void cse_around_loop PARAMS ((rtx)); static void cse_around_loop (rtx);
static void invalidate_skipped_set PARAMS ((rtx, rtx, void *)); static void invalidate_skipped_set (rtx, rtx, void *);
static void invalidate_skipped_block PARAMS ((rtx)); static void invalidate_skipped_block (rtx);
static void cse_check_loop_start PARAMS ((rtx, rtx, void *)); static void cse_check_loop_start (rtx, rtx, void *);
static void cse_set_around_loop PARAMS ((rtx, rtx, rtx)); static void cse_set_around_loop (rtx, rtx, rtx);
static rtx cse_basic_block PARAMS ((rtx, rtx, struct branch_path *, int)); static rtx cse_basic_block (rtx, rtx, struct branch_path *, int);
static void count_reg_usage PARAMS ((rtx, int *, rtx, int)); static void count_reg_usage (rtx, int *, rtx, int);
static int check_for_label_ref PARAMS ((rtx *, void *)); static int check_for_label_ref (rtx *, void *);
extern void dump_class PARAMS ((struct table_elt*)); extern void dump_class (struct table_elt*);
static struct cse_reg_info * get_cse_reg_info PARAMS ((unsigned int)); static struct cse_reg_info * get_cse_reg_info (unsigned int);
static int check_dependence PARAMS ((rtx *, void *)); static int check_dependence (rtx *, void *);
static void flush_hash_table PARAMS ((void)); static void flush_hash_table (void);
static bool insn_live_p PARAMS ((rtx, int *)); static bool insn_live_p (rtx, int *);
static bool set_live_p PARAMS ((rtx, rtx, int *)); static bool set_live_p (rtx, rtx, int *);
static bool dead_libcall_p PARAMS ((rtx, int *)); static bool dead_libcall_p (rtx, int *);
/* Nonzero if X has the form (PLUS frame-pointer integer). We check for /* Nonzero if X has the form (PLUS frame-pointer integer). We check for
virtual regs here because the simplify_*_operation routines are called virtual regs here because the simplify_*_operation routines are called
by integrate.c, which is called before virtual register instantiation. */ by integrate.c, which is called before virtual register instantiation. */
static bool static bool
fixed_base_plus_p (x) fixed_base_plus_p (rtx x)
rtx x;
{ {
switch (GET_CODE (x)) switch (GET_CODE (x))
{ {
...@@ -695,8 +693,7 @@ fixed_base_plus_p (x) ...@@ -695,8 +693,7 @@ fixed_base_plus_p (x)
/* Dump the expressions in the equivalence class indicated by CLASSP. /* Dump the expressions in the equivalence class indicated by CLASSP.
This function is used only for debugging. */ This function is used only for debugging. */
void void
dump_class (classp) dump_class (struct table_elt *classp)
struct table_elt *classp;
{ {
struct table_elt *elt; struct table_elt *elt;
...@@ -714,9 +711,7 @@ dump_class (classp) ...@@ -714,9 +711,7 @@ dump_class (classp)
/* Subroutine of approx_reg_cost; called through for_each_rtx. */ /* Subroutine of approx_reg_cost; called through for_each_rtx. */
static int static int
approx_reg_cost_1 (xp, data) approx_reg_cost_1 (rtx *xp, void *data)
rtx *xp;
void *data;
{ {
rtx x = *xp; rtx x = *xp;
int *cost_p = data; int *cost_p = data;
...@@ -747,8 +742,7 @@ approx_reg_cost_1 (xp, data) ...@@ -747,8 +742,7 @@ approx_reg_cost_1 (xp, data)
0. If any other hard register reference occurs, return MAX_COST. */ 0. If any other hard register reference occurs, return MAX_COST. */
static int static int
approx_reg_cost (x) approx_reg_cost (rtx x)
rtx x;
{ {
int cost = 0; int cost = 0;
...@@ -763,8 +757,7 @@ approx_reg_cost (x) ...@@ -763,8 +757,7 @@ approx_reg_cost (x)
Return a positive value if A is less desirable, or 0 if the two are Return a positive value if A is less desirable, or 0 if the two are
equally good. */ equally good. */
static int static int
preferrable (cost_a, regcost_a, cost_b, regcost_b) preferrable (int cost_a, int regcost_a, int cost_b, int regcost_b)
int cost_a, regcost_a, cost_b, regcost_b;
{ {
/* First, get rid of cases involving expressions that are entirely /* First, get rid of cases involving expressions that are entirely
unwanted. */ unwanted. */
...@@ -798,9 +791,7 @@ preferrable (cost_a, regcost_a, cost_b, regcost_b) ...@@ -798,9 +791,7 @@ preferrable (cost_a, regcost_a, cost_b, regcost_b)
from COST macro to keep it simple. */ from COST macro to keep it simple. */
static int static int
notreg_cost (x, outer) notreg_cost (rtx x, enum rtx_code outer)
rtx x;
enum rtx_code outer;
{ {
return ((GET_CODE (x) == SUBREG return ((GET_CODE (x) == SUBREG
&& GET_CODE (SUBREG_REG (x)) == REG && GET_CODE (SUBREG_REG (x)) == REG
...@@ -821,9 +812,7 @@ notreg_cost (x, outer) ...@@ -821,9 +812,7 @@ notreg_cost (x, outer)
Other uses like the latter are expected in the future. */ Other uses like the latter are expected in the future. */
int int
rtx_cost (x, outer_code) rtx_cost (rtx x, enum rtx_code outer_code ATTRIBUTE_UNUSED)
rtx x;
enum rtx_code outer_code ATTRIBUTE_UNUSED;
{ {
int i, j; int i, j;
enum rtx_code code; enum rtx_code code;
...@@ -893,9 +882,7 @@ rtx_cost (x, outer_code) ...@@ -893,9 +882,7 @@ rtx_cost (x, outer_code)
Expect that X is properly formed address reference. */ Expect that X is properly formed address reference. */
int int
address_cost (x, mode) address_cost (rtx x, enum machine_mode mode)
rtx x;
enum machine_mode mode;
{ {
/* The address_cost target hook does not deal with ADDRESSOF nodes. But, /* The address_cost target hook does not deal with ADDRESSOF nodes. But,
during CSE, such nodes are present. Using an ADDRESSOF node which during CSE, such nodes are present. Using an ADDRESSOF node which
...@@ -918,15 +905,13 @@ address_cost (x, mode) ...@@ -918,15 +905,13 @@ address_cost (x, mode)
/* If the target doesn't override, compute the cost as with arithmetic. */ /* If the target doesn't override, compute the cost as with arithmetic. */
int int
default_address_cost (x) default_address_cost (rtx x)
rtx x;
{ {
return rtx_cost (x, MEM); return rtx_cost (x, MEM);
} }
static struct cse_reg_info * static struct cse_reg_info *
get_cse_reg_info (regno) get_cse_reg_info (unsigned int regno)
unsigned int regno;
{ {
struct cse_reg_info **hash_head = &reg_hash[REGHASH_FN (regno)]; struct cse_reg_info **hash_head = &reg_hash[REGHASH_FN (regno)];
struct cse_reg_info *p; struct cse_reg_info *p;
...@@ -974,7 +959,7 @@ get_cse_reg_info (regno) ...@@ -974,7 +959,7 @@ get_cse_reg_info (regno)
for a new basic block. */ for a new basic block. */
static void static void
new_basic_block () new_basic_block (void)
{ {
int i; int i;
...@@ -1029,9 +1014,7 @@ new_basic_block () ...@@ -1029,9 +1014,7 @@ new_basic_block ()
register before and initialize that quantity. */ register before and initialize that quantity. */
static void static void
make_new_qty (reg, mode) make_new_qty (unsigned int reg, enum machine_mode mode)
unsigned int reg;
enum machine_mode mode;
{ {
int q; int q;
struct qty_table_elem *ent; struct qty_table_elem *ent;
...@@ -1056,8 +1039,7 @@ make_new_qty (reg, mode) ...@@ -1056,8 +1039,7 @@ make_new_qty (reg, mode)
OLD is not changing; NEW is. */ OLD is not changing; NEW is. */
static void static void
make_regs_eqv (new, old) make_regs_eqv (unsigned int new, unsigned int old)
unsigned int new, old;
{ {
unsigned int lastr, firstr; unsigned int lastr, firstr;
int q = REG_QTY (old); int q = REG_QTY (old);
...@@ -1120,8 +1102,7 @@ make_regs_eqv (new, old) ...@@ -1120,8 +1102,7 @@ make_regs_eqv (new, old)
/* Remove REG from its equivalence class. */ /* Remove REG from its equivalence class. */
static void static void
delete_reg_equiv (reg) delete_reg_equiv (unsigned int reg)
unsigned int reg;
{ {
struct qty_table_elem *ent; struct qty_table_elem *ent;
int q = REG_QTY (reg); int q = REG_QTY (reg);
...@@ -1161,8 +1142,7 @@ delete_reg_equiv (reg) ...@@ -1161,8 +1142,7 @@ delete_reg_equiv (reg)
of X. */ of X. */
static int static int
mention_regs (x) mention_regs (rtx x)
rtx x;
{ {
enum rtx_code code; enum rtx_code code;
int i, j; int i, j;
...@@ -1271,10 +1251,7 @@ mention_regs (x) ...@@ -1271,10 +1251,7 @@ mention_regs (x)
so X's hash code may be different. */ so X's hash code may be different. */
static int static int
insert_regs (x, classp, modified) insert_regs (rtx x, struct table_elt *classp, int modified)
rtx x;
struct table_elt *classp;
int modified;
{ {
if (GET_CODE (x) == REG) if (GET_CODE (x) == REG)
{ {
...@@ -1351,9 +1328,7 @@ insert_regs (x, classp, modified) ...@@ -1351,9 +1328,7 @@ insert_regs (x, classp, modified)
and we save much time not recomputing it. */ and we save much time not recomputing it. */
static void static void
remove_from_table (elt, hash) remove_from_table (struct table_elt *elt, unsigned int hash)
struct table_elt *elt;
unsigned hash;
{ {
if (elt == 0) if (elt == 0)
return; return;
...@@ -1436,10 +1411,7 @@ remove_from_table (elt, hash) ...@@ -1436,10 +1411,7 @@ remove_from_table (elt, hash)
looks like X. */ looks like X. */
static struct table_elt * static struct table_elt *
lookup (x, hash, mode) lookup (rtx x, unsigned int hash, enum machine_mode mode)
rtx x;
unsigned hash;
enum machine_mode mode;
{ {
struct table_elt *p; struct table_elt *p;
...@@ -1455,10 +1427,7 @@ lookup (x, hash, mode) ...@@ -1455,10 +1427,7 @@ lookup (x, hash, mode)
Also ignore discrepancies in the machine mode of a register. */ Also ignore discrepancies in the machine mode of a register. */
static struct table_elt * static struct table_elt *
lookup_for_remove (x, hash, mode) lookup_for_remove (rtx x, unsigned int hash, enum machine_mode mode)
rtx x;
unsigned hash;
enum machine_mode mode;
{ {
struct table_elt *p; struct table_elt *p;
...@@ -1487,9 +1456,7 @@ lookup_for_remove (x, hash, mode) ...@@ -1487,9 +1456,7 @@ lookup_for_remove (x, hash, mode)
If one is found, return that expression. */ If one is found, return that expression. */
static rtx static rtx
lookup_as_function (x, code) lookup_as_function (rtx x, enum rtx_code code)
rtx x;
enum rtx_code code;
{ {
struct table_elt *p struct table_elt *p
= lookup (x, safe_hash (x, VOIDmode) & HASH_MASK, GET_MODE (x)); = lookup (x, safe_hash (x, VOIDmode) & HASH_MASK, GET_MODE (x));
...@@ -1545,11 +1512,7 @@ lookup_as_function (x, code) ...@@ -1545,11 +1512,7 @@ lookup_as_function (x, code)
(preferrable ((X)->cost, (X)->regcost, (Y)->cost, (Y)->regcost) < 0) (preferrable ((X)->cost, (X)->regcost, (Y)->cost, (Y)->regcost) < 0)
static struct table_elt * static struct table_elt *
insert (x, classp, hash, mode) insert (rtx x, struct table_elt *classp, unsigned int hash, enum machine_mode mode)
rtx x;
struct table_elt *classp;
unsigned hash;
enum machine_mode mode;
{ {
struct table_elt *elt; struct table_elt *elt;
...@@ -1735,8 +1698,7 @@ insert (x, classp, hash, mode) ...@@ -1735,8 +1698,7 @@ insert (x, classp, hash, mode)
Any invalid entries in CLASS2 will not be copied. */ Any invalid entries in CLASS2 will not be copied. */
static void static void
merge_equiv_classes (class1, class2) merge_equiv_classes (struct table_elt *class1, struct table_elt *class2)
struct table_elt *class1, *class2;
{ {
struct table_elt *elt, *next, *new; struct table_elt *elt, *next, *new;
...@@ -1783,7 +1745,7 @@ merge_equiv_classes (class1, class2) ...@@ -1783,7 +1745,7 @@ merge_equiv_classes (class1, class2)
/* Flush the entire hash table. */ /* Flush the entire hash table. */
static void static void
flush_hash_table () flush_hash_table (void)
{ {
int i; int i;
struct table_elt *p; struct table_elt *p;
...@@ -1808,9 +1770,7 @@ struct check_dependence_data ...@@ -1808,9 +1770,7 @@ struct check_dependence_data
}; };
static int static int
check_dependence (x, data) check_dependence (rtx *x, void *data)
rtx *x;
void *data;
{ {
struct check_dependence_data *d = (struct check_dependence_data *) data; struct check_dependence_data *d = (struct check_dependence_data *) data;
if (*x && GET_CODE (*x) == MEM) if (*x && GET_CODE (*x) == MEM)
...@@ -1832,9 +1792,7 @@ check_dependence (x, data) ...@@ -1832,9 +1792,7 @@ check_dependence (x, data)
or it may be either of those plus a numeric offset. */ or it may be either of those plus a numeric offset. */
static void static void
invalidate (x, full_mode) invalidate (rtx x, enum machine_mode full_mode)
rtx x;
enum machine_mode full_mode;
{ {
int i; int i;
struct table_elt *p; struct table_elt *p;
...@@ -1974,8 +1932,7 @@ invalidate (x, full_mode) ...@@ -1974,8 +1932,7 @@ invalidate (x, full_mode)
expressions to reappear as valid. */ expressions to reappear as valid. */
static void static void
remove_invalid_refs (regno) remove_invalid_refs (unsigned int regno)
unsigned int regno;
{ {
unsigned int i; unsigned int i;
struct table_elt *p, *next; struct table_elt *p, *next;
...@@ -1993,10 +1950,8 @@ remove_invalid_refs (regno) ...@@ -1993,10 +1950,8 @@ remove_invalid_refs (regno)
/* Likewise for a subreg with subreg_reg REGNO, subreg_byte OFFSET, /* Likewise for a subreg with subreg_reg REGNO, subreg_byte OFFSET,
and mode MODE. */ and mode MODE. */
static void static void
remove_invalid_subreg_refs (regno, offset, mode) remove_invalid_subreg_refs (unsigned int regno, unsigned int offset,
unsigned int regno; enum machine_mode mode)
unsigned int offset;
enum machine_mode mode;
{ {
unsigned int i; unsigned int i;
struct table_elt *p, *next; struct table_elt *p, *next;
...@@ -2026,8 +1981,7 @@ remove_invalid_subreg_refs (regno, offset, mode) ...@@ -2026,8 +1981,7 @@ remove_invalid_subreg_refs (regno, offset, mode)
This is called when we make a jump equivalence. */ This is called when we make a jump equivalence. */
static void static void
rehash_using_reg (x) rehash_using_reg (rtx x)
rtx x;
{ {
unsigned int i; unsigned int i;
struct table_elt *p, *next; struct table_elt *p, *next;
...@@ -2077,7 +2031,7 @@ rehash_using_reg (x) ...@@ -2077,7 +2031,7 @@ rehash_using_reg (x)
register. Also update their TICK values. */ register. Also update their TICK values. */
static void static void
invalidate_for_call () invalidate_for_call (void)
{ {
unsigned int regno, endregno; unsigned int regno, endregno;
unsigned int i; unsigned int i;
...@@ -2136,9 +2090,7 @@ invalidate_for_call () ...@@ -2136,9 +2090,7 @@ invalidate_for_call ()
If none can be found, return 0. */ If none can be found, return 0. */
static rtx static rtx
use_related_value (x, elt) use_related_value (rtx x, struct table_elt *elt)
rtx x;
struct table_elt *elt;
{ {
struct table_elt *relt = 0; struct table_elt *relt = 0;
struct table_elt *p, *q; struct table_elt *p, *q;
...@@ -2206,8 +2158,7 @@ use_related_value (x, elt) ...@@ -2206,8 +2158,7 @@ use_related_value (x, elt)
/* Hash a string. Just add its bytes up. */ /* Hash a string. Just add its bytes up. */
static inline unsigned static inline unsigned
canon_hash_string (ps) canon_hash_string (const char *ps)
const char *ps;
{ {
unsigned hash = 0; unsigned hash = 0;
const unsigned char *p = (const unsigned char *) ps; const unsigned char *p = (const unsigned char *) ps;
...@@ -2233,9 +2184,7 @@ canon_hash_string (ps) ...@@ -2233,9 +2184,7 @@ canon_hash_string (ps)
is just (int) MEM plus the hash code of the address. */ is just (int) MEM plus the hash code of the address. */
static unsigned static unsigned
canon_hash (x, mode) canon_hash (rtx x, enum machine_mode mode)
rtx x;
enum machine_mode mode;
{ {
int i, j; int i, j;
unsigned hash = 0; unsigned hash = 0;
...@@ -2487,9 +2436,7 @@ canon_hash (x, mode) ...@@ -2487,9 +2436,7 @@ canon_hash (x, mode)
/* Like canon_hash but with no side effects. */ /* Like canon_hash but with no side effects. */
static unsigned static unsigned
safe_hash (x, mode) safe_hash (rtx x, enum machine_mode mode)
rtx x;
enum machine_mode mode;
{ {
int save_do_not_record = do_not_record; int save_do_not_record = do_not_record;
int save_hash_arg_in_memory = hash_arg_in_memory; int save_hash_arg_in_memory = hash_arg_in_memory;
...@@ -2515,10 +2462,7 @@ safe_hash (x, mode) ...@@ -2515,10 +2462,7 @@ safe_hash (x, mode)
is the same as that of the given value is pure luck. */ is the same as that of the given value is pure luck. */
static int static int
exp_equiv_p (x, y, validate, equal_values) exp_equiv_p (rtx x, rtx y, int validate, int equal_values)
rtx x, y;
int validate;
int equal_values;
{ {
int i, j; int i, j;
enum rtx_code code; enum rtx_code code;
...@@ -2710,9 +2654,7 @@ exp_equiv_p (x, y, validate, equal_values) ...@@ -2710,9 +2654,7 @@ exp_equiv_p (x, y, validate, equal_values)
against certain constants or near-constants. */ against certain constants or near-constants. */
static int static int
cse_rtx_varies_p (x, from_alias) cse_rtx_varies_p (rtx x, int from_alias)
rtx x;
int from_alias;
{ {
/* We need not check for X and the equivalence class being of the same /* We need not check for X and the equivalence class being of the same
mode because if X is equivalent to a constant in some mode, it mode because if X is equivalent to a constant in some mode, it
...@@ -2780,9 +2722,7 @@ cse_rtx_varies_p (x, from_alias) ...@@ -2780,9 +2722,7 @@ cse_rtx_varies_p (x, from_alias)
generally be discarded since the changes we are making are optional. */ generally be discarded since the changes we are making are optional. */
static rtx static rtx
canon_reg (x, insn) canon_reg (rtx x, rtx insn)
rtx x;
rtx insn;
{ {
int i; int i;
enum rtx_code code; enum rtx_code code;
...@@ -2879,10 +2819,7 @@ canon_reg (x, insn) ...@@ -2879,10 +2819,7 @@ canon_reg (x, insn)
hard registers here because we would also prefer the pseudo registers. */ hard registers here because we would also prefer the pseudo registers. */
static void static void
find_best_addr (insn, loc, mode) find_best_addr (rtx insn, rtx *loc, enum machine_mode mode)
rtx insn;
rtx *loc;
enum machine_mode mode;
{ {
struct table_elt *elt; struct table_elt *elt;
rtx addr = *loc; rtx addr = *loc;
...@@ -3095,10 +3032,8 @@ find_best_addr (insn, loc, mode) ...@@ -3095,10 +3032,8 @@ find_best_addr (insn, loc, mode)
A or the code corresponding to the inverse of the comparison. */ A or the code corresponding to the inverse of the comparison. */
static enum rtx_code static enum rtx_code
find_comparison_args (code, parg1, parg2, pmode1, pmode2) find_comparison_args (enum rtx_code code, rtx *parg1, rtx *parg2,
enum rtx_code code; enum machine_mode *pmode1, enum machine_mode *pmode2)
rtx *parg1, *parg2;
enum machine_mode *pmode1, *pmode2;
{ {
rtx arg1, arg2; rtx arg1, arg2;
...@@ -3293,9 +3228,7 @@ find_comparison_args (code, parg1, parg2, pmode1, pmode2) ...@@ -3293,9 +3228,7 @@ find_comparison_args (code, parg1, parg2, pmode1, pmode2)
of X before modifying it. */ of X before modifying it. */
static rtx static rtx
fold_rtx (x, insn) fold_rtx (rtx x, rtx insn)
rtx x;
rtx insn;
{ {
enum rtx_code code; enum rtx_code code;
enum machine_mode mode; enum machine_mode mode;
...@@ -4323,8 +4256,7 @@ fold_rtx (x, insn) ...@@ -4323,8 +4256,7 @@ fold_rtx (x, insn)
Return 0 if we don't know one. */ Return 0 if we don't know one. */
static rtx static rtx
equiv_constant (x) equiv_constant (rtx x)
rtx x;
{ {
if (GET_CODE (x) == REG if (GET_CODE (x) == REG
&& REGNO_QTY_VALID_P (REGNO (x))) && REGNO_QTY_VALID_P (REGNO (x)))
...@@ -4374,9 +4306,7 @@ equiv_constant (x) ...@@ -4374,9 +4306,7 @@ equiv_constant (x)
This is similar to gen_lowpart in emit-rtl.c. */ This is similar to gen_lowpart in emit-rtl.c. */
rtx rtx
gen_lowpart_if_possible (mode, x) gen_lowpart_if_possible (enum machine_mode mode, rtx x)
enum machine_mode mode;
rtx x;
{ {
rtx result = gen_lowpart_common (mode, x); rtx result = gen_lowpart_common (mode, x);
...@@ -4419,9 +4349,7 @@ gen_lowpart_if_possible (mode, x) ...@@ -4419,9 +4349,7 @@ gen_lowpart_if_possible (mode, x)
comparison is seen later, we will know its value. */ comparison is seen later, we will know its value. */
static void static void
record_jump_equiv (insn, taken) record_jump_equiv (rtx insn, int taken)
rtx insn;
int taken;
{ {
int cond_known_true; int cond_known_true;
rtx op0, op1; rtx op0, op1;
...@@ -4472,11 +4400,8 @@ record_jump_equiv (insn, taken) ...@@ -4472,11 +4400,8 @@ record_jump_equiv (insn, taken)
above function and called recursively. */ above function and called recursively. */
static void static void
record_jump_cond (code, mode, op0, op1, reversed_nonequality) record_jump_cond (enum rtx_code code, enum machine_mode mode, rtx op0,
enum rtx_code code; rtx op1, int reversed_nonequality)
enum machine_mode mode;
rtx op0, op1;
int reversed_nonequality;
{ {
unsigned op0_hash, op1_hash; unsigned op0_hash, op1_hash;
int op0_in_memory, op1_in_memory; int op0_in_memory, op1_in_memory;
...@@ -4727,9 +4652,7 @@ struct set ...@@ -4727,9 +4652,7 @@ struct set
}; };
static void static void
cse_insn (insn, libcall_insn) cse_insn (rtx insn, rtx libcall_insn)
rtx insn;
rtx libcall_insn;
{ {
rtx x = PATTERN (insn); rtx x = PATTERN (insn);
int i; int i;
...@@ -6370,7 +6293,7 @@ cse_insn (insn, libcall_insn) ...@@ -6370,7 +6293,7 @@ cse_insn (insn, libcall_insn)
/* Remove from the hash table all expressions that reference memory. */ /* Remove from the hash table all expressions that reference memory. */
static void static void
invalidate_memory () invalidate_memory (void)
{ {
int i; int i;
struct table_elt *p, *next; struct table_elt *p, *next;
...@@ -6388,8 +6311,7 @@ invalidate_memory () ...@@ -6388,8 +6311,7 @@ invalidate_memory ()
1 and update the register tables to show the effect. Else, return 0. */ 1 and update the register tables to show the effect. Else, return 0. */
static int static int
addr_affects_sp_p (addr) addr_affects_sp_p (rtx addr)
rtx addr;
{ {
if (GET_RTX_CLASS (GET_CODE (addr)) == 'a' if (GET_RTX_CLASS (GET_CODE (addr)) == 'a'
&& GET_CODE (XEXP (addr, 0)) == REG && GET_CODE (XEXP (addr, 0)) == REG
...@@ -6420,8 +6342,7 @@ addr_affects_sp_p (addr) ...@@ -6420,8 +6342,7 @@ addr_affects_sp_p (addr)
X is the pattern of the insn. */ X is the pattern of the insn. */
static void static void
invalidate_from_clobbers (x) invalidate_from_clobbers (rtx x)
rtx x;
{ {
if (GET_CODE (x) == CLOBBER) if (GET_CODE (x) == CLOBBER)
{ {
...@@ -6466,9 +6387,7 @@ invalidate_from_clobbers (x) ...@@ -6466,9 +6387,7 @@ invalidate_from_clobbers (x)
Return the replacement for X. */ Return the replacement for X. */
static rtx static rtx
cse_process_notes (x, object) cse_process_notes (rtx x, rtx object)
rtx x;
rtx object;
{ {
enum rtx_code code = GET_CODE (x); enum rtx_code code = GET_CODE (x);
const char *fmt = GET_RTX_FORMAT (code); const char *fmt = GET_RTX_FORMAT (code);
...@@ -6560,8 +6479,7 @@ cse_process_notes (x, object) ...@@ -6560,8 +6479,7 @@ cse_process_notes (x, object)
jumps to a label used only once. */ jumps to a label used only once. */
static void static void
cse_around_loop (loop_start) cse_around_loop (rtx loop_start)
rtx loop_start;
{ {
rtx insn; rtx insn;
int i; int i;
...@@ -6632,10 +6550,7 @@ cse_around_loop (loop_start) ...@@ -6632,10 +6550,7 @@ cse_around_loop (loop_start)
since they are done elsewhere. This function is called via note_stores. */ since they are done elsewhere. This function is called via note_stores. */
static void static void
invalidate_skipped_set (dest, set, data) invalidate_skipped_set (rtx dest, rtx set, void *data ATTRIBUTE_UNUSED)
rtx set;
rtx dest;
void *data ATTRIBUTE_UNUSED;
{ {
enum rtx_code code = GET_CODE (dest); enum rtx_code code = GET_CODE (dest);
...@@ -6669,8 +6584,7 @@ invalidate_skipped_set (dest, set, data) ...@@ -6669,8 +6584,7 @@ invalidate_skipped_set (dest, set, data)
conditionally executed. */ conditionally executed. */
static void static void
invalidate_skipped_block (start) invalidate_skipped_block (rtx start)
rtx start;
{ {
rtx insn; rtx insn;
...@@ -6697,10 +6611,7 @@ invalidate_skipped_block (start) ...@@ -6697,10 +6611,7 @@ invalidate_skipped_block (start)
NULL_RTX. */ NULL_RTX. */
static void static void
cse_check_loop_start (x, set, data) cse_check_loop_start (rtx x, rtx set ATTRIBUTE_UNUSED, void *data)
rtx x;
rtx set ATTRIBUTE_UNUSED;
void *data;
{ {
rtx *cse_check_loop_start_value = (rtx *) data; rtx *cse_check_loop_start_value = (rtx *) data;
...@@ -6731,10 +6642,7 @@ cse_check_loop_start (x, set, data) ...@@ -6731,10 +6642,7 @@ cse_check_loop_start (x, set, data)
In any event, we invalidate whatever this SET or CLOBBER modifies. */ In any event, we invalidate whatever this SET or CLOBBER modifies. */
static void static void
cse_set_around_loop (x, insn, loop_start) cse_set_around_loop (rtx x, rtx insn, rtx loop_start)
rtx x;
rtx insn;
rtx loop_start;
{ {
struct table_elt *src_elt; struct table_elt *src_elt;
...@@ -6841,12 +6749,8 @@ cse_set_around_loop (x, insn, loop_start) ...@@ -6841,12 +6749,8 @@ cse_set_around_loop (x, insn, loop_start)
to construct the output branch path. */ to construct the output branch path. */
void void
cse_end_of_basic_block (insn, data, follow_jumps, after_loop, skip_blocks) cse_end_of_basic_block (rtx insn, struct cse_basic_block_data *data,
rtx insn; int follow_jumps, int after_loop, int skip_blocks)
struct cse_basic_block_data *data;
int follow_jumps;
int after_loop;
int skip_blocks;
{ {
rtx p = insn, q; rtx p = insn, q;
int nsets = 0; int nsets = 0;
...@@ -7063,11 +6967,7 @@ cse_end_of_basic_block (insn, data, follow_jumps, after_loop, skip_blocks) ...@@ -7063,11 +6967,7 @@ cse_end_of_basic_block (insn, data, follow_jumps, after_loop, skip_blocks)
in conditional jump instructions. */ in conditional jump instructions. */
int int
cse_main (f, nregs, after_loop, file) cse_main (rtx f, int nregs, int after_loop, FILE *file)
rtx f;
int nregs;
int after_loop;
FILE *file;
{ {
struct cse_basic_block_data val; struct cse_basic_block_data val;
rtx insn = f; rtx insn = f;
...@@ -7213,10 +7113,8 @@ cse_main (f, nregs, after_loop, file) ...@@ -7213,10 +7113,8 @@ cse_main (f, nregs, after_loop, file)
block and this CSE pass is before loop.c. */ block and this CSE pass is before loop.c. */
static rtx static rtx
cse_basic_block (from, to, next_branch, around_loop) cse_basic_block (rtx from, rtx to, struct branch_path *next_branch,
rtx from, to; int around_loop)
struct branch_path *next_branch;
int around_loop;
{ {
rtx insn; rtx insn;
int to_usage = 0; int to_usage = 0;
...@@ -7429,9 +7327,7 @@ cse_basic_block (from, to, next_branch, around_loop) ...@@ -7429,9 +7327,7 @@ cse_basic_block (from, to, next_branch, around_loop)
there isn't a REG_LABEL note. Return one if so. DATA is the insn. */ there isn't a REG_LABEL note. Return one if so. DATA is the insn. */
static int static int
check_for_label_ref (rtl, data) check_for_label_ref (rtx *rtl, void *data)
rtx *rtl;
void *data;
{ {
rtx insn = (rtx) data; rtx insn = (rtx) data;
...@@ -7455,11 +7351,7 @@ check_for_label_ref (rtl, data) ...@@ -7455,11 +7351,7 @@ check_for_label_ref (rtl, data)
modify the liveness of DEST. */ modify the liveness of DEST. */
static void static void
count_reg_usage (x, counts, dest, incr) count_reg_usage (rtx x, int *counts, rtx dest, int incr)
rtx x;
int *counts;
rtx dest;
int incr;
{ {
enum rtx_code code; enum rtx_code code;
rtx note; rtx note;
...@@ -7563,10 +7455,8 @@ count_reg_usage (x, counts, dest, incr) ...@@ -7563,10 +7455,8 @@ count_reg_usage (x, counts, dest, incr)
/* Return true if set is live. */ /* Return true if set is live. */
static bool static bool
set_live_p (set, insn, counts) set_live_p (rtx set, rtx insn ATTRIBUTE_UNUSED, /* Only used with HAVE_cc0. */
rtx set; int *counts)
rtx insn ATTRIBUTE_UNUSED; /* Only used with HAVE_cc0. */
int *counts;
{ {
#ifdef HAVE_cc0 #ifdef HAVE_cc0
rtx tem; rtx tem;
...@@ -7599,9 +7489,7 @@ set_live_p (set, insn, counts) ...@@ -7599,9 +7489,7 @@ set_live_p (set, insn, counts)
/* Return true if insn is live. */ /* Return true if insn is live. */
static bool static bool
insn_live_p (insn, counts) insn_live_p (rtx insn, int *counts)
rtx insn;
int *counts;
{ {
int i; int i;
if (flag_non_call_exceptions && may_trap_p (PATTERN (insn))) if (flag_non_call_exceptions && may_trap_p (PATTERN (insn)))
...@@ -7631,9 +7519,7 @@ insn_live_p (insn, counts) ...@@ -7631,9 +7519,7 @@ insn_live_p (insn, counts)
/* Return true if libcall is dead as a whole. */ /* Return true if libcall is dead as a whole. */
static bool static bool
dead_libcall_p (insn, counts) dead_libcall_p (rtx insn, int *counts)
rtx insn;
int *counts;
{ {
rtx note, set, new; rtx note, set, new;
...@@ -7690,9 +7576,7 @@ dead_libcall_p (insn, counts) ...@@ -7690,9 +7576,7 @@ dead_libcall_p (insn, counts)
remaining passes of the compilation are also sped up. */ remaining passes of the compilation are also sped up. */
int int
delete_trivially_dead_insns (insns, nreg) delete_trivially_dead_insns (rtx insns, int nreg)
rtx insns;
int nreg;
{ {
int *counts; int *counts;
rtx insn, prev; rtx insn, prev;
......
...@@ -40,34 +40,28 @@ Software Foundation, 59 Temple Place - Suite 330, Boston, MA ...@@ -40,34 +40,28 @@ Software Foundation, 59 Temple Place - Suite 330, Boston, MA
#include "hashtab.h" #include "hashtab.h"
#include "cselib.h" #include "cselib.h"
static int entry_and_rtx_equal_p PARAMS ((const void *, const void *)); static int entry_and_rtx_equal_p (const void *, const void *);
static hashval_t get_value_hash PARAMS ((const void *)); static hashval_t get_value_hash (const void *);
static struct elt_list *new_elt_list PARAMS ((struct elt_list *, static struct elt_list *new_elt_list (struct elt_list *, cselib_val *);
cselib_val *)); static struct elt_loc_list *new_elt_loc_list (struct elt_loc_list *, rtx);
static struct elt_loc_list *new_elt_loc_list PARAMS ((struct elt_loc_list *, static void unchain_one_value (cselib_val *);
rtx)); static void unchain_one_elt_list (struct elt_list **);
static void unchain_one_value PARAMS ((cselib_val *)); static void unchain_one_elt_loc_list (struct elt_loc_list **);
static void unchain_one_elt_list PARAMS ((struct elt_list **)); static void clear_table (void);
static void unchain_one_elt_loc_list PARAMS ((struct elt_loc_list **)); static int discard_useless_locs (void **, void *);
static void clear_table PARAMS ((void)); static int discard_useless_values (void **, void *);
static int discard_useless_locs PARAMS ((void **, void *)); static void remove_useless_values (void);
static int discard_useless_values PARAMS ((void **, void *)); static rtx wrap_constant (enum machine_mode, rtx);
static void remove_useless_values PARAMS ((void)); static unsigned int hash_rtx (rtx, enum machine_mode, int);
static rtx wrap_constant PARAMS ((enum machine_mode, rtx)); static cselib_val *new_cselib_val (unsigned int, enum machine_mode);
static unsigned int hash_rtx PARAMS ((rtx, enum machine_mode, int)); static void add_mem_for_addr (cselib_val *, cselib_val *, rtx);
static cselib_val *new_cselib_val PARAMS ((unsigned int, static cselib_val *cselib_lookup_mem (rtx, int);
enum machine_mode)); static void cselib_invalidate_regno (unsigned int, enum machine_mode);
static void add_mem_for_addr PARAMS ((cselib_val *, cselib_val *, static int cselib_mem_conflict_p (rtx, rtx);
rtx)); static void cselib_invalidate_mem (rtx);
static cselib_val *cselib_lookup_mem PARAMS ((rtx, int)); static void cselib_invalidate_rtx (rtx, rtx, void *);
static void cselib_invalidate_regno PARAMS ((unsigned int, static void cselib_record_set (rtx, cselib_val *, cselib_val *);
enum machine_mode)); static void cselib_record_sets (rtx);
static int cselib_mem_conflict_p PARAMS ((rtx, rtx));
static void cselib_invalidate_mem PARAMS ((rtx));
static void cselib_invalidate_rtx PARAMS ((rtx, rtx, void *));
static void cselib_record_set PARAMS ((rtx, cselib_val *,
cselib_val *));
static void cselib_record_sets PARAMS ((rtx));
/* There are three ways in which cselib can look up an rtx: /* There are three ways in which cselib can look up an rtx:
- for a REG, the reg_values table (which is indexed by regno) is used - for a REG, the reg_values table (which is indexed by regno) is used
...@@ -146,9 +140,7 @@ static cselib_val *first_containing_mem = &dummy_val; ...@@ -146,9 +140,7 @@ static cselib_val *first_containing_mem = &dummy_val;
arguments. */ arguments. */
static struct elt_list * static struct elt_list *
new_elt_list (next, elt) new_elt_list (struct elt_list *next, cselib_val *elt)
struct elt_list *next;
cselib_val *elt;
{ {
struct elt_list *el = empty_elt_lists; struct elt_list *el = empty_elt_lists;
...@@ -165,9 +157,7 @@ new_elt_list (next, elt) ...@@ -165,9 +157,7 @@ new_elt_list (next, elt)
arguments. */ arguments. */
static struct elt_loc_list * static struct elt_loc_list *
new_elt_loc_list (next, loc) new_elt_loc_list (struct elt_loc_list *next, rtx loc)
struct elt_loc_list *next;
rtx loc;
{ {
struct elt_loc_list *el = empty_elt_loc_lists; struct elt_loc_list *el = empty_elt_loc_lists;
...@@ -186,8 +176,7 @@ new_elt_loc_list (next, loc) ...@@ -186,8 +176,7 @@ new_elt_loc_list (next, loc)
storage. */ storage. */
static void static void
unchain_one_elt_list (pl) unchain_one_elt_list (struct elt_list **pl)
struct elt_list **pl;
{ {
struct elt_list *l = *pl; struct elt_list *l = *pl;
...@@ -199,8 +188,7 @@ unchain_one_elt_list (pl) ...@@ -199,8 +188,7 @@ unchain_one_elt_list (pl)
/* Likewise for elt_loc_lists. */ /* Likewise for elt_loc_lists. */
static void static void
unchain_one_elt_loc_list (pl) unchain_one_elt_loc_list (struct elt_loc_list **pl)
struct elt_loc_list **pl;
{ {
struct elt_loc_list *l = *pl; struct elt_loc_list *l = *pl;
...@@ -213,8 +201,7 @@ unchain_one_elt_loc_list (pl) ...@@ -213,8 +201,7 @@ unchain_one_elt_loc_list (pl)
V. */ V. */
static void static void
unchain_one_value (v) unchain_one_value (cselib_val *v)
cselib_val *v;
{ {
while (v->addr_list) while (v->addr_list)
unchain_one_elt_list (&v->addr_list); unchain_one_elt_list (&v->addr_list);
...@@ -228,7 +215,7 @@ unchain_one_value (v) ...@@ -228,7 +215,7 @@ unchain_one_value (v)
which are known to have been used. */ which are known to have been used. */
static void static void
clear_table () clear_table (void)
{ {
unsigned int i; unsigned int i;
...@@ -254,8 +241,7 @@ clear_table () ...@@ -254,8 +241,7 @@ clear_table ()
CONST of an appropriate mode. */ CONST of an appropriate mode. */
static int static int
entry_and_rtx_equal_p (entry, x_arg) entry_and_rtx_equal_p (const void *entry, const void *x_arg)
const void *entry, *x_arg;
{ {
struct elt_loc_list *l; struct elt_loc_list *l;
const cselib_val *v = (const cselib_val *) entry; const cselib_val *v = (const cselib_val *) entry;
...@@ -288,8 +274,7 @@ entry_and_rtx_equal_p (entry, x_arg) ...@@ -288,8 +274,7 @@ entry_and_rtx_equal_p (entry, x_arg)
value from a cselib_val structure. */ value from a cselib_val structure. */
static hashval_t static hashval_t
get_value_hash (entry) get_value_hash (const void *entry)
const void *entry;
{ {
const cselib_val *v = (const cselib_val *) entry; const cselib_val *v = (const cselib_val *) entry;
return v->value; return v->value;
...@@ -301,9 +286,7 @@ get_value_hash (entry) ...@@ -301,9 +286,7 @@ get_value_hash (entry)
removed. */ removed. */
int int
references_value_p (x, only_useless) references_value_p (rtx x, int only_useless)
rtx x;
int only_useless;
{ {
enum rtx_code code = GET_CODE (x); enum rtx_code code = GET_CODE (x);
const char *fmt = GET_RTX_FORMAT (code); const char *fmt = GET_RTX_FORMAT (code);
...@@ -331,9 +314,7 @@ references_value_p (x, only_useless) ...@@ -331,9 +314,7 @@ references_value_p (x, only_useless)
htab_traverse. */ htab_traverse. */
static int static int
discard_useless_locs (x, info) discard_useless_locs (void **x, void *info ATTRIBUTE_UNUSED)
void **x;
void *info ATTRIBUTE_UNUSED;
{ {
cselib_val *v = (cselib_val *)*x; cselib_val *v = (cselib_val *)*x;
struct elt_loc_list **p = &v->locs; struct elt_loc_list **p = &v->locs;
...@@ -358,9 +339,7 @@ discard_useless_locs (x, info) ...@@ -358,9 +339,7 @@ discard_useless_locs (x, info)
/* If X is a value with no locations, remove it from the hashtable. */ /* If X is a value with no locations, remove it from the hashtable. */
static int static int
discard_useless_values (x, info) discard_useless_values (void **x, void *info ATTRIBUTE_UNUSED)
void **x;
void *info ATTRIBUTE_UNUSED;
{ {
cselib_val *v = (cselib_val *)*x; cselib_val *v = (cselib_val *)*x;
...@@ -378,7 +357,7 @@ discard_useless_values (x, info) ...@@ -378,7 +357,7 @@ discard_useless_values (x, info)
associated with them) from the hash table. */ associated with them) from the hash table. */
static void static void
remove_useless_values () remove_useless_values (void)
{ {
cselib_val **p, *v; cselib_val **p, *v;
/* First pass: eliminate locations that reference the value. That in /* First pass: eliminate locations that reference the value. That in
...@@ -412,8 +391,7 @@ remove_useless_values () ...@@ -412,8 +391,7 @@ remove_useless_values ()
VOIDmode. */ VOIDmode. */
enum machine_mode enum machine_mode
cselib_reg_set_mode (x) cselib_reg_set_mode (rtx x)
rtx x;
{ {
if (GET_CODE (x) != REG) if (GET_CODE (x) != REG)
return GET_MODE (x); return GET_MODE (x);
...@@ -429,8 +407,7 @@ cselib_reg_set_mode (x) ...@@ -429,8 +407,7 @@ cselib_reg_set_mode (x)
our gathered information into account. */ our gathered information into account. */
int int
rtx_equal_for_cselib_p (x, y) rtx_equal_for_cselib_p (rtx x, rtx y)
rtx x, y;
{ {
enum rtx_code code; enum rtx_code code;
const char *fmt; const char *fmt;
...@@ -568,9 +545,7 @@ rtx_equal_for_cselib_p (x, y) ...@@ -568,9 +545,7 @@ rtx_equal_for_cselib_p (x, y)
functions. For that purpose, wrap them in a CONST of the appropriate functions. For that purpose, wrap them in a CONST of the appropriate
mode. */ mode. */
static rtx static rtx
wrap_constant (mode, x) wrap_constant (enum machine_mode mode, rtx x)
enum machine_mode mode;
rtx x;
{ {
if (GET_CODE (x) != CONST_INT if (GET_CODE (x) != CONST_INT
&& (GET_CODE (x) != CONST_DOUBLE || GET_MODE (x) != VOIDmode)) && (GET_CODE (x) != CONST_DOUBLE || GET_MODE (x) != VOIDmode))
...@@ -590,10 +565,7 @@ wrap_constant (mode, x) ...@@ -590,10 +565,7 @@ wrap_constant (mode, x)
otherwise the mode of X is used. */ otherwise the mode of X is used. */
static unsigned int static unsigned int
hash_rtx (x, mode, create) hash_rtx (rtx x, enum machine_mode mode, int create)
rtx x;
enum machine_mode mode;
int create;
{ {
cselib_val *e; cselib_val *e;
int i, j; int i, j;
...@@ -725,9 +697,7 @@ hash_rtx (x, mode, create) ...@@ -725,9 +697,7 @@ hash_rtx (x, mode, create)
value is MODE. */ value is MODE. */
static cselib_val * static cselib_val *
new_cselib_val (value, mode) new_cselib_val (unsigned int value, enum machine_mode mode)
unsigned int value;
enum machine_mode mode;
{ {
cselib_val *e = empty_vals; cselib_val *e = empty_vals;
...@@ -753,9 +723,7 @@ new_cselib_val (value, mode) ...@@ -753,9 +723,7 @@ new_cselib_val (value, mode)
value. Update the two value structures to represent this situation. */ value. Update the two value structures to represent this situation. */
static void static void
add_mem_for_addr (addr_elt, mem_elt, x) add_mem_for_addr (cselib_val *addr_elt, cselib_val *mem_elt, rtx x)
cselib_val *addr_elt, *mem_elt;
rtx x;
{ {
struct elt_loc_list *l; struct elt_loc_list *l;
...@@ -780,9 +748,7 @@ add_mem_for_addr (addr_elt, mem_elt, x) ...@@ -780,9 +748,7 @@ add_mem_for_addr (addr_elt, mem_elt, x)
If CREATE, make a new one if we haven't seen it before. */ If CREATE, make a new one if we haven't seen it before. */
static cselib_val * static cselib_val *
cselib_lookup_mem (x, create) cselib_lookup_mem (rtx x, int create)
rtx x;
int create;
{ {
enum machine_mode mode = GET_MODE (x); enum machine_mode mode = GET_MODE (x);
void **slot; void **slot;
...@@ -822,8 +788,7 @@ cselib_lookup_mem (x, create) ...@@ -822,8 +788,7 @@ cselib_lookup_mem (x, create)
allocated. However, the return value can share rtl with X. */ allocated. However, the return value can share rtl with X. */
rtx rtx
cselib_subst_to_values (x) cselib_subst_to_values (rtx x)
rtx x;
{ {
enum rtx_code code = GET_CODE (x); enum rtx_code code = GET_CODE (x);
const char *fmt = GET_RTX_FORMAT (code); const char *fmt = GET_RTX_FORMAT (code);
...@@ -915,10 +880,7 @@ cselib_subst_to_values (x) ...@@ -915,10 +880,7 @@ cselib_subst_to_values (x)
(i.e. because it's a constant). */ (i.e. because it's a constant). */
cselib_val * cselib_val *
cselib_lookup (x, mode, create) cselib_lookup (rtx x, enum machine_mode mode, int create)
rtx x;
enum machine_mode mode;
int create;
{ {
void **slot; void **slot;
cselib_val *e; cselib_val *e;
...@@ -1003,9 +965,7 @@ cselib_lookup (x, mode, create) ...@@ -1003,9 +965,7 @@ cselib_lookup (x, mode, create)
invalidating call clobbered registers across a call. */ invalidating call clobbered registers across a call. */
static void static void
cselib_invalidate_regno (regno, mode) cselib_invalidate_regno (unsigned int regno, enum machine_mode mode)
unsigned int regno;
enum machine_mode mode;
{ {
unsigned int endregno; unsigned int endregno;
unsigned int i; unsigned int i;
...@@ -1094,9 +1054,7 @@ cselib_invalidate_regno (regno, mode) ...@@ -1094,9 +1054,7 @@ cselib_invalidate_regno (regno, mode)
Return whether this change will invalidate VAL. */ Return whether this change will invalidate VAL. */
static int static int
cselib_mem_conflict_p (mem_base, val) cselib_mem_conflict_p (rtx mem_base, rtx val)
rtx mem_base;
rtx val;
{ {
enum rtx_code code; enum rtx_code code;
const char *fmt; const char *fmt;
...@@ -1153,8 +1111,7 @@ cselib_mem_conflict_p (mem_base, val) ...@@ -1153,8 +1111,7 @@ cselib_mem_conflict_p (mem_base, val)
instruction, MEM_RTX is (mem:BLK const0_rtx). */ instruction, MEM_RTX is (mem:BLK const0_rtx). */
static void static void
cselib_invalidate_mem (mem_rtx) cselib_invalidate_mem (rtx mem_rtx)
rtx mem_rtx;
{ {
cselib_val **vp, *v, *next; cselib_val **vp, *v, *next;
...@@ -1224,10 +1181,8 @@ cselib_invalidate_mem (mem_rtx) ...@@ -1224,10 +1181,8 @@ cselib_invalidate_mem (mem_rtx)
note_stores; they are ignored. */ note_stores; they are ignored. */
static void static void
cselib_invalidate_rtx (dest, ignore, data) cselib_invalidate_rtx (rtx dest, rtx ignore ATTRIBUTE_UNUSED,
rtx dest; void *data ATTRIBUTE_UNUSED)
rtx ignore ATTRIBUTE_UNUSED;
void *data ATTRIBUTE_UNUSED;
{ {
while (GET_CODE (dest) == STRICT_LOW_PART || GET_CODE (dest) == SIGN_EXTRACT while (GET_CODE (dest) == STRICT_LOW_PART || GET_CODE (dest) == SIGN_EXTRACT
|| GET_CODE (dest) == ZERO_EXTRACT || GET_CODE (dest) == SUBREG) || GET_CODE (dest) == ZERO_EXTRACT || GET_CODE (dest) == SUBREG)
...@@ -1251,9 +1206,7 @@ cselib_invalidate_rtx (dest, ignore, data) ...@@ -1251,9 +1206,7 @@ cselib_invalidate_rtx (dest, ignore, data)
describes its address. */ describes its address. */
static void static void
cselib_record_set (dest, src_elt, dest_addr_elt) cselib_record_set (rtx dest, cselib_val *src_elt, cselib_val *dest_addr_elt)
rtx dest;
cselib_val *src_elt, *dest_addr_elt;
{ {
int dreg = GET_CODE (dest) == REG ? (int) REGNO (dest) : -1; int dreg = GET_CODE (dest) == REG ? (int) REGNO (dest) : -1;
...@@ -1311,8 +1264,7 @@ struct set ...@@ -1311,8 +1264,7 @@ struct set
/* Record the effects of any sets in INSN. */ /* Record the effects of any sets in INSN. */
static void static void
cselib_record_sets (insn) cselib_record_sets (rtx insn)
rtx insn;
{ {
int n_sets = 0; int n_sets = 0;
int i; int i;
...@@ -1393,8 +1345,7 @@ cselib_record_sets (insn) ...@@ -1393,8 +1345,7 @@ cselib_record_sets (insn)
/* Record the effects of INSN. */ /* Record the effects of INSN. */
void void
cselib_process_insn (insn) cselib_process_insn (rtx insn)
rtx insn;
{ {
int i; int i;
rtx x; rtx x;
...@@ -1464,7 +1415,7 @@ cselib_process_insn (insn) ...@@ -1464,7 +1415,7 @@ cselib_process_insn (insn)
it must be called by the user if it allocated new registers. */ it must be called by the user if it allocated new registers. */
void void
cselib_update_varray_sizes () cselib_update_varray_sizes (void)
{ {
unsigned int nregs = max_reg_num (); unsigned int nregs = max_reg_num ();
...@@ -1480,7 +1431,7 @@ cselib_update_varray_sizes () ...@@ -1480,7 +1431,7 @@ cselib_update_varray_sizes ()
init_alias_analysis. */ init_alias_analysis. */
void void
cselib_init () cselib_init (void)
{ {
/* This is only created once. */ /* This is only created once. */
if (! callmem) if (! callmem)
...@@ -1505,7 +1456,7 @@ cselib_init () ...@@ -1505,7 +1456,7 @@ cselib_init ()
/* Called when the current user is done with cselib. */ /* Called when the current user is done with cselib. */
void void
cselib_finish () cselib_finish (void)
{ {
clear_table (); clear_table ();
reg_values_old = reg_values; reg_values_old = reg_values;
......
...@@ -62,12 +62,12 @@ struct elt_list GTY(()) ...@@ -62,12 +62,12 @@ struct elt_list GTY(())
cselib_val *elt; cselib_val *elt;
}; };
extern cselib_val *cselib_lookup PARAMS ((rtx, enum machine_mode, int)); extern cselib_val *cselib_lookup (rtx, enum machine_mode, int);
extern void cselib_update_varray_sizes PARAMS ((void)); extern void cselib_update_varray_sizes (void);
extern void cselib_init PARAMS ((void)); extern void cselib_init (void);
extern void cselib_finish PARAMS ((void)); extern void cselib_finish (void);
extern void cselib_process_insn PARAMS ((rtx)); extern void cselib_process_insn (rtx);
extern enum machine_mode cselib_reg_set_mode PARAMS ((rtx)); extern enum machine_mode cselib_reg_set_mode (rtx);
extern int rtx_equal_for_cselib_p PARAMS ((rtx, rtx)); extern int rtx_equal_for_cselib_p (rtx, rtx);
extern int references_value_p PARAMS ((rtx, int)); extern int references_value_p (rtx, int);
extern rtx cselib_subst_to_values PARAMS ((rtx)); extern rtx cselib_subst_to_values (rtx);
...@@ -307,46 +307,46 @@ static int current_sym_nchars; ...@@ -307,46 +307,46 @@ static int current_sym_nchars;
#define CONTIN do { } while (0) #define CONTIN do { } while (0)
#endif #endif
static void dbxout_init PARAMS ((const char *)); static void dbxout_init (const char *);
static void dbxout_finish PARAMS ((const char *)); static void dbxout_finish (const char *);
static void dbxout_start_source_file PARAMS ((unsigned, const char *)); static void dbxout_start_source_file (unsigned, const char *);
static void dbxout_end_source_file PARAMS ((unsigned)); static void dbxout_end_source_file (unsigned);
static void dbxout_typedefs PARAMS ((tree)); static void dbxout_typedefs (tree);
static void dbxout_fptype_value PARAMS ((tree)); static void dbxout_fptype_value (tree);
static void dbxout_type_index PARAMS ((tree)); static void dbxout_type_index (tree);
#if DBX_CONTIN_LENGTH > 0 #if DBX_CONTIN_LENGTH > 0
static void dbxout_continue PARAMS ((void)); static void dbxout_continue (void);
#endif #endif
static void dbxout_args PARAMS ((tree)); static void dbxout_args (tree);
static void dbxout_type_fields PARAMS ((tree)); static void dbxout_type_fields (tree);
static void dbxout_type_method_1 PARAMS ((tree, const char *)); static void dbxout_type_method_1 (tree, const char *);
static void dbxout_type_methods PARAMS ((tree)); static void dbxout_type_methods (tree);
static void dbxout_range_type PARAMS ((tree)); static void dbxout_range_type (tree);
static void dbxout_type PARAMS ((tree, int)); static void dbxout_type (tree, int);
static bool print_int_cst_bounds_in_octal_p PARAMS ((tree)); static bool print_int_cst_bounds_in_octal_p (tree);
static void print_int_cst_octal PARAMS ((tree)); static void print_int_cst_octal (tree);
static void print_octal PARAMS ((unsigned HOST_WIDE_INT, int)); static void print_octal (unsigned HOST_WIDE_INT, int);
static void print_wide_int PARAMS ((HOST_WIDE_INT)); static void print_wide_int (HOST_WIDE_INT);
static void dbxout_type_name PARAMS ((tree)); static void dbxout_type_name (tree);
static void dbxout_class_name_qualifiers PARAMS ((tree)); static void dbxout_class_name_qualifiers (tree);
static int dbxout_symbol_location PARAMS ((tree, tree, const char *, rtx)); static int dbxout_symbol_location (tree, tree, const char *, rtx);
static void dbxout_symbol_name PARAMS ((tree, const char *, int)); static void dbxout_symbol_name (tree, const char *, int);
static void dbxout_prepare_symbol PARAMS ((tree)); static void dbxout_prepare_symbol (tree);
static void dbxout_finish_symbol PARAMS ((tree)); static void dbxout_finish_symbol (tree);
static void dbxout_block PARAMS ((tree, int, tree)); static void dbxout_block (tree, int, tree);
static void dbxout_global_decl PARAMS ((tree)); static void dbxout_global_decl (tree);
static void dbxout_handle_pch PARAMS ((unsigned)); static void dbxout_handle_pch (unsigned);
/* The debug hooks structure. */ /* The debug hooks structure. */
#if defined (DBX_DEBUGGING_INFO) #if defined (DBX_DEBUGGING_INFO)
static void dbxout_source_line PARAMS ((unsigned int, const char *)); static void dbxout_source_line (unsigned int, const char *);
static void dbxout_source_file PARAMS ((FILE *, const char *)); static void dbxout_source_file (FILE *, const char *);
static void dbxout_function_end PARAMS ((void)); static void dbxout_function_end (void);
static void dbxout_begin_function PARAMS ((tree)); static void dbxout_begin_function (tree);
static void dbxout_begin_block PARAMS ((unsigned, unsigned)); static void dbxout_begin_block (unsigned, unsigned);
static void dbxout_end_block PARAMS ((unsigned, unsigned)); static void dbxout_end_block (unsigned, unsigned);
static void dbxout_function_decl PARAMS ((tree)); static void dbxout_function_decl (tree);
const struct gcc_debug_hooks dbx_debug_hooks = const struct gcc_debug_hooks dbx_debug_hooks =
{ {
...@@ -407,7 +407,7 @@ const struct gcc_debug_hooks xcoff_debug_hooks = ...@@ -407,7 +407,7 @@ const struct gcc_debug_hooks xcoff_debug_hooks =
#if defined (DBX_DEBUGGING_INFO) #if defined (DBX_DEBUGGING_INFO)
static void static void
dbxout_function_end () dbxout_function_end (void)
{ {
char lscope_label_name[100]; char lscope_label_name[100];
/* Convert Ltext into the appropriate format for local labels in case /* Convert Ltext into the appropriate format for local labels in case
...@@ -435,8 +435,7 @@ dbxout_function_end () ...@@ -435,8 +435,7 @@ dbxout_function_end ()
Initialize `typevec' and output the standard data types of C. */ Initialize `typevec' and output the standard data types of C. */
static void static void
dbxout_init (input_file_name) dbxout_init (const char *input_file_name)
const char *input_file_name;
{ {
char ltext_label_name[100]; char ltext_label_name[100];
tree syms = (*lang_hooks.decls.getdecls) (); tree syms = (*lang_hooks.decls.getdecls) ();
...@@ -526,8 +525,7 @@ dbxout_init (input_file_name) ...@@ -526,8 +525,7 @@ dbxout_init (input_file_name)
in the reverse order from that which is found in SYMS. */ in the reverse order from that which is found in SYMS. */
static void static void
dbxout_typedefs (syms) dbxout_typedefs (tree syms)
tree syms;
{ {
if (syms) if (syms)
{ {
...@@ -547,9 +545,8 @@ dbxout_typedefs (syms) ...@@ -547,9 +545,8 @@ dbxout_typedefs (syms)
/* Change to reading from a new source file. Generate a N_BINCL stab. */ /* Change to reading from a new source file. Generate a N_BINCL stab. */
static void static void
dbxout_start_source_file (line, filename) dbxout_start_source_file (unsigned int line ATTRIBUTE_UNUSED,
unsigned int line ATTRIBUTE_UNUSED; const char *filename ATTRIBUTE_UNUSED)
const char *filename ATTRIBUTE_UNUSED;
{ {
#ifdef DBX_USE_BINCL #ifdef DBX_USE_BINCL
struct dbx_file *n = (struct dbx_file *) ggc_alloc (sizeof *n); struct dbx_file *n = (struct dbx_file *) ggc_alloc (sizeof *n);
...@@ -567,8 +564,7 @@ dbxout_start_source_file (line, filename) ...@@ -567,8 +564,7 @@ dbxout_start_source_file (line, filename)
/* Revert to reading a previous source file. Generate a N_EINCL stab. */ /* Revert to reading a previous source file. Generate a N_EINCL stab. */
static void static void
dbxout_end_source_file (line) dbxout_end_source_file (unsigned int line ATTRIBUTE_UNUSED)
unsigned int line ATTRIBUTE_UNUSED;
{ {
#ifdef DBX_USE_BINCL #ifdef DBX_USE_BINCL
fprintf (asmfile, "%s%d,0,0,0\n", ASM_STABN_OP, N_EINCL); fprintf (asmfile, "%s%d,0,0,0\n", ASM_STABN_OP, N_EINCL);
...@@ -605,9 +601,7 @@ dbxout_handle_pch (unsigned at_end) ...@@ -605,9 +601,7 @@ dbxout_handle_pch (unsigned at_end)
/* Output debugging info to FILE to switch to sourcefile FILENAME. */ /* Output debugging info to FILE to switch to sourcefile FILENAME. */
static void static void
dbxout_source_file (file, filename) dbxout_source_file (FILE *file, const char *filename)
FILE *file;
const char *filename;
{ {
if (lastfile == 0 && lastfile_is_base) if (lastfile == 0 && lastfile_is_base)
{ {
...@@ -641,9 +635,7 @@ dbxout_source_file (file, filename) ...@@ -641,9 +635,7 @@ dbxout_source_file (file, filename)
number LINENO. */ number LINENO. */
static void static void
dbxout_source_line (lineno, filename) dbxout_source_line (unsigned int lineno, const char *filename)
unsigned int lineno;
const char *filename;
{ {
dbxout_source_file (asmfile, filename); dbxout_source_file (asmfile, filename);
...@@ -658,9 +650,7 @@ dbxout_source_line (lineno, filename) ...@@ -658,9 +650,7 @@ dbxout_source_line (lineno, filename)
/* Describe the beginning of an internal block within a function. */ /* Describe the beginning of an internal block within a function. */
static void static void
dbxout_begin_block (line, n) dbxout_begin_block (unsigned int line ATTRIBUTE_UNUSED, unsigned int n)
unsigned int line ATTRIBUTE_UNUSED;
unsigned int n;
{ {
(*targetm.asm_out.internal_label) (asmfile, "LBB", n); (*targetm.asm_out.internal_label) (asmfile, "LBB", n);
} }
...@@ -668,9 +658,7 @@ dbxout_begin_block (line, n) ...@@ -668,9 +658,7 @@ dbxout_begin_block (line, n)
/* Describe the end line-number of an internal block within a function. */ /* Describe the end line-number of an internal block within a function. */
static void static void
dbxout_end_block (line, n) dbxout_end_block (unsigned int line ATTRIBUTE_UNUSED, unsigned int n)
unsigned int line ATTRIBUTE_UNUSED;
unsigned int n;
{ {
(*targetm.asm_out.internal_label) (asmfile, "LBE", n); (*targetm.asm_out.internal_label) (asmfile, "LBE", n);
} }
...@@ -682,8 +670,7 @@ dbxout_end_block (line, n) ...@@ -682,8 +670,7 @@ dbxout_end_block (line, n)
(including all the auto variables of the function). */ (including all the auto variables of the function). */
static void static void
dbxout_function_decl (decl) dbxout_function_decl (tree decl)
tree decl;
{ {
#ifndef DBX_FUNCTION_FIRST #ifndef DBX_FUNCTION_FIRST
dbxout_begin_function (decl); dbxout_begin_function (decl);
...@@ -705,8 +692,7 @@ dbxout_function_decl (decl) ...@@ -705,8 +692,7 @@ dbxout_function_decl (decl)
/* Debug information for a global DECL. Called from toplev.c after /* Debug information for a global DECL. Called from toplev.c after
compilation proper has finished. */ compilation proper has finished. */
static void static void
dbxout_global_decl (decl) dbxout_global_decl (tree decl)
tree decl;
{ {
if (TREE_CODE (decl) == VAR_DECL if (TREE_CODE (decl) == VAR_DECL
&& ! DECL_EXTERNAL (decl) && ! DECL_EXTERNAL (decl)
...@@ -724,8 +710,7 @@ dbxout_global_decl (decl) ...@@ -724,8 +710,7 @@ dbxout_global_decl (decl)
to do nothing. */ to do nothing. */
static void static void
dbxout_finish (filename) dbxout_finish (const char *filename ATTRIBUTE_UNUSED)
const char *filename ATTRIBUTE_UNUSED;
{ {
#ifdef DBX_OUTPUT_MAIN_SOURCE_FILE_END #ifdef DBX_OUTPUT_MAIN_SOURCE_FILE_END
DBX_OUTPUT_MAIN_SOURCE_FILE_END (asmfile, filename); DBX_OUTPUT_MAIN_SOURCE_FILE_END (asmfile, filename);
...@@ -752,8 +737,7 @@ dbxout_finish (filename) ...@@ -752,8 +737,7 @@ dbxout_finish (filename)
them. */ them. */
static void static void
dbxout_fptype_value (type) dbxout_fptype_value (tree type)
tree type;
{ {
char value = '0'; char value = '0';
enum machine_mode mode = TYPE_MODE (type); enum machine_mode mode = TYPE_MODE (type);
...@@ -792,8 +776,7 @@ dbxout_fptype_value (type) ...@@ -792,8 +776,7 @@ dbxout_fptype_value (type)
/* Output the index of a type. */ /* Output the index of a type. */
static void static void
dbxout_type_index (type) dbxout_type_index (tree type)
tree type;
{ {
#ifndef DBX_USE_BINCL #ifndef DBX_USE_BINCL
fprintf (asmfile, "%d", TYPE_SYMTAB_ADDRESS (type)); fprintf (asmfile, "%d", TYPE_SYMTAB_ADDRESS (type));
...@@ -813,7 +796,7 @@ dbxout_type_index (type) ...@@ -813,7 +796,7 @@ dbxout_type_index (type)
.stabs "...rest",code,0,value */ .stabs "...rest",code,0,value */
static void static void
dbxout_continue () dbxout_continue (void)
{ {
#ifdef DBX_CONTIN_CHAR #ifdef DBX_CONTIN_CHAR
fprintf (asmfile, "%c", DBX_CONTIN_CHAR); fprintf (asmfile, "%c", DBX_CONTIN_CHAR);
...@@ -831,8 +814,7 @@ dbxout_continue () ...@@ -831,8 +814,7 @@ dbxout_continue ()
recursive calls. */ recursive calls. */
static void static void
dbxout_type_fields (type) dbxout_type_fields (tree type)
tree type;
{ {
tree tem; tree tem;
...@@ -922,9 +904,7 @@ dbxout_type_fields (type) ...@@ -922,9 +904,7 @@ dbxout_type_fields (type)
now. */ now. */
static void static void
dbxout_type_method_1 (decl, debug_name) dbxout_type_method_1 (tree decl, const char *debug_name)
tree decl;
const char *debug_name;
{ {
char c1 = 'A', c2; char c1 = 'A', c2;
...@@ -969,8 +949,7 @@ dbxout_type_method_1 (decl, debug_name) ...@@ -969,8 +949,7 @@ dbxout_type_method_1 (decl, debug_name)
in TYPE. */ in TYPE. */
static void static void
dbxout_type_methods (type) dbxout_type_methods (tree type)
tree type;
{ {
/* C++: put out the method names and their parameter lists */ /* C++: put out the method names and their parameter lists */
tree methods = TYPE_METHODS (type); tree methods = TYPE_METHODS (type);
...@@ -1075,8 +1054,7 @@ dbxout_type_methods (type) ...@@ -1075,8 +1054,7 @@ dbxout_type_methods (type)
TYPE is an INTEGER_TYPE. */ TYPE is an INTEGER_TYPE. */
static void static void
dbxout_range_type (type) dbxout_range_type (tree type)
tree type;
{ {
fprintf (asmfile, "r"); fprintf (asmfile, "r");
if (TREE_TYPE (type)) if (TREE_TYPE (type))
...@@ -1150,9 +1128,7 @@ dbxout_range_type (type) ...@@ -1150,9 +1128,7 @@ dbxout_range_type (type)
using the number previously allocated. */ using the number previously allocated. */
static void static void
dbxout_type (type, full) dbxout_type (tree type, int full)
tree type;
int full;
{ {
tree tem; tree tem;
tree main_variant; tree main_variant;
...@@ -1854,8 +1830,7 @@ dbxout_type (type, full) ...@@ -1854,8 +1830,7 @@ dbxout_type (type, full)
should be printed in octal format. */ should be printed in octal format. */
static bool static bool
print_int_cst_bounds_in_octal_p (type) print_int_cst_bounds_in_octal_p (tree type)
tree type;
{ {
/* If we can use GDB extensions and the size is wider than a long /* If we can use GDB extensions and the size is wider than a long
(the size used by GDB to read them) or we may have trouble writing (the size used by GDB to read them) or we may have trouble writing
...@@ -1888,8 +1863,7 @@ print_int_cst_bounds_in_octal_p (type) ...@@ -1888,8 +1863,7 @@ print_int_cst_bounds_in_octal_p (type)
handling double precision. */ handling double precision. */
static void static void
print_int_cst_octal (c) print_int_cst_octal (tree c)
tree c;
{ {
unsigned HOST_WIDE_INT high = TREE_INT_CST_HIGH (c); unsigned HOST_WIDE_INT high = TREE_INT_CST_HIGH (c);
unsigned HOST_WIDE_INT low = TREE_INT_CST_LOW (c); unsigned HOST_WIDE_INT low = TREE_INT_CST_LOW (c);
...@@ -1934,9 +1908,7 @@ print_int_cst_octal (c) ...@@ -1934,9 +1908,7 @@ print_int_cst_octal (c)
} }
static void static void
print_octal (value, digits) print_octal (unsigned HOST_WIDE_INT value, int digits)
unsigned HOST_WIDE_INT value;
int digits;
{ {
int i; int i;
...@@ -1949,8 +1921,7 @@ print_octal (value, digits) ...@@ -1949,8 +1921,7 @@ print_octal (value, digits)
/* Output C in decimal while adjusting the number of digits written. */ /* Output C in decimal while adjusting the number of digits written. */
static void static void
print_wide_int (c) print_wide_int (HOST_WIDE_INT c)
HOST_WIDE_INT c;
{ {
int digs = 0; int digs = 0;
...@@ -1970,8 +1941,7 @@ print_wide_int (c) ...@@ -1970,8 +1941,7 @@ print_wide_int (c)
or by struct, enum and union tags. */ or by struct, enum and union tags. */
static void static void
dbxout_type_name (type) dbxout_type_name (tree type)
tree type;
{ {
tree t; tree t;
if (TYPE_NAME (type) == 0) if (TYPE_NAME (type) == 0)
...@@ -1995,8 +1965,7 @@ dbxout_type_name (type) ...@@ -1995,8 +1965,7 @@ dbxout_type_name (type)
type whose scope is limited to a struct or class. */ type whose scope is limited to a struct or class. */
static void static void
dbxout_class_name_qualifiers (decl) dbxout_class_name_qualifiers (tree decl)
tree decl;
{ {
tree context = decl_type_context (decl); tree context = decl_type_context (decl);
...@@ -2025,9 +1994,7 @@ dbxout_class_name_qualifiers (decl) ...@@ -2025,9 +1994,7 @@ dbxout_class_name_qualifiers (decl)
Return 1 if a stabs might have been emitted. */ Return 1 if a stabs might have been emitted. */
int int
dbxout_symbol (decl, local) dbxout_symbol (tree decl, int local ATTRIBUTE_UNUSED)
tree decl;
int local ATTRIBUTE_UNUSED;
{ {
tree type = TREE_TYPE (decl); tree type = TREE_TYPE (decl);
tree context = NULL_TREE; tree context = NULL_TREE;
...@@ -2369,10 +2336,7 @@ dbxout_symbol (decl, local) ...@@ -2369,10 +2336,7 @@ dbxout_symbol (decl, local)
Returns 1 if the stab was really emitted. */ Returns 1 if the stab was really emitted. */
static int static int
dbxout_symbol_location (decl, type, suffix, home) dbxout_symbol_location (tree decl, tree type, const char *suffix, rtx home)
tree decl, type;
const char *suffix;
rtx home;
{ {
int letter = 0; int letter = 0;
int regno = -1; int regno = -1;
...@@ -2605,10 +2569,7 @@ dbxout_symbol_location (decl, type, suffix, home) ...@@ -2605,10 +2569,7 @@ dbxout_symbol_location (decl, type, suffix, home)
Then output LETTER to indicate the kind of location the symbol has. */ Then output LETTER to indicate the kind of location the symbol has. */
static void static void
dbxout_symbol_name (decl, suffix, letter) dbxout_symbol_name (tree decl, const char *suffix, int letter)
tree decl;
const char *suffix;
int letter;
{ {
const char *name; const char *name;
...@@ -2633,8 +2594,7 @@ dbxout_symbol_name (decl, suffix, letter) ...@@ -2633,8 +2594,7 @@ dbxout_symbol_name (decl, suffix, letter)
} }
static void static void
dbxout_prepare_symbol (decl) dbxout_prepare_symbol (tree decl ATTRIBUTE_UNUSED)
tree decl ATTRIBUTE_UNUSED;
{ {
#ifdef WINNING_GDB #ifdef WINNING_GDB
const char *filename = DECL_SOURCE_FILE (decl); const char *filename = DECL_SOURCE_FILE (decl);
...@@ -2644,8 +2604,7 @@ dbxout_prepare_symbol (decl) ...@@ -2644,8 +2604,7 @@ dbxout_prepare_symbol (decl)
} }
static void static void
dbxout_finish_symbol (sym) dbxout_finish_symbol (tree sym)
tree sym;
{ {
#ifdef DBX_FINISH_SYMBOL #ifdef DBX_FINISH_SYMBOL
DBX_FINISH_SYMBOL (sym); DBX_FINISH_SYMBOL (sym);
...@@ -2667,8 +2626,7 @@ dbxout_finish_symbol (sym) ...@@ -2667,8 +2626,7 @@ dbxout_finish_symbol (sym)
anything was output */ anything was output */
int int
dbxout_syms (syms) dbxout_syms (tree syms)
tree syms;
{ {
int result = 0; int result = 0;
while (syms) while (syms)
...@@ -2692,8 +2650,7 @@ dbxout_syms (syms) ...@@ -2692,8 +2650,7 @@ dbxout_syms (syms)
of all the parms in PARMS, which is a chain of PARM_DECL nodes. */ of all the parms in PARMS, which is a chain of PARM_DECL nodes. */
void void
dbxout_parms (parms) dbxout_parms (tree parms)
tree parms;
{ {
++debug_nesting; ++debug_nesting;
...@@ -2969,8 +2926,7 @@ dbxout_parms (parms) ...@@ -2969,8 +2926,7 @@ dbxout_parms (parms)
PARMS is a chain of PARM_DECL nodes. */ PARMS is a chain of PARM_DECL nodes. */
void void
dbxout_reg_parms (parms) dbxout_reg_parms (tree parms)
tree parms;
{ {
++debug_nesting; ++debug_nesting;
...@@ -3001,8 +2957,7 @@ dbxout_reg_parms (parms) ...@@ -3001,8 +2957,7 @@ dbxout_reg_parms (parms)
output definitions of those names, in raw form */ output definitions of those names, in raw form */
static void static void
dbxout_args (args) dbxout_args (tree args)
tree args;
{ {
while (args) while (args)
{ {
...@@ -3031,10 +2986,7 @@ dbxout_args (args) ...@@ -3031,10 +2986,7 @@ dbxout_args (args)
We handle them all in sequence. */ We handle them all in sequence. */
static void static void
dbxout_block (block, depth, args) dbxout_block (tree block, int depth, tree args)
tree block;
int depth;
tree args;
{ {
int blocknum = -1; int blocknum = -1;
...@@ -3129,8 +3081,7 @@ dbxout_block (block, depth, args) ...@@ -3129,8 +3081,7 @@ dbxout_block (block, depth, args)
#if defined (DBX_DEBUGGING_INFO) #if defined (DBX_DEBUGGING_INFO)
static void static void
dbxout_begin_function (decl) dbxout_begin_function (tree decl)
tree decl;
{ {
int saved_tree_used1 = TREE_USED (decl); int saved_tree_used1 = TREE_USED (decl);
TREE_USED (decl) = 1; TREE_USED (decl) = 1;
......
/* Do-nothing debug hooks for GCC. /* Do-nothing debug hooks for GCC.
Copyright (C) 2001, 2002 Free Software Foundation, Inc. Copyright (C) 2001, 2002, 2003 Free Software Foundation, Inc.
This program is free software; you can redistribute it and/or modify it This program is free software; you can redistribute it and/or modify it
under the terms of the GNU General Public License as published by the under the terms of the GNU General Public License as published by the
...@@ -51,51 +51,44 @@ const struct gcc_debug_hooks do_nothing_debug_hooks = ...@@ -51,51 +51,44 @@ const struct gcc_debug_hooks do_nothing_debug_hooks =
nothing. */ nothing. */
void void
debug_nothing_void () debug_nothing_void (void)
{ {
} }
void void
debug_nothing_tree (decl) debug_nothing_tree (tree decl ATTRIBUTE_UNUSED)
tree decl ATTRIBUTE_UNUSED;
{ {
} }
bool bool
debug_true_tree (block) debug_true_tree (tree block ATTRIBUTE_UNUSED)
tree block ATTRIBUTE_UNUSED;
{ {
return true; return true;
} }
void void
debug_nothing_rtx (insn) debug_nothing_rtx (rtx insn ATTRIBUTE_UNUSED)
rtx insn ATTRIBUTE_UNUSED;
{ {
} }
void void
debug_nothing_charstar (main_filename) debug_nothing_charstar (const char *main_filename ATTRIBUTE_UNUSED)
const char *main_filename ATTRIBUTE_UNUSED;
{ {
} }
void void
debug_nothing_int_charstar (line, text) debug_nothing_int_charstar (unsigned int line ATTRIBUTE_UNUSED,
unsigned int line ATTRIBUTE_UNUSED; const char *text ATTRIBUTE_UNUSED)
const char *text ATTRIBUTE_UNUSED;
{ {
} }
void void
debug_nothing_int (line) debug_nothing_int (unsigned int line ATTRIBUTE_UNUSED)
unsigned int line ATTRIBUTE_UNUSED;
{ {
} }
void void
debug_nothing_int_int (line, n) debug_nothing_int_int (unsigned int line ATTRIBUTE_UNUSED,
unsigned int line ATTRIBUTE_UNUSED; unsigned int n ATTRIBUTE_UNUSED)
unsigned int n ATTRIBUTE_UNUSED;
{ {
} }
...@@ -201,113 +201,103 @@ static alloc_pool df_ref_pool; ...@@ -201,113 +201,103 @@ static alloc_pool df_ref_pool;
static alloc_pool df_link_pool; static alloc_pool df_link_pool;
static struct df *ddf; static struct df *ddf;
static void df_reg_table_realloc PARAMS((struct df *, int)); static void df_reg_table_realloc (struct df *, int);
static void df_insn_table_realloc PARAMS((struct df *, unsigned int)); static void df_insn_table_realloc (struct df *, unsigned int);
static void df_bitmaps_alloc PARAMS((struct df *, int)); static void df_bitmaps_alloc (struct df *, int);
static void df_bitmaps_free PARAMS((struct df *, int)); static void df_bitmaps_free (struct df *, int);
static void df_free PARAMS((struct df *)); static void df_free (struct df *);
static void df_alloc PARAMS((struct df *, int)); static void df_alloc (struct df *, int);
static rtx df_reg_clobber_gen PARAMS((unsigned int)); static rtx df_reg_clobber_gen (unsigned int);
static rtx df_reg_use_gen PARAMS((unsigned int)); static rtx df_reg_use_gen (unsigned int);
static inline struct df_link *df_link_create PARAMS((struct ref *, static inline struct df_link *df_link_create (struct ref *, struct df_link *);
struct df_link *)); static struct df_link *df_ref_unlink (struct df_link **, struct ref *);
static struct df_link *df_ref_unlink PARAMS((struct df_link **, struct ref *)); static void df_def_unlink (struct df *, struct ref *);
static void df_def_unlink PARAMS((struct df *, struct ref *)); static void df_use_unlink (struct df *, struct ref *);
static void df_use_unlink PARAMS((struct df *, struct ref *)); static void df_insn_refs_unlink (struct df *, basic_block, rtx);
static void df_insn_refs_unlink PARAMS ((struct df *, basic_block, rtx));
#if 0 #if 0
static void df_bb_refs_unlink PARAMS ((struct df *, basic_block)); static void df_bb_refs_unlink (struct df *, basic_block);
static void df_refs_unlink PARAMS ((struct df *, bitmap)); static void df_refs_unlink (struct df *, bitmap);
#endif #endif
static struct ref *df_ref_create PARAMS((struct df *, static struct ref *df_ref_create (struct df *, rtx, rtx *, rtx,
rtx, rtx *, rtx, enum df_ref_type, enum df_ref_flags);
enum df_ref_type, enum df_ref_flags)); static void df_ref_record_1 (struct df *, rtx, rtx *, rtx, enum df_ref_type,
static void df_ref_record_1 PARAMS((struct df *, rtx, rtx *, enum df_ref_flags);
rtx, enum df_ref_type, static void df_ref_record (struct df *, rtx, rtx *, rtx, enum df_ref_type,
enum df_ref_flags)); enum df_ref_flags);
static void df_ref_record PARAMS((struct df *, rtx, rtx *, static void df_def_record_1 (struct df *, rtx, basic_block, rtx);
rtx, enum df_ref_type, static void df_defs_record (struct df *, rtx, basic_block, rtx);
enum df_ref_flags)); static void df_uses_record (struct df *, rtx *, enum df_ref_type,
static void df_def_record_1 PARAMS((struct df *, rtx, basic_block, rtx)); basic_block, rtx, enum df_ref_flags);
static void df_defs_record PARAMS((struct df *, rtx, basic_block, rtx)); static void df_insn_refs_record (struct df *, basic_block, rtx);
static void df_uses_record PARAMS((struct df *, rtx *, static void df_bb_refs_record (struct df *, basic_block);
enum df_ref_type, basic_block, rtx, static void df_refs_record (struct df *, bitmap);
enum df_ref_flags));
static void df_insn_refs_record PARAMS((struct df *, basic_block, rtx)); static void df_bb_reg_def_chain_create (struct df *, basic_block);
static void df_bb_refs_record PARAMS((struct df *, basic_block)); static void df_reg_def_chain_create (struct df *, bitmap);
static void df_refs_record PARAMS((struct df *, bitmap)); static void df_bb_reg_use_chain_create (struct df *, basic_block);
static void df_reg_use_chain_create (struct df *, bitmap);
static void df_bb_reg_def_chain_create PARAMS((struct df *, basic_block)); static void df_bb_du_chain_create (struct df *, basic_block, bitmap);
static void df_reg_def_chain_create PARAMS((struct df *, bitmap)); static void df_du_chain_create (struct df *, bitmap);
static void df_bb_reg_use_chain_create PARAMS((struct df *, basic_block)); static void df_bb_ud_chain_create (struct df *, basic_block);
static void df_reg_use_chain_create PARAMS((struct df *, bitmap)); static void df_ud_chain_create (struct df *, bitmap);
static void df_bb_du_chain_create PARAMS((struct df *, basic_block, bitmap)); static void df_bb_rd_local_compute (struct df *, basic_block);
static void df_du_chain_create PARAMS((struct df *, bitmap)); static void df_rd_local_compute (struct df *, bitmap);
static void df_bb_ud_chain_create PARAMS((struct df *, basic_block)); static void df_bb_ru_local_compute (struct df *, basic_block);
static void df_ud_chain_create PARAMS((struct df *, bitmap)); static void df_ru_local_compute (struct df *, bitmap);
static void df_bb_rd_local_compute PARAMS((struct df *, basic_block)); static void df_bb_lr_local_compute (struct df *, basic_block);
static void df_rd_local_compute PARAMS((struct df *, bitmap)); static void df_lr_local_compute (struct df *, bitmap);
static void df_bb_ru_local_compute PARAMS((struct df *, basic_block)); static void df_bb_reg_info_compute (struct df *, basic_block, bitmap);
static void df_ru_local_compute PARAMS((struct df *, bitmap)); static void df_reg_info_compute (struct df *, bitmap);
static void df_bb_lr_local_compute PARAMS((struct df *, basic_block));
static void df_lr_local_compute PARAMS((struct df *, bitmap)); static int df_bb_luids_set (struct df *df, basic_block);
static void df_bb_reg_info_compute PARAMS((struct df *, basic_block, bitmap)); static int df_luids_set (struct df *df, bitmap);
static void df_reg_info_compute PARAMS((struct df *, bitmap));
static int df_modified_p (struct df *, bitmap);
static int df_bb_luids_set PARAMS((struct df *df, basic_block)); static int df_refs_queue (struct df *);
static int df_luids_set PARAMS((struct df *df, bitmap)); static int df_refs_process (struct df *);
static int df_bb_refs_update (struct df *, basic_block);
static int df_modified_p PARAMS ((struct df *, bitmap)); static int df_refs_update (struct df *);
static int df_refs_queue PARAMS ((struct df *)); static void df_analyse_1 (struct df *, bitmap, int, int);
static int df_refs_process PARAMS ((struct df *));
static int df_bb_refs_update PARAMS ((struct df *, basic_block)); static void df_insns_modify (struct df *, basic_block, rtx, rtx);
static int df_refs_update PARAMS ((struct df *)); static int df_rtx_mem_replace (rtx *, void *);
static void df_analyse_1 PARAMS((struct df *, bitmap, int, int)); static int df_rtx_reg_replace (rtx *, void *);
void df_refs_reg_replace (struct df *, bitmap, struct df_link *, rtx, rtx);
static void df_insns_modify PARAMS((struct df *, basic_block,
rtx, rtx)); static int df_def_dominates_all_uses_p (struct df *, struct ref *def);
static int df_rtx_mem_replace PARAMS ((rtx *, void *)); static int df_def_dominates_uses_p (struct df *, struct ref *def, bitmap);
static int df_rtx_reg_replace PARAMS ((rtx *, void *)); static struct ref *df_bb_regno_last_use_find (struct df *, basic_block,
void df_refs_reg_replace PARAMS ((struct df *, bitmap, unsigned int);
struct df_link *, rtx, rtx)); static struct ref *df_bb_regno_first_def_find (struct df *, basic_block,
unsigned int);
static int df_def_dominates_all_uses_p PARAMS((struct df *, struct ref *def)); static struct ref *df_bb_insn_regno_last_use_find (struct df *, basic_block,
static int df_def_dominates_uses_p PARAMS((struct df *, rtx, unsigned int);
struct ref *def, bitmap)); static struct ref *df_bb_insn_regno_first_def_find (struct df *, basic_block,
static struct ref *df_bb_regno_last_use_find PARAMS((struct df *, basic_block, rtx, unsigned int);
unsigned int));
static struct ref *df_bb_regno_first_def_find PARAMS((struct df *, basic_block, static void df_chain_dump (struct df_link *, FILE *file);
unsigned int)); static void df_chain_dump_regno (struct df_link *, FILE *file);
static struct ref *df_bb_insn_regno_last_use_find PARAMS((struct df *, static void df_regno_debug (struct df *, unsigned int, FILE *);
basic_block, static void df_ref_debug (struct df *, struct ref *, FILE *);
rtx, unsigned int)); static void df_rd_transfer_function (int, int *, bitmap, bitmap, bitmap,
static struct ref *df_bb_insn_regno_first_def_find PARAMS((struct df *, bitmap, void *);
basic_block, static void df_ru_transfer_function (int, int *, bitmap, bitmap, bitmap,
rtx, unsigned int)); bitmap, void *);
static void df_lr_transfer_function (int, int *, bitmap, bitmap, bitmap,
static void df_chain_dump PARAMS((struct df_link *, FILE *file)); bitmap, void *);
static void df_chain_dump_regno PARAMS((struct df_link *, FILE *file)); static void hybrid_search_bitmap (basic_block, bitmap *, bitmap *,
static void df_regno_debug PARAMS ((struct df *, unsigned int, FILE *));
static void df_ref_debug PARAMS ((struct df *, struct ref *, FILE *));
static void df_rd_transfer_function PARAMS ((int, int *, bitmap, bitmap,
bitmap, bitmap, void *));
static void df_ru_transfer_function PARAMS ((int, int *, bitmap, bitmap,
bitmap, bitmap, void *));
static void df_lr_transfer_function PARAMS ((int, int *, bitmap, bitmap,
bitmap, bitmap, void *));
static void hybrid_search_bitmap PARAMS ((basic_block, bitmap *, bitmap *,
bitmap *, bitmap *, enum df_flow_dir, bitmap *, bitmap *, enum df_flow_dir,
enum df_confluence_op, enum df_confluence_op,
transfer_function_bitmap, transfer_function_bitmap,
sbitmap, sbitmap, void *)); sbitmap, sbitmap, void *);
static void hybrid_search_sbitmap PARAMS ((basic_block, sbitmap *, sbitmap *, static void hybrid_search_sbitmap (basic_block, sbitmap *, sbitmap *,
sbitmap *, sbitmap *, enum df_flow_dir, sbitmap *, sbitmap *, enum df_flow_dir,
enum df_confluence_op, enum df_confluence_op,
transfer_function_sbitmap, transfer_function_sbitmap,
sbitmap, sbitmap, void *)); sbitmap, sbitmap, void *);
/* Local memory allocation/deallocation routines. */ /* Local memory allocation/deallocation routines. */
...@@ -316,9 +306,7 @@ static void hybrid_search_sbitmap PARAMS ((basic_block, sbitmap *, sbitmap *, ...@@ -316,9 +306,7 @@ static void hybrid_search_sbitmap PARAMS ((basic_block, sbitmap *, sbitmap *,
/* Increase the insn info table to have space for at least SIZE + 1 /* Increase the insn info table to have space for at least SIZE + 1
elements. */ elements. */
static void static void
df_insn_table_realloc (df, size) df_insn_table_realloc (struct df *df, unsigned int size)
struct df *df;
unsigned int size;
{ {
size++; size++;
if (size <= df->insn_size) if (size <= df->insn_size)
...@@ -346,9 +334,7 @@ df_insn_table_realloc (df, size) ...@@ -346,9 +334,7 @@ df_insn_table_realloc (df, size)
/* Increase the reg info table by SIZE more elements. */ /* Increase the reg info table by SIZE more elements. */
static void static void
df_reg_table_realloc (df, size) df_reg_table_realloc (struct df *df, int size)
struct df *df;
int size;
{ {
/* Make table 25 percent larger by default. */ /* Make table 25 percent larger by default. */
if (! size) if (! size)
...@@ -371,9 +357,7 @@ df_reg_table_realloc (df, size) ...@@ -371,9 +357,7 @@ df_reg_table_realloc (df, size)
/* Allocate bitmaps for each basic block. */ /* Allocate bitmaps for each basic block. */
static void static void
df_bitmaps_alloc (df, flags) df_bitmaps_alloc (struct df *df, int flags)
struct df *df;
int flags;
{ {
int dflags = 0; int dflags = 0;
basic_block bb; basic_block bb;
...@@ -438,9 +422,7 @@ df_bitmaps_alloc (df, flags) ...@@ -438,9 +422,7 @@ df_bitmaps_alloc (df, flags)
/* Free bitmaps for each basic block. */ /* Free bitmaps for each basic block. */
static void static void
df_bitmaps_free (df, flags) df_bitmaps_free (struct df *df, int flags)
struct df *df ATTRIBUTE_UNUSED;
int flags;
{ {
basic_block bb; basic_block bb;
...@@ -496,9 +478,7 @@ df_bitmaps_free (df, flags) ...@@ -496,9 +478,7 @@ df_bitmaps_free (df, flags)
/* Allocate and initialize dataflow memory. */ /* Allocate and initialize dataflow memory. */
static void static void
df_alloc (df, n_regs) df_alloc (struct df *df, int n_regs)
struct df *df;
int n_regs;
{ {
int n_insns; int n_insns;
basic_block bb; basic_block bb;
...@@ -548,8 +528,7 @@ df_alloc (df, n_regs) ...@@ -548,8 +528,7 @@ df_alloc (df, n_regs)
/* Free all the dataflow info. */ /* Free all the dataflow info. */
static void static void
df_free (df) df_free (struct df *df)
struct df *df;
{ {
df_bitmaps_free (df, DF_ALL); df_bitmaps_free (df, DF_ALL);
...@@ -598,8 +577,7 @@ df_free (df) ...@@ -598,8 +577,7 @@ df_free (df)
/* Local miscellaneous routines. */ /* Local miscellaneous routines. */
/* Return a USE for register REGNO. */ /* Return a USE for register REGNO. */
static rtx df_reg_use_gen (regno) static rtx df_reg_use_gen (unsigned int regno)
unsigned int regno;
{ {
rtx reg; rtx reg;
rtx use; rtx use;
...@@ -612,8 +590,7 @@ static rtx df_reg_use_gen (regno) ...@@ -612,8 +590,7 @@ static rtx df_reg_use_gen (regno)
/* Return a CLOBBER for register REGNO. */ /* Return a CLOBBER for register REGNO. */
static rtx df_reg_clobber_gen (regno) static rtx df_reg_clobber_gen (unsigned int regno)
unsigned int regno;
{ {
rtx reg; rtx reg;
rtx use; rtx use;
...@@ -628,9 +605,7 @@ static rtx df_reg_clobber_gen (regno) ...@@ -628,9 +605,7 @@ static rtx df_reg_clobber_gen (regno)
/* Create a link in a def-use or use-def chain. */ /* Create a link in a def-use or use-def chain. */
static inline struct df_link * static inline struct df_link *
df_link_create (ref, next) df_link_create (struct ref *ref, struct df_link *next)
struct ref *ref;
struct df_link *next;
{ {
struct df_link *link; struct df_link *link;
...@@ -643,9 +618,7 @@ df_link_create (ref, next) ...@@ -643,9 +618,7 @@ df_link_create (ref, next)
/* Add REF to chain head pointed to by PHEAD. */ /* Add REF to chain head pointed to by PHEAD. */
static struct df_link * static struct df_link *
df_ref_unlink (phead, ref) df_ref_unlink (struct df_link **phead, struct ref *ref)
struct df_link **phead;
struct ref *ref;
{ {
struct df_link *link = *phead; struct df_link *link = *phead;
...@@ -687,9 +660,7 @@ df_ref_unlink (phead, ref) ...@@ -687,9 +660,7 @@ df_ref_unlink (phead, ref)
/* Unlink REF from all def-use/use-def chains, etc. */ /* Unlink REF from all def-use/use-def chains, etc. */
int int
df_ref_remove (df, ref) df_ref_remove (struct df *df, struct ref *ref)
struct df *df;
struct ref *ref;
{ {
if (DF_REF_REG_DEF_P (ref)) if (DF_REF_REG_DEF_P (ref))
{ {
...@@ -707,9 +678,7 @@ df_ref_remove (df, ref) ...@@ -707,9 +678,7 @@ df_ref_remove (df, ref)
/* Unlink DEF from use-def and reg-def chains. */ /* Unlink DEF from use-def and reg-def chains. */
static void static void
df_def_unlink (df, def) df_def_unlink (struct df *df ATTRIBUTE_UNUSED, struct ref *def)
struct df *df ATTRIBUTE_UNUSED;
struct ref *def;
{ {
struct df_link *du_link; struct df_link *du_link;
unsigned int dregno = DF_REF_REGNO (def); unsigned int dregno = DF_REF_REGNO (def);
...@@ -733,9 +702,7 @@ df_def_unlink (df, def) ...@@ -733,9 +702,7 @@ df_def_unlink (df, def)
/* Unlink use from def-use and reg-use chains. */ /* Unlink use from def-use and reg-use chains. */
static void static void
df_use_unlink (df, use) df_use_unlink (struct df *df ATTRIBUTE_UNUSED, struct ref *use)
struct df *df ATTRIBUTE_UNUSED;
struct ref *use;
{ {
struct df_link *ud_link; struct df_link *ud_link;
unsigned int uregno = DF_REF_REGNO (use); unsigned int uregno = DF_REF_REGNO (use);
...@@ -762,13 +729,8 @@ df_use_unlink (df, use) ...@@ -762,13 +729,8 @@ df_use_unlink (df, use)
/* Create a new ref of type DF_REF_TYPE for register REG at address /* Create a new ref of type DF_REF_TYPE for register REG at address
LOC within INSN of BB. */ LOC within INSN of BB. */
static struct ref * static struct ref *
df_ref_create (df, reg, loc, insn, ref_type, ref_flags) df_ref_create (struct df *df, rtx reg, rtx *loc, rtx insn,
struct df *df; enum df_ref_type ref_type, enum df_ref_flags ref_flags)
rtx reg;
rtx *loc;
rtx insn;
enum df_ref_type ref_type;
enum df_ref_flags ref_flags;
{ {
struct ref *this_ref; struct ref *this_ref;
...@@ -811,13 +773,8 @@ df_ref_create (df, reg, loc, insn, ref_type, ref_flags) ...@@ -811,13 +773,8 @@ df_ref_create (df, reg, loc, insn, ref_type, ref_flags)
/* Create a new reference of type DF_REF_TYPE for a single register REG, /* Create a new reference of type DF_REF_TYPE for a single register REG,
used inside the LOC rtx of INSN. */ used inside the LOC rtx of INSN. */
static void static void
df_ref_record_1 (df, reg, loc, insn, ref_type, ref_flags) df_ref_record_1 (struct df *df, rtx reg, rtx *loc, rtx insn,
struct df *df; enum df_ref_type ref_type, enum df_ref_flags ref_flags)
rtx reg;
rtx *loc;
rtx insn;
enum df_ref_type ref_type;
enum df_ref_flags ref_flags;
{ {
df_ref_create (df, reg, loc, insn, ref_type, ref_flags); df_ref_create (df, reg, loc, insn, ref_type, ref_flags);
} }
...@@ -826,13 +783,8 @@ df_ref_record_1 (df, reg, loc, insn, ref_type, ref_flags) ...@@ -826,13 +783,8 @@ df_ref_record_1 (df, reg, loc, insn, ref_type, ref_flags)
/* Create new references of type DF_REF_TYPE for each part of register REG /* Create new references of type DF_REF_TYPE for each part of register REG
at address LOC within INSN of BB. */ at address LOC within INSN of BB. */
static void static void
df_ref_record (df, reg, loc, insn, ref_type, ref_flags) df_ref_record (struct df *df, rtx reg, rtx *loc, rtx insn,
struct df *df; enum df_ref_type ref_type, enum df_ref_flags ref_flags)
rtx reg;
rtx *loc;
rtx insn;
enum df_ref_type ref_type;
enum df_ref_flags ref_flags;
{ {
unsigned int regno; unsigned int regno;
...@@ -888,8 +840,7 @@ df_ref_record (df, reg, loc, insn, ref_type, ref_flags) ...@@ -888,8 +840,7 @@ df_ref_record (df, reg, loc, insn, ref_type, ref_flags)
/* Return nonzero if writes to paradoxical SUBREGs, or SUBREGs which /* Return nonzero if writes to paradoxical SUBREGs, or SUBREGs which
are too narrow, are read-modify-write. */ are too narrow, are read-modify-write. */
bool bool
read_modify_subreg_p (x) read_modify_subreg_p (rtx x)
rtx x;
{ {
unsigned int isize, osize; unsigned int isize, osize;
if (GET_CODE (x) != SUBREG) if (GET_CODE (x) != SUBREG)
...@@ -903,11 +854,7 @@ read_modify_subreg_p (x) ...@@ -903,11 +854,7 @@ read_modify_subreg_p (x)
/* Process all the registers defined in the rtx, X. */ /* Process all the registers defined in the rtx, X. */
static void static void
df_def_record_1 (df, x, bb, insn) df_def_record_1 (struct df *df, rtx x, basic_block bb, rtx insn)
struct df *df;
rtx x;
basic_block bb;
rtx insn;
{ {
rtx *loc; rtx *loc;
rtx dst; rtx dst;
...@@ -937,13 +884,6 @@ df_def_record_1 (df, x, bb, insn) ...@@ -937,13 +884,6 @@ df_def_record_1 (df, x, bb, insn)
return; return;
} }
#ifdef CLASS_CANNOT_CHANGE_MODE
if (GET_CODE (dst) == SUBREG
&& CLASS_CANNOT_CHANGE_MODE_P (GET_MODE (dst),
GET_MODE (SUBREG_REG (dst))))
flags |= DF_REF_MODE_CHANGE;
#endif
/* Maybe, we should flag the use of STRICT_LOW_PART somehow. It might /* Maybe, we should flag the use of STRICT_LOW_PART somehow. It might
be handy for the reg allocator. */ be handy for the reg allocator. */
while (GET_CODE (dst) == STRICT_LOW_PART while (GET_CODE (dst) == STRICT_LOW_PART
...@@ -959,12 +899,6 @@ df_def_record_1 (df, x, bb, insn) ...@@ -959,12 +899,6 @@ df_def_record_1 (df, x, bb, insn)
loc = &XEXP (dst, 0); loc = &XEXP (dst, 0);
dst = *loc; dst = *loc;
} }
#ifdef CLASS_CANNOT_CHANGE_MODE
if (GET_CODE (dst) == SUBREG
&& CLASS_CANNOT_CHANGE_MODE_P (GET_MODE (dst),
GET_MODE (SUBREG_REG (dst))))
flags |= DF_REF_MODE_CHANGE;
#endif
loc = &XEXP (dst, 0); loc = &XEXP (dst, 0);
dst = *loc; dst = *loc;
flags |= DF_REF_READ_WRITE; flags |= DF_REF_READ_WRITE;
...@@ -978,11 +912,7 @@ df_def_record_1 (df, x, bb, insn) ...@@ -978,11 +912,7 @@ df_def_record_1 (df, x, bb, insn)
/* Process all the registers defined in the pattern rtx, X. */ /* Process all the registers defined in the pattern rtx, X. */
static void static void
df_defs_record (df, x, bb, insn) df_defs_record (struct df *df, rtx x, basic_block bb, rtx insn)
struct df *df;
rtx x;
basic_block bb;
rtx insn;
{ {
RTX_CODE code = GET_CODE (x); RTX_CODE code = GET_CODE (x);
...@@ -1008,13 +938,8 @@ df_defs_record (df, x, bb, insn) ...@@ -1008,13 +938,8 @@ df_defs_record (df, x, bb, insn)
/* Process all the registers used in the rtx at address LOC. */ /* Process all the registers used in the rtx at address LOC. */
static void static void
df_uses_record (df, loc, ref_type, bb, insn, flags) df_uses_record (struct df *df, rtx *loc, enum df_ref_type ref_type,
struct df *df; basic_block bb, rtx insn, enum df_ref_flags flags)
rtx *loc;
enum df_ref_type ref_type;
basic_block bb;
rtx insn;
enum df_ref_flags flags;
{ {
RTX_CODE code; RTX_CODE code;
rtx x; rtx x;
...@@ -1061,12 +986,6 @@ df_uses_record (df, loc, ref_type, bb, insn, flags) ...@@ -1061,12 +986,6 @@ df_uses_record (df, loc, ref_type, bb, insn, flags)
df_uses_record (df, loc, ref_type, bb, insn, flags); df_uses_record (df, loc, ref_type, bb, insn, flags);
return; return;
} }
#ifdef CLASS_CANNOT_CHANGE_MODE
if (CLASS_CANNOT_CHANGE_MODE_P (GET_MODE (x),
GET_MODE (SUBREG_REG (x))))
flags |= DF_REF_MODE_CHANGE;
#endif
/* ... Fall through ... */ /* ... Fall through ... */
case REG: case REG:
...@@ -1088,11 +1007,6 @@ df_uses_record (df, loc, ref_type, bb, insn, flags) ...@@ -1088,11 +1007,6 @@ df_uses_record (df, loc, ref_type, bb, insn, flags)
&& read_modify_subreg_p (dst)) && read_modify_subreg_p (dst))
{ {
use_flags = DF_REF_READ_WRITE; use_flags = DF_REF_READ_WRITE;
#ifdef CLASS_CANNOT_CHANGE_MODE
if (CLASS_CANNOT_CHANGE_MODE_P (GET_MODE (dst),
GET_MODE (SUBREG_REG (dst))))
use_flags |= DF_REF_MODE_CHANGE;
#endif
df_uses_record (df, &SUBREG_REG (dst), DF_REF_REG_USE, bb, df_uses_record (df, &SUBREG_REG (dst), DF_REF_REG_USE, bb,
insn, use_flags); insn, use_flags);
break; break;
...@@ -1114,11 +1028,6 @@ df_uses_record (df, loc, ref_type, bb, insn, flags) ...@@ -1114,11 +1028,6 @@ df_uses_record (df, loc, ref_type, bb, insn, flags)
if (GET_CODE (dst) != SUBREG) if (GET_CODE (dst) != SUBREG)
abort (); abort ();
use_flags = DF_REF_READ_WRITE; use_flags = DF_REF_READ_WRITE;
#ifdef CLASS_CANNOT_CHANGE_MODE
if (CLASS_CANNOT_CHANGE_MODE_P (GET_MODE (dst),
GET_MODE (SUBREG_REG (dst))))
use_flags |= DF_REF_MODE_CHANGE;
#endif
df_uses_record (df, &SUBREG_REG (dst), DF_REF_REG_USE, bb, df_uses_record (df, &SUBREG_REG (dst), DF_REF_REG_USE, bb,
insn, use_flags); insn, use_flags);
break; break;
...@@ -1217,10 +1126,7 @@ df_uses_record (df, loc, ref_type, bb, insn, flags) ...@@ -1217,10 +1126,7 @@ df_uses_record (df, loc, ref_type, bb, insn, flags)
/* Record all the df within INSN of basic block BB. */ /* Record all the df within INSN of basic block BB. */
static void static void
df_insn_refs_record (df, bb, insn) df_insn_refs_record (struct df *df, basic_block bb, rtx insn)
struct df *df;
basic_block bb;
rtx insn;
{ {
int i; int i;
...@@ -1310,9 +1216,7 @@ df_insn_refs_record (df, bb, insn) ...@@ -1310,9 +1216,7 @@ df_insn_refs_record (df, bb, insn)
/* Record all the refs within the basic block BB. */ /* Record all the refs within the basic block BB. */
static void static void
df_bb_refs_record (df, bb) df_bb_refs_record (struct df *df, basic_block bb)
struct df *df;
basic_block bb;
{ {
rtx insn; rtx insn;
...@@ -1332,9 +1236,7 @@ df_bb_refs_record (df, bb) ...@@ -1332,9 +1236,7 @@ df_bb_refs_record (df, bb)
/* Record all the refs in the basic blocks specified by BLOCKS. */ /* Record all the refs in the basic blocks specified by BLOCKS. */
static void static void
df_refs_record (df, blocks) df_refs_record (struct df *df, bitmap blocks)
struct df *df;
bitmap blocks;
{ {
basic_block bb; basic_block bb;
...@@ -1350,9 +1252,7 @@ df_refs_record (df, blocks) ...@@ -1350,9 +1252,7 @@ df_refs_record (df, blocks)
/* Create reg-def chains for basic block BB. These are a list of /* Create reg-def chains for basic block BB. These are a list of
definitions for each register. */ definitions for each register. */
static void static void
df_bb_reg_def_chain_create (df, bb) df_bb_reg_def_chain_create (struct df *df, basic_block bb)
struct df *df;
basic_block bb;
{ {
rtx insn; rtx insn;
...@@ -1392,9 +1292,7 @@ df_bb_reg_def_chain_create (df, bb) ...@@ -1392,9 +1292,7 @@ df_bb_reg_def_chain_create (df, bb)
/* Create reg-def chains for each basic block within BLOCKS. These /* Create reg-def chains for each basic block within BLOCKS. These
are a list of definitions for each register. */ are a list of definitions for each register. */
static void static void
df_reg_def_chain_create (df, blocks) df_reg_def_chain_create (struct df *df, bitmap blocks)
struct df *df;
bitmap blocks;
{ {
basic_block bb; basic_block bb;
...@@ -1408,9 +1306,7 @@ df_reg_def_chain_create (df, blocks) ...@@ -1408,9 +1306,7 @@ df_reg_def_chain_create (df, blocks)
/* Create reg-use chains for basic block BB. These are a list of uses /* Create reg-use chains for basic block BB. These are a list of uses
for each register. */ for each register. */
static void static void
df_bb_reg_use_chain_create (df, bb) df_bb_reg_use_chain_create (struct df *df, basic_block bb)
struct df *df;
basic_block bb;
{ {
rtx insn; rtx insn;
...@@ -1448,9 +1344,7 @@ df_bb_reg_use_chain_create (df, bb) ...@@ -1448,9 +1344,7 @@ df_bb_reg_use_chain_create (df, bb)
/* Create reg-use chains for each basic block within BLOCKS. These /* Create reg-use chains for each basic block within BLOCKS. These
are a list of uses for each register. */ are a list of uses for each register. */
static void static void
df_reg_use_chain_create (df, blocks) df_reg_use_chain_create (struct df *df, bitmap blocks)
struct df *df;
bitmap blocks;
{ {
basic_block bb; basic_block bb;
...@@ -1463,10 +1357,7 @@ df_reg_use_chain_create (df, blocks) ...@@ -1463,10 +1357,7 @@ df_reg_use_chain_create (df, blocks)
/* Create def-use chains from reaching use bitmaps for basic block BB. */ /* Create def-use chains from reaching use bitmaps for basic block BB. */
static void static void
df_bb_du_chain_create (df, bb, ru) df_bb_du_chain_create (struct df *df, basic_block bb, bitmap ru)
struct df *df;
basic_block bb;
bitmap ru;
{ {
struct bb_info *bb_info = DF_BB_INFO (df, bb); struct bb_info *bb_info = DF_BB_INFO (df, bb);
rtx insn; rtx insn;
...@@ -1524,9 +1415,7 @@ df_bb_du_chain_create (df, bb, ru) ...@@ -1524,9 +1415,7 @@ df_bb_du_chain_create (df, bb, ru)
/* Create def-use chains from reaching use bitmaps for basic blocks /* Create def-use chains from reaching use bitmaps for basic blocks
in BLOCKS. */ in BLOCKS. */
static void static void
df_du_chain_create (df, blocks) df_du_chain_create (struct df *df, bitmap blocks)
struct df *df;
bitmap blocks;
{ {
bitmap ru; bitmap ru;
basic_block bb; basic_block bb;
...@@ -1544,9 +1433,7 @@ df_du_chain_create (df, blocks) ...@@ -1544,9 +1433,7 @@ df_du_chain_create (df, blocks)
/* Create use-def chains from reaching def bitmaps for basic block BB. */ /* Create use-def chains from reaching def bitmaps for basic block BB. */
static void static void
df_bb_ud_chain_create (df, bb) df_bb_ud_chain_create (struct df *df, basic_block bb)
struct df *df;
basic_block bb;
{ {
struct bb_info *bb_info = DF_BB_INFO (df, bb); struct bb_info *bb_info = DF_BB_INFO (df, bb);
struct ref **reg_def_last = df->reg_def_last; struct ref **reg_def_last = df->reg_def_last;
...@@ -1620,9 +1507,7 @@ df_bb_ud_chain_create (df, bb) ...@@ -1620,9 +1507,7 @@ df_bb_ud_chain_create (df, bb)
/* Create use-def chains from reaching def bitmaps for basic blocks /* Create use-def chains from reaching def bitmaps for basic blocks
within BLOCKS. */ within BLOCKS. */
static void static void
df_ud_chain_create (df, blocks) df_ud_chain_create (struct df *df, bitmap blocks)
struct df *df;
bitmap blocks;
{ {
basic_block bb; basic_block bb;
...@@ -1635,33 +1520,27 @@ df_ud_chain_create (df, blocks) ...@@ -1635,33 +1520,27 @@ df_ud_chain_create (df, blocks)
static void static void
df_rd_transfer_function (bb, changed, in, out, gen, kill, data) df_rd_transfer_function (int bb ATTRIBUTE_UNUSED, int *changed, bitmap in,
int bb ATTRIBUTE_UNUSED; bitmap out, bitmap gen, bitmap kill,
int *changed; void *data ATTRIBUTE_UNUSED)
bitmap in, out, gen, kill;
void *data ATTRIBUTE_UNUSED;
{ {
*changed = bitmap_union_of_diff (out, gen, in, kill); *changed = bitmap_union_of_diff (out, gen, in, kill);
} }
static void static void
df_ru_transfer_function (bb, changed, in, out, gen, kill, data) df_ru_transfer_function (int bb ATTRIBUTE_UNUSED, int *changed, bitmap in,
int bb ATTRIBUTE_UNUSED; bitmap out, bitmap gen, bitmap kill,
int *changed; void *data ATTRIBUTE_UNUSED)
bitmap in, out, gen, kill;
void *data ATTRIBUTE_UNUSED;
{ {
*changed = bitmap_union_of_diff (in, gen, out, kill); *changed = bitmap_union_of_diff (in, gen, out, kill);
} }
static void static void
df_lr_transfer_function (bb, changed, in, out, use, def, data) df_lr_transfer_function (int bb ATTRIBUTE_UNUSED, int *changed, bitmap in,
int bb ATTRIBUTE_UNUSED; bitmap out, bitmap use, bitmap def,
int *changed; void *data ATTRIBUTE_UNUSED)
bitmap in, out, use, def;
void *data ATTRIBUTE_UNUSED;
{ {
*changed = bitmap_union_of_diff (in, use, out, def); *changed = bitmap_union_of_diff (in, use, out, def);
} }
...@@ -1669,9 +1548,7 @@ df_lr_transfer_function (bb, changed, in, out, use, def, data) ...@@ -1669,9 +1548,7 @@ df_lr_transfer_function (bb, changed, in, out, use, def, data)
/* Compute local reaching def info for basic block BB. */ /* Compute local reaching def info for basic block BB. */
static void static void
df_bb_rd_local_compute (df, bb) df_bb_rd_local_compute (struct df *df, basic_block bb)
struct df *df;
basic_block bb;
{ {
struct bb_info *bb_info = DF_BB_INFO (df, bb); struct bb_info *bb_info = DF_BB_INFO (df, bb);
rtx insn; rtx insn;
...@@ -1716,9 +1593,7 @@ df_bb_rd_local_compute (df, bb) ...@@ -1716,9 +1593,7 @@ df_bb_rd_local_compute (df, bb)
/* Compute local reaching def info for each basic block within BLOCKS. */ /* Compute local reaching def info for each basic block within BLOCKS. */
static void static void
df_rd_local_compute (df, blocks) df_rd_local_compute (struct df *df, bitmap blocks)
struct df *df;
bitmap blocks;
{ {
basic_block bb; basic_block bb;
...@@ -1732,9 +1607,7 @@ df_rd_local_compute (df, blocks) ...@@ -1732,9 +1607,7 @@ df_rd_local_compute (df, blocks)
/* Compute local reaching use (upward exposed use) info for basic /* Compute local reaching use (upward exposed use) info for basic
block BB. */ block BB. */
static void static void
df_bb_ru_local_compute (df, bb) df_bb_ru_local_compute (struct df *df, basic_block bb)
struct df *df;
basic_block bb;
{ {
/* This is much more tricky than computing reaching defs. With /* This is much more tricky than computing reaching defs. With
reaching defs, defs get killed by other defs. With upwards reaching defs, defs get killed by other defs. With upwards
...@@ -1789,9 +1662,7 @@ df_bb_ru_local_compute (df, bb) ...@@ -1789,9 +1662,7 @@ df_bb_ru_local_compute (df, bb)
/* Compute local reaching use (upward exposed use) info for each basic /* Compute local reaching use (upward exposed use) info for each basic
block within BLOCKS. */ block within BLOCKS. */
static void static void
df_ru_local_compute (df, blocks) df_ru_local_compute (struct df *df, bitmap blocks)
struct df *df;
bitmap blocks;
{ {
basic_block bb; basic_block bb;
...@@ -1804,9 +1675,7 @@ df_ru_local_compute (df, blocks) ...@@ -1804,9 +1675,7 @@ df_ru_local_compute (df, blocks)
/* Compute local live variable info for basic block BB. */ /* Compute local live variable info for basic block BB. */
static void static void
df_bb_lr_local_compute (df, bb) df_bb_lr_local_compute (struct df *df, basic_block bb)
struct df *df;
basic_block bb;
{ {
struct bb_info *bb_info = DF_BB_INFO (df, bb); struct bb_info *bb_info = DF_BB_INFO (df, bb);
rtx insn; rtx insn;
...@@ -1844,9 +1713,7 @@ df_bb_lr_local_compute (df, bb) ...@@ -1844,9 +1713,7 @@ df_bb_lr_local_compute (df, bb)
/* Compute local live variable info for each basic block within BLOCKS. */ /* Compute local live variable info for each basic block within BLOCKS. */
static void static void
df_lr_local_compute (df, blocks) df_lr_local_compute (struct df *df, bitmap blocks)
struct df *df;
bitmap blocks;
{ {
basic_block bb; basic_block bb;
...@@ -1860,10 +1727,7 @@ df_lr_local_compute (df, blocks) ...@@ -1860,10 +1727,7 @@ df_lr_local_compute (df, blocks)
/* Compute register info: lifetime, bb, and number of defs and uses /* Compute register info: lifetime, bb, and number of defs and uses
for basic block BB. */ for basic block BB. */
static void static void
df_bb_reg_info_compute (df, bb, live) df_bb_reg_info_compute (struct df *df, basic_block bb, bitmap live)
struct df *df;
basic_block bb;
bitmap live;
{ {
struct reg_info *reg_info = df->regs; struct reg_info *reg_info = df->regs;
struct bb_info *bb_info = DF_BB_INFO (df, bb); struct bb_info *bb_info = DF_BB_INFO (df, bb);
...@@ -1912,9 +1776,7 @@ df_bb_reg_info_compute (df, bb, live) ...@@ -1912,9 +1776,7 @@ df_bb_reg_info_compute (df, bb, live)
/* Compute register info: lifetime, bb, and number of defs and uses. */ /* Compute register info: lifetime, bb, and number of defs and uses. */
static void static void
df_reg_info_compute (df, blocks) df_reg_info_compute (struct df *df, bitmap blocks)
struct df *df;
bitmap blocks;
{ {
basic_block bb; basic_block bb;
bitmap live; bitmap live;
...@@ -1932,9 +1794,7 @@ df_reg_info_compute (df, blocks) ...@@ -1932,9 +1794,7 @@ df_reg_info_compute (df, blocks)
/* Assign LUIDs for BB. */ /* Assign LUIDs for BB. */
static int static int
df_bb_luids_set (df, bb) df_bb_luids_set (struct df *df, basic_block bb)
struct df *df;
basic_block bb;
{ {
rtx insn; rtx insn;
int luid = 0; int luid = 0;
...@@ -1956,9 +1816,7 @@ df_bb_luids_set (df, bb) ...@@ -1956,9 +1816,7 @@ df_bb_luids_set (df, bb)
/* Assign LUIDs for each basic block within BLOCKS. */ /* Assign LUIDs for each basic block within BLOCKS. */
static int static int
df_luids_set (df, blocks) df_luids_set (struct df *df, bitmap blocks)
struct df *df;
bitmap blocks;
{ {
basic_block bb; basic_block bb;
int total = 0; int total = 0;
...@@ -1974,11 +1832,7 @@ df_luids_set (df, blocks) ...@@ -1974,11 +1832,7 @@ df_luids_set (df, blocks)
/* Perform dataflow analysis using existing DF structure for blocks /* Perform dataflow analysis using existing DF structure for blocks
within BLOCKS. If BLOCKS is zero, use all basic blocks in the CFG. */ within BLOCKS. If BLOCKS is zero, use all basic blocks in the CFG. */
static void static void
df_analyse_1 (df, blocks, flags, update) df_analyse_1 (struct df *df, bitmap blocks, int flags, int update)
struct df *df;
bitmap blocks;
int flags;
int update;
{ {
int aflags; int aflags;
int dflags; int dflags;
...@@ -2180,7 +2034,7 @@ df_analyse_1 (df, blocks, flags, update) ...@@ -2180,7 +2034,7 @@ df_analyse_1 (df, blocks, flags, update)
/* Initialize dataflow analysis. */ /* Initialize dataflow analysis. */
struct df * struct df *
df_init () df_init (void)
{ {
struct df *df; struct df *df;
...@@ -2195,8 +2049,7 @@ df_init () ...@@ -2195,8 +2049,7 @@ df_init ()
/* Start queuing refs. */ /* Start queuing refs. */
static int static int
df_refs_queue (df) df_refs_queue (struct df *df)
struct df *df;
{ {
df->def_id_save = df->def_id; df->def_id_save = df->def_id;
df->use_id_save = df->use_id; df->use_id_save = df->use_id;
...@@ -2208,8 +2061,7 @@ df_refs_queue (df) ...@@ -2208,8 +2061,7 @@ df_refs_queue (df)
/* Process queued refs. */ /* Process queued refs. */
static int static int
df_refs_process (df) df_refs_process (struct df *df)
struct df *df;
{ {
unsigned int i; unsigned int i;
...@@ -2240,9 +2092,7 @@ df_refs_process (df) ...@@ -2240,9 +2092,7 @@ df_refs_process (df)
/* Update refs for basic block BB. */ /* Update refs for basic block BB. */
static int static int
df_bb_refs_update (df, bb) df_bb_refs_update (struct df *df, basic_block bb)
struct df *df;
basic_block bb;
{ {
rtx insn; rtx insn;
int count = 0; int count = 0;
...@@ -2277,8 +2127,7 @@ df_bb_refs_update (df, bb) ...@@ -2277,8 +2127,7 @@ df_bb_refs_update (df, bb)
/* Process all the modified/deleted insns that were queued. */ /* Process all the modified/deleted insns that were queued. */
static int static int
df_refs_update (df) df_refs_update (struct df *df)
struct df *df;
{ {
basic_block bb; basic_block bb;
int count = 0; int count = 0;
...@@ -2301,9 +2150,7 @@ df_refs_update (df) ...@@ -2301,9 +2150,7 @@ df_refs_update (df)
/* Return nonzero if any of the requested blocks in the bitmap /* Return nonzero if any of the requested blocks in the bitmap
BLOCKS have been modified. */ BLOCKS have been modified. */
static int static int
df_modified_p (df, blocks) df_modified_p (struct df *df, bitmap blocks)
struct df *df;
bitmap blocks;
{ {
int update = 0; int update = 0;
basic_block bb; basic_block bb;
...@@ -2327,10 +2174,7 @@ df_modified_p (df, blocks) ...@@ -2327,10 +2174,7 @@ df_modified_p (df, blocks)
BLOCKS, or for the whole CFG if BLOCKS is zero, or just for the BLOCKS, or for the whole CFG if BLOCKS is zero, or just for the
modified blocks if BLOCKS is -1. */ modified blocks if BLOCKS is -1. */
int int
df_analyse (df, blocks, flags) df_analyse (struct df *df, bitmap blocks, int flags)
struct df *df;
bitmap blocks;
int flags;
{ {
int update; int update;
...@@ -2373,8 +2217,7 @@ df_analyse (df, blocks, flags) ...@@ -2373,8 +2217,7 @@ df_analyse (df, blocks, flags)
/* Free all the dataflow info and the DF structure. */ /* Free all the dataflow info and the DF structure. */
void void
df_finish (df) df_finish (struct df *df)
struct df *df;
{ {
df_free (df); df_free (df);
free (df); free (df);
...@@ -2383,10 +2226,7 @@ df_finish (df) ...@@ -2383,10 +2226,7 @@ df_finish (df)
/* Unlink INSN from its reference information. */ /* Unlink INSN from its reference information. */
static void static void
df_insn_refs_unlink (df, bb, insn) df_insn_refs_unlink (struct df *df, basic_block bb ATTRIBUTE_UNUSED, rtx insn)
struct df *df;
basic_block bb ATTRIBUTE_UNUSED;
rtx insn;
{ {
struct df_link *link; struct df_link *link;
unsigned int uid; unsigned int uid;
...@@ -2409,9 +2249,7 @@ df_insn_refs_unlink (df, bb, insn) ...@@ -2409,9 +2249,7 @@ df_insn_refs_unlink (df, bb, insn)
#if 0 #if 0
/* Unlink all the insns within BB from their reference information. */ /* Unlink all the insns within BB from their reference information. */
static void static void
df_bb_refs_unlink (df, bb) df_bb_refs_unlink (struct df *df, basic_block bb)
struct df *df;
basic_block bb;
{ {
rtx insn; rtx insn;
...@@ -2432,9 +2270,7 @@ df_bb_refs_unlink (df, bb) ...@@ -2432,9 +2270,7 @@ df_bb_refs_unlink (df, bb)
/* Unlink all the refs in the basic blocks specified by BLOCKS. /* Unlink all the refs in the basic blocks specified by BLOCKS.
Not currently used. */ Not currently used. */
static void static void
df_refs_unlink (df, blocks) df_refs_unlink (struct df *df, bitmap blocks)
struct df *df;
bitmap blocks;
{ {
basic_block bb; basic_block bb;
...@@ -2458,10 +2294,7 @@ df_refs_unlink (df, blocks) ...@@ -2458,10 +2294,7 @@ df_refs_unlink (df, blocks)
/* Delete INSN and all its reference information. */ /* Delete INSN and all its reference information. */
rtx rtx
df_insn_delete (df, bb, insn) df_insn_delete (struct df *df, basic_block bb ATTRIBUTE_UNUSED, rtx insn)
struct df *df;
basic_block bb ATTRIBUTE_UNUSED;
rtx insn;
{ {
/* If the insn is a jump, we should perhaps call delete_insn to /* If the insn is a jump, we should perhaps call delete_insn to
handle the JUMP_LABEL? */ handle the JUMP_LABEL? */
...@@ -2484,10 +2317,7 @@ df_insn_delete (df, bb, insn) ...@@ -2484,10 +2317,7 @@ df_insn_delete (df, bb, insn)
harm calling this function if the insn wasn't changed; it will just harm calling this function if the insn wasn't changed; it will just
slow down the rescanning of refs. */ slow down the rescanning of refs. */
void void
df_insn_modify (df, bb, insn) df_insn_modify (struct df *df, basic_block bb, rtx insn)
struct df *df;
basic_block bb;
rtx insn;
{ {
unsigned int uid; unsigned int uid;
...@@ -2520,9 +2350,7 @@ typedef struct replace_args ...@@ -2520,9 +2350,7 @@ typedef struct replace_args
instruction currently being scanned and the MEM we are currently instruction currently being scanned and the MEM we are currently
replacing. */ replacing. */
static int static int
df_rtx_mem_replace (px, data) df_rtx_mem_replace (rtx *px, void *data)
rtx *px;
void *data;
{ {
replace_args *args = (replace_args *) data; replace_args *args = (replace_args *) data;
rtx mem = *px; rtx mem = *px;
...@@ -2558,12 +2386,7 @@ df_rtx_mem_replace (px, data) ...@@ -2558,12 +2386,7 @@ df_rtx_mem_replace (px, data)
int int
df_insn_mem_replace (df, bb, insn, mem, reg) df_insn_mem_replace (struct df *df, basic_block bb, rtx insn, rtx mem, rtx reg)
struct df *df;
basic_block bb;
rtx insn;
rtx mem;
rtx reg;
{ {
replace_args args; replace_args args;
...@@ -2591,9 +2414,7 @@ df_insn_mem_replace (df, bb, insn, mem, reg) ...@@ -2591,9 +2414,7 @@ df_insn_mem_replace (df, bb, insn, mem, reg)
points to the rtx being scanned. DATA is actually a pointer to a points to the rtx being scanned. DATA is actually a pointer to a
structure of arguments. */ structure of arguments. */
static int static int
df_rtx_reg_replace (px, data) df_rtx_reg_replace (rtx *px, void *data)
rtx *px;
void *data;
{ {
rtx x = *px; rtx x = *px;
replace_args *args = (replace_args *) data; replace_args *args = (replace_args *) data;
...@@ -2615,12 +2436,7 @@ df_rtx_reg_replace (px, data) ...@@ -2615,12 +2436,7 @@ df_rtx_reg_replace (px, data)
BLOCKS of basic blocks with NEWREG. Also update the regs within BLOCKS of basic blocks with NEWREG. Also update the regs within
REG_NOTES. */ REG_NOTES. */
void void
df_refs_reg_replace (df, blocks, chain, oldreg, newreg) df_refs_reg_replace (struct df *df, bitmap blocks, struct df_link *chain, rtx oldreg, rtx newreg)
struct df *df;
bitmap blocks;
struct df_link *chain;
rtx oldreg;
rtx newreg;
{ {
struct df_link *link; struct df_link *link;
replace_args args; replace_args args;
...@@ -2668,11 +2484,7 @@ df_refs_reg_replace (df, blocks, chain, oldreg, newreg) ...@@ -2668,11 +2484,7 @@ df_refs_reg_replace (df, blocks, chain, oldreg, newreg)
OLDREG in the REG_NOTES but only for insns containing OLDREG. This OLDREG in the REG_NOTES but only for insns containing OLDREG. This
routine expects the reg-use and reg-def chains to be valid. */ routine expects the reg-use and reg-def chains to be valid. */
int int
df_reg_replace (df, blocks, oldreg, newreg) df_reg_replace (struct df *df, bitmap blocks, rtx oldreg, rtx newreg)
struct df *df;
bitmap blocks;
rtx oldreg;
rtx newreg;
{ {
unsigned int oldregno = REGNO (oldreg); unsigned int oldregno = REGNO (oldreg);
...@@ -2685,11 +2497,7 @@ df_reg_replace (df, blocks, oldreg, newreg) ...@@ -2685,11 +2497,7 @@ df_reg_replace (df, blocks, oldreg, newreg)
/* Try replacing the reg within REF with NEWREG. Do not modify /* Try replacing the reg within REF with NEWREG. Do not modify
def-use/use-def chains. */ def-use/use-def chains. */
int int
df_ref_reg_replace (df, ref, oldreg, newreg) df_ref_reg_replace (struct df *df, struct ref *ref, rtx oldreg, rtx newreg)
struct df *df;
struct ref *ref;
rtx oldreg;
rtx newreg;
{ {
/* Check that insn was deleted by being converted into a NOTE. If /* Check that insn was deleted by being converted into a NOTE. If
so ignore this insn. */ so ignore this insn. */
...@@ -2708,12 +2516,7 @@ df_ref_reg_replace (df, ref, oldreg, newreg) ...@@ -2708,12 +2516,7 @@ df_ref_reg_replace (df, ref, oldreg, newreg)
struct ref* struct ref*
df_bb_def_use_swap (df, bb, def_insn, use_insn, regno) df_bb_def_use_swap (struct df *df, basic_block bb, rtx def_insn, rtx use_insn, unsigned int regno)
struct df * df;
basic_block bb;
rtx def_insn;
rtx use_insn;
unsigned int regno;
{ {
struct ref *def; struct ref *def;
struct ref *use; struct ref *use;
...@@ -2757,11 +2560,7 @@ df_bb_def_use_swap (df, bb, def_insn, use_insn, regno) ...@@ -2757,11 +2560,7 @@ df_bb_def_use_swap (df, bb, def_insn, use_insn, regno)
/* Record df between FIRST_INSN and LAST_INSN inclusive. All new /* Record df between FIRST_INSN and LAST_INSN inclusive. All new
insns must be processed by this routine. */ insns must be processed by this routine. */
static void static void
df_insns_modify (df, bb, first_insn, last_insn) df_insns_modify (struct df *df, basic_block bb, rtx first_insn, rtx last_insn)
struct df *df;
basic_block bb;
rtx first_insn;
rtx last_insn;
{ {
rtx insn; rtx insn;
...@@ -2792,11 +2591,7 @@ df_insns_modify (df, bb, first_insn, last_insn) ...@@ -2792,11 +2591,7 @@ df_insns_modify (df, bb, first_insn, last_insn)
/* Emit PATTERN before INSN within BB. */ /* Emit PATTERN before INSN within BB. */
rtx rtx
df_pattern_emit_before (df, pattern, bb, insn) df_pattern_emit_before (struct df *df, rtx pattern, basic_block bb, rtx insn)
struct df *df ATTRIBUTE_UNUSED;
rtx pattern;
basic_block bb;
rtx insn;
{ {
rtx ret_insn; rtx ret_insn;
rtx prev_insn = PREV_INSN (insn); rtx prev_insn = PREV_INSN (insn);
...@@ -2815,11 +2610,7 @@ df_pattern_emit_before (df, pattern, bb, insn) ...@@ -2815,11 +2610,7 @@ df_pattern_emit_before (df, pattern, bb, insn)
/* Emit PATTERN after INSN within BB. */ /* Emit PATTERN after INSN within BB. */
rtx rtx
df_pattern_emit_after (df, pattern, bb, insn) df_pattern_emit_after (struct df *df, rtx pattern, basic_block bb, rtx insn)
struct df *df;
rtx pattern;
basic_block bb;
rtx insn;
{ {
rtx ret_insn; rtx ret_insn;
...@@ -2834,11 +2625,7 @@ df_pattern_emit_after (df, pattern, bb, insn) ...@@ -2834,11 +2625,7 @@ df_pattern_emit_after (df, pattern, bb, insn)
/* Emit jump PATTERN after INSN within BB. */ /* Emit jump PATTERN after INSN within BB. */
rtx rtx
df_jump_pattern_emit_after (df, pattern, bb, insn) df_jump_pattern_emit_after (struct df *df, rtx pattern, basic_block bb, rtx insn)
struct df *df;
rtx pattern;
basic_block bb;
rtx insn;
{ {
rtx ret_insn; rtx ret_insn;
...@@ -2857,12 +2644,7 @@ df_jump_pattern_emit_after (df, pattern, bb, insn) ...@@ -2857,12 +2644,7 @@ df_jump_pattern_emit_after (df, pattern, bb, insn)
out of a loop where it has been proven that the def-use info out of a loop where it has been proven that the def-use info
will still be valid. */ will still be valid. */
rtx rtx
df_insn_move_before (df, bb, insn, before_bb, before_insn) df_insn_move_before (struct df *df, basic_block bb, rtx insn, basic_block before_bb, rtx before_insn)
struct df *df;
basic_block bb;
rtx insn;
basic_block before_bb;
rtx before_insn;
{ {
struct df_link *link; struct df_link *link;
unsigned int uid; unsigned int uid;
...@@ -2892,11 +2674,8 @@ df_insn_move_before (df, bb, insn, before_bb, before_insn) ...@@ -2892,11 +2674,8 @@ df_insn_move_before (df, bb, insn, before_bb, before_insn)
int int
df_insn_regno_def_p (df, bb, insn, regno) df_insn_regno_def_p (struct df *df, basic_block bb ATTRIBUTE_UNUSED,
struct df *df; rtx insn, unsigned int regno)
basic_block bb ATTRIBUTE_UNUSED;
rtx insn;
unsigned int regno;
{ {
unsigned int uid; unsigned int uid;
struct df_link *link; struct df_link *link;
...@@ -2916,9 +2695,7 @@ df_insn_regno_def_p (df, bb, insn, regno) ...@@ -2916,9 +2695,7 @@ df_insn_regno_def_p (df, bb, insn, regno)
static int static int
df_def_dominates_all_uses_p (df, def) df_def_dominates_all_uses_p (struct df *df ATTRIBUTE_UNUSED, struct ref *def)
struct df *df ATTRIBUTE_UNUSED;
struct ref *def;
{ {
struct df_link *du_link; struct df_link *du_link;
...@@ -2938,10 +2715,8 @@ df_def_dominates_all_uses_p (df, def) ...@@ -2938,10 +2715,8 @@ df_def_dominates_all_uses_p (df, def)
int int
df_insn_dominates_all_uses_p (df, bb, insn) df_insn_dominates_all_uses_p (struct df *df, basic_block bb ATTRIBUTE_UNUSED,
struct df *df; rtx insn)
basic_block bb ATTRIBUTE_UNUSED;
rtx insn;
{ {
unsigned int uid; unsigned int uid;
struct df_link *link; struct df_link *link;
...@@ -2963,10 +2738,8 @@ df_insn_dominates_all_uses_p (df, bb, insn) ...@@ -2963,10 +2738,8 @@ df_insn_dominates_all_uses_p (df, bb, insn)
/* Return nonzero if all DF dominates all the uses within the bitmap /* Return nonzero if all DF dominates all the uses within the bitmap
BLOCKS. */ BLOCKS. */
static int static int
df_def_dominates_uses_p (df, def, blocks) df_def_dominates_uses_p (struct df *df ATTRIBUTE_UNUSED, struct ref *def,
struct df *df ATTRIBUTE_UNUSED; bitmap blocks)
struct ref *def;
bitmap blocks;
{ {
struct df_link *du_link; struct df_link *du_link;
...@@ -2994,11 +2767,8 @@ df_def_dominates_uses_p (df, def, blocks) ...@@ -2994,11 +2767,8 @@ df_def_dominates_uses_p (df, def, blocks)
/* Return nonzero if all the defs of INSN within BB dominates /* Return nonzero if all the defs of INSN within BB dominates
all the corresponding uses. */ all the corresponding uses. */
int int
df_insn_dominates_uses_p (df, bb, insn, blocks) df_insn_dominates_uses_p (struct df *df, basic_block bb ATTRIBUTE_UNUSED,
struct df *df; rtx insn, bitmap blocks)
basic_block bb ATTRIBUTE_UNUSED;
rtx insn;
bitmap blocks;
{ {
unsigned int uid; unsigned int uid;
struct df_link *link; struct df_link *link;
...@@ -3021,9 +2791,7 @@ df_insn_dominates_uses_p (df, bb, insn, blocks) ...@@ -3021,9 +2791,7 @@ df_insn_dominates_uses_p (df, bb, insn, blocks)
/* Return the basic block that REG referenced in or NULL if referenced /* Return the basic block that REG referenced in or NULL if referenced
in multiple basic blocks. */ in multiple basic blocks. */
basic_block basic_block
df_regno_bb (df, regno) df_regno_bb (struct df *df, unsigned int regno)
struct df *df;
unsigned int regno;
{ {
struct df_link *defs = df->regs[regno].defs; struct df_link *defs = df->regs[regno].defs;
struct df_link *uses = df->regs[regno].uses; struct df_link *uses = df->regs[regno].uses;
...@@ -3040,9 +2808,7 @@ df_regno_bb (df, regno) ...@@ -3040,9 +2808,7 @@ df_regno_bb (df, regno)
/* Return nonzero if REG used in multiple basic blocks. */ /* Return nonzero if REG used in multiple basic blocks. */
int int
df_reg_global_p (df, reg) df_reg_global_p (struct df *df, rtx reg)
struct df *df;
rtx reg;
{ {
return df_regno_bb (df, REGNO (reg)) != 0; return df_regno_bb (df, REGNO (reg)) != 0;
} }
...@@ -3050,9 +2816,7 @@ df_reg_global_p (df, reg) ...@@ -3050,9 +2816,7 @@ df_reg_global_p (df, reg)
/* Return total lifetime (in insns) of REG. */ /* Return total lifetime (in insns) of REG. */
int int
df_reg_lifetime (df, reg) df_reg_lifetime (struct df *df, rtx reg)
struct df *df;
rtx reg;
{ {
return df->regs[REGNO (reg)].lifetime; return df->regs[REGNO (reg)].lifetime;
} }
...@@ -3060,10 +2824,7 @@ df_reg_lifetime (df, reg) ...@@ -3060,10 +2824,7 @@ df_reg_lifetime (df, reg)
/* Return nonzero if REG live at start of BB. */ /* Return nonzero if REG live at start of BB. */
int int
df_bb_reg_live_start_p (df, bb, reg) df_bb_reg_live_start_p (struct df *df, basic_block bb, rtx reg)
struct df *df ATTRIBUTE_UNUSED;
basic_block bb;
rtx reg;
{ {
struct bb_info *bb_info = DF_BB_INFO (df, bb); struct bb_info *bb_info = DF_BB_INFO (df, bb);
...@@ -3078,10 +2839,7 @@ df_bb_reg_live_start_p (df, bb, reg) ...@@ -3078,10 +2839,7 @@ df_bb_reg_live_start_p (df, bb, reg)
/* Return nonzero if REG live at end of BB. */ /* Return nonzero if REG live at end of BB. */
int int
df_bb_reg_live_end_p (df, bb, reg) df_bb_reg_live_end_p (struct df *df, basic_block bb, rtx reg)
struct df *df ATTRIBUTE_UNUSED;
basic_block bb;
rtx reg;
{ {
struct bb_info *bb_info = DF_BB_INFO (df, bb); struct bb_info *bb_info = DF_BB_INFO (df, bb);
...@@ -3097,11 +2855,7 @@ df_bb_reg_live_end_p (df, bb, reg) ...@@ -3097,11 +2855,7 @@ df_bb_reg_live_end_p (df, bb, reg)
/* Return -1 if life of REG1 before life of REG2, 1 if life of REG1 /* Return -1 if life of REG1 before life of REG2, 1 if life of REG1
after life of REG2, or 0, if the lives overlap. */ after life of REG2, or 0, if the lives overlap. */
int int
df_bb_regs_lives_compare (df, bb, reg1, reg2) df_bb_regs_lives_compare (struct df *df, basic_block bb, rtx reg1, rtx reg2)
struct df *df;
basic_block bb;
rtx reg1;
rtx reg2;
{ {
unsigned int regno1 = REGNO (reg1); unsigned int regno1 = REGNO (reg1);
unsigned int regno2 = REGNO (reg2); unsigned int regno2 = REGNO (reg2);
...@@ -3136,10 +2890,7 @@ df_bb_regs_lives_compare (df, bb, reg1, reg2) ...@@ -3136,10 +2890,7 @@ df_bb_regs_lives_compare (df, bb, reg1, reg2)
/* Return last use of REGNO within BB. */ /* Return last use of REGNO within BB. */
static struct ref * static struct ref *
df_bb_regno_last_use_find (df, bb, regno) df_bb_regno_last_use_find (struct df *df, basic_block bb, unsigned int regno)
struct df * df;
basic_block bb ATTRIBUTE_UNUSED;
unsigned int regno;
{ {
struct df_link *link; struct df_link *link;
...@@ -3160,10 +2911,7 @@ df_bb_regno_last_use_find (df, bb, regno) ...@@ -3160,10 +2911,7 @@ df_bb_regno_last_use_find (df, bb, regno)
/* Return first def of REGNO within BB. */ /* Return first def of REGNO within BB. */
static struct ref * static struct ref *
df_bb_regno_first_def_find (df, bb, regno) df_bb_regno_first_def_find (struct df *df, basic_block bb, unsigned int regno)
struct df * df;
basic_block bb ATTRIBUTE_UNUSED;
unsigned int regno;
{ {
struct df_link *link; struct df_link *link;
...@@ -3184,11 +2932,9 @@ df_bb_regno_first_def_find (df, bb, regno) ...@@ -3184,11 +2932,9 @@ df_bb_regno_first_def_find (df, bb, regno)
/* Return first use of REGNO inside INSN within BB. */ /* Return first use of REGNO inside INSN within BB. */
static struct ref * static struct ref *
df_bb_insn_regno_last_use_find (df, bb, insn, regno) df_bb_insn_regno_last_use_find (struct df *df,
struct df * df; basic_block bb ATTRIBUTE_UNUSED, rtx insn,
basic_block bb ATTRIBUTE_UNUSED; unsigned int regno)
rtx insn;
unsigned int regno;
{ {
unsigned int uid; unsigned int uid;
struct df_link *link; struct df_link *link;
...@@ -3209,11 +2955,9 @@ df_bb_insn_regno_last_use_find (df, bb, insn, regno) ...@@ -3209,11 +2955,9 @@ df_bb_insn_regno_last_use_find (df, bb, insn, regno)
/* Return first def of REGNO inside INSN within BB. */ /* Return first def of REGNO inside INSN within BB. */
static struct ref * static struct ref *
df_bb_insn_regno_first_def_find (df, bb, insn, regno) df_bb_insn_regno_first_def_find (struct df *df,
struct df * df; basic_block bb ATTRIBUTE_UNUSED, rtx insn,
basic_block bb ATTRIBUTE_UNUSED; unsigned int regno)
rtx insn;
unsigned int regno;
{ {
unsigned int uid; unsigned int uid;
struct df_link *link; struct df_link *link;
...@@ -3235,11 +2979,7 @@ df_bb_insn_regno_first_def_find (df, bb, insn, regno) ...@@ -3235,11 +2979,7 @@ df_bb_insn_regno_first_def_find (df, bb, insn, regno)
/* Return insn using REG if the BB contains only a single /* Return insn using REG if the BB contains only a single
use and def of REG. */ use and def of REG. */
rtx rtx
df_bb_single_def_use_insn_find (df, bb, insn, reg) df_bb_single_def_use_insn_find (struct df *df, basic_block bb, rtx insn, rtx reg)
struct df * df;
basic_block bb;
rtx insn;
rtx reg;
{ {
struct ref *def; struct ref *def;
struct ref *use; struct ref *use;
...@@ -3273,9 +3013,7 @@ df_bb_single_def_use_insn_find (df, bb, insn, reg) ...@@ -3273,9 +3013,7 @@ df_bb_single_def_use_insn_find (df, bb, insn, reg)
/* Dump a def-use or use-def chain for REF to FILE. */ /* Dump a def-use or use-def chain for REF to FILE. */
static void static void
df_chain_dump (link, file) df_chain_dump (struct df_link *link, FILE *file)
struct df_link *link;
FILE *file;
{ {
fprintf (file, "{ "); fprintf (file, "{ ");
for (; link; link = link->next) for (; link; link = link->next)
...@@ -3290,9 +3028,7 @@ df_chain_dump (link, file) ...@@ -3290,9 +3028,7 @@ df_chain_dump (link, file)
/* Dump a chain of refs with the associated regno. */ /* Dump a chain of refs with the associated regno. */
static void static void
df_chain_dump_regno (link, file) df_chain_dump_regno (struct df_link *link, FILE *file)
struct df_link *link;
FILE *file;
{ {
fprintf (file, "{ "); fprintf (file, "{ ");
for (; link; link = link->next) for (; link; link = link->next)
...@@ -3308,10 +3044,7 @@ df_chain_dump_regno (link, file) ...@@ -3308,10 +3044,7 @@ df_chain_dump_regno (link, file)
/* Dump dataflow info. */ /* Dump dataflow info. */
void void
df_dump (df, flags, file) df_dump (struct df *df, int flags, FILE *file)
struct df *df;
int flags;
FILE *file;
{ {
unsigned int j; unsigned int j;
basic_block bb; basic_block bb;
...@@ -3482,10 +3215,7 @@ df_dump (df, flags, file) ...@@ -3482,10 +3215,7 @@ df_dump (df, flags, file)
void void
df_insn_debug (df, insn, file) df_insn_debug (struct df *df, rtx insn, FILE *file)
struct df *df;
rtx insn;
FILE *file;
{ {
unsigned int uid; unsigned int uid;
int bbi; int bbi;
...@@ -3511,10 +3241,7 @@ df_insn_debug (df, insn, file) ...@@ -3511,10 +3241,7 @@ df_insn_debug (df, insn, file)
void void
df_insn_debug_regno (df, insn, file) df_insn_debug_regno (struct df *df, rtx insn, FILE *file)
struct df *df;
rtx insn;
FILE *file;
{ {
unsigned int uid; unsigned int uid;
int bbi; int bbi;
...@@ -3540,10 +3267,7 @@ df_insn_debug_regno (df, insn, file) ...@@ -3540,10 +3267,7 @@ df_insn_debug_regno (df, insn, file)
static void static void
df_regno_debug (df, regno, file) df_regno_debug (struct df *df, unsigned int regno, FILE *file)
struct df *df;
unsigned int regno;
FILE *file;
{ {
if (regno >= df->reg_size) if (regno >= df->reg_size)
return; return;
...@@ -3558,10 +3282,7 @@ df_regno_debug (df, regno, file) ...@@ -3558,10 +3282,7 @@ df_regno_debug (df, regno, file)
static void static void
df_ref_debug (df, ref, file) df_ref_debug (struct df *df, struct ref *ref, FILE *file)
struct df *df;
struct ref *ref;
FILE *file;
{ {
fprintf (file, "%c%d ", fprintf (file, "%c%d ",
DF_REF_REG_DEF_P (ref) ? 'd' : 'u', DF_REF_REG_DEF_P (ref) ? 'd' : 'u',
...@@ -3578,8 +3299,7 @@ df_ref_debug (df, ref, file) ...@@ -3578,8 +3299,7 @@ df_ref_debug (df, ref, file)
/* Functions for debugging from GDB. */ /* Functions for debugging from GDB. */
void void
debug_df_insn (insn) debug_df_insn (rtx insn)
rtx insn;
{ {
df_insn_debug (ddf, insn, stderr); df_insn_debug (ddf, insn, stderr);
debug_rtx (insn); debug_rtx (insn);
...@@ -3587,48 +3307,42 @@ debug_df_insn (insn) ...@@ -3587,48 +3307,42 @@ debug_df_insn (insn)
void void
debug_df_reg (reg) debug_df_reg (rtx reg)
rtx reg;
{ {
df_regno_debug (ddf, REGNO (reg), stderr); df_regno_debug (ddf, REGNO (reg), stderr);
} }
void void
debug_df_regno (regno) debug_df_regno (unsigned int regno)
unsigned int regno;
{ {
df_regno_debug (ddf, regno, stderr); df_regno_debug (ddf, regno, stderr);
} }
void void
debug_df_ref (ref) debug_df_ref (struct ref *ref)
struct ref *ref;
{ {
df_ref_debug (ddf, ref, stderr); df_ref_debug (ddf, ref, stderr);
} }
void void
debug_df_defno (defno) debug_df_defno (unsigned int defno)
unsigned int defno;
{ {
df_ref_debug (ddf, ddf->defs[defno], stderr); df_ref_debug (ddf, ddf->defs[defno], stderr);
} }
void void
debug_df_useno (defno) debug_df_useno (unsigned int defno)
unsigned int defno;
{ {
df_ref_debug (ddf, ddf->uses[defno], stderr); df_ref_debug (ddf, ddf->uses[defno], stderr);
} }
void void
debug_df_chain (link) debug_df_chain (struct df_link *link)
struct df_link *link;
{ {
df_chain_dump (link, stderr); df_chain_dump (link, stderr);
fputc ('\n', stderr); fputc ('\n', stderr);
...@@ -3638,17 +3352,11 @@ debug_df_chain (link) ...@@ -3638,17 +3352,11 @@ debug_df_chain (link)
/* Hybrid search algorithm from "Implementation Techniques for /* Hybrid search algorithm from "Implementation Techniques for
Efficient Data-Flow Analysis of Large Programs". */ Efficient Data-Flow Analysis of Large Programs". */
static void static void
hybrid_search_bitmap (block, in, out, gen, kill, dir, hybrid_search_bitmap (basic_block block, bitmap *in, bitmap *out, bitmap *gen,
conf_op, transfun, visited, pending, bitmap *kill, enum df_flow_dir dir,
data) enum df_confluence_op conf_op,
basic_block block; transfer_function_bitmap transfun, sbitmap visited,
bitmap *in, *out, *gen, *kill; sbitmap pending, void *data)
enum df_flow_dir dir;
enum df_confluence_op conf_op;
transfer_function_bitmap transfun;
sbitmap visited;
sbitmap pending;
void *data;
{ {
int changed; int changed;
int i = block->index; int i = block->index;
...@@ -3750,17 +3458,11 @@ hybrid_search_bitmap (block, in, out, gen, kill, dir, ...@@ -3750,17 +3458,11 @@ hybrid_search_bitmap (block, in, out, gen, kill, dir,
/* Hybrid search for sbitmaps, rather than bitmaps. */ /* Hybrid search for sbitmaps, rather than bitmaps. */
static void static void
hybrid_search_sbitmap (block, in, out, gen, kill, dir, hybrid_search_sbitmap (basic_block block, sbitmap *in, sbitmap *out,
conf_op, transfun, visited, pending, sbitmap *gen, sbitmap *kill, enum df_flow_dir dir,
data) enum df_confluence_op conf_op,
basic_block block; transfer_function_sbitmap transfun, sbitmap visited,
sbitmap *in, *out, *gen, *kill; sbitmap pending, void *data)
enum df_flow_dir dir;
enum df_confluence_op conf_op;
transfer_function_sbitmap transfun;
sbitmap visited;
sbitmap pending;
void *data;
{ {
int changed; int changed;
int i = block->index; int i = block->index;
...@@ -3881,15 +3583,12 @@ hybrid_search_sbitmap (block, in, out, gen, kill, dir, ...@@ -3881,15 +3583,12 @@ hybrid_search_sbitmap (block, in, out, gen, kill, dir,
block number to rc_order (like df->inverse_rc_map). block number to rc_order (like df->inverse_rc_map).
*/ */
void void
iterative_dataflow_sbitmap (in, out, gen, kill, blocks, iterative_dataflow_sbitmap (sbitmap *in, sbitmap *out, sbitmap *gen,
dir, conf_op, transfun, order, data) sbitmap *kill, bitmap blocks,
sbitmap *in, *out, *gen, *kill; enum df_flow_dir dir,
bitmap blocks; enum df_confluence_op conf_op,
enum df_flow_dir dir; transfer_function_sbitmap transfun, int *order,
enum df_confluence_op conf_op; void *data)
transfer_function_sbitmap transfun;
int *order;
void *data;
{ {
int i; int i;
fibheap_t worklist; fibheap_t worklist;
...@@ -3946,15 +3645,11 @@ iterative_dataflow_sbitmap (in, out, gen, kill, blocks, ...@@ -3946,15 +3645,11 @@ iterative_dataflow_sbitmap (in, out, gen, kill, blocks,
/* Exactly the same as iterative_dataflow_sbitmap, except it works on /* Exactly the same as iterative_dataflow_sbitmap, except it works on
bitmaps instead. */ bitmaps instead. */
void void
iterative_dataflow_bitmap (in, out, gen, kill, blocks, iterative_dataflow_bitmap (bitmap *in, bitmap *out, bitmap *gen, bitmap *kill,
dir, conf_op, transfun, order, data) bitmap blocks, enum df_flow_dir dir,
bitmap *in, *out, *gen, *kill; enum df_confluence_op conf_op,
bitmap blocks; transfer_function_bitmap transfun, int *order,
enum df_flow_dir dir; void *data)
enum df_confluence_op conf_op;
transfer_function_bitmap transfun;
int *order;
void *data;
{ {
int i; int i;
fibheap_t worklist; fibheap_t worklist;
......
...@@ -231,96 +231,87 @@ struct df_map ...@@ -231,96 +231,87 @@ struct df_map
/* Functions to build and analyse dataflow information. */ /* Functions to build and analyse dataflow information. */
extern struct df *df_init PARAMS ((void)); extern struct df *df_init (void);
extern int df_analyse PARAMS ((struct df *, bitmap, int)); extern int df_analyse (struct df *, bitmap, int);
extern void df_finish PARAMS ((struct df *)); extern void df_finish (struct df *);
extern void df_dump PARAMS ((struct df *, int, FILE *)); extern void df_dump (struct df *, int, FILE *);
/* Functions to modify insns. */ /* Functions to modify insns. */
extern void df_insn_modify PARAMS ((struct df *, basic_block, rtx)); extern void df_insn_modify (struct df *, basic_block, rtx);
extern rtx df_insn_delete PARAMS ((struct df *, basic_block, rtx)); extern rtx df_insn_delete (struct df *, basic_block, rtx);
extern rtx df_pattern_emit_before PARAMS ((struct df *, rtx, extern rtx df_pattern_emit_before (struct df *, rtx, basic_block, rtx);
basic_block, rtx));
extern rtx df_jump_pattern_emit_after PARAMS ((struct df *, rtx, extern rtx df_jump_pattern_emit_after (struct df *, rtx, basic_block, rtx);
basic_block, rtx));
extern rtx df_pattern_emit_after PARAMS ((struct df *, rtx, extern rtx df_pattern_emit_after (struct df *, rtx, basic_block, rtx);
basic_block, rtx));
extern rtx df_insn_move_before PARAMS ((struct df *, basic_block, rtx, extern rtx df_insn_move_before (struct df *, basic_block, rtx, basic_block,
basic_block, rtx)); rtx);
extern int df_reg_replace PARAMS ((struct df *, bitmap, rtx, rtx)); extern int df_reg_replace (struct df *, bitmap, rtx, rtx);
extern int df_ref_reg_replace PARAMS ((struct df *, struct ref *, rtx, rtx)); extern int df_ref_reg_replace (struct df *, struct ref *, rtx, rtx);
extern int df_ref_remove PARAMS ((struct df *, struct ref *)); extern int df_ref_remove (struct df *, struct ref *);
extern int df_insn_reg_replace PARAMS ((struct df *, basic_block, extern int df_insn_reg_replace (struct df *, basic_block, rtx, rtx, rtx);
rtx, rtx, rtx));
extern int df_insn_mem_replace PARAMS ((struct df *, basic_block, extern int df_insn_mem_replace (struct df *, basic_block, rtx, rtx, rtx);
rtx, rtx, rtx));
extern struct ref *df_bb_def_use_swap PARAMS ((struct df *, basic_block, extern struct ref *df_bb_def_use_swap (struct df *, basic_block, rtx, rtx,
rtx, rtx, unsigned int)); unsigned int);
/* Functions to query dataflow information. */ /* Functions to query dataflow information. */
extern basic_block df_regno_bb PARAMS((struct df *, unsigned int)); extern basic_block df_regno_bb (struct df *, unsigned int);
extern int df_reg_lifetime PARAMS ((struct df *, rtx)); extern int df_reg_lifetime (struct df *, rtx);
extern int df_reg_global_p PARAMS ((struct df *, rtx)); extern int df_reg_global_p (struct df *, rtx);
extern int df_insn_regno_def_p PARAMS ((struct df *, extern int df_insn_regno_def_p (struct df *, basic_block, rtx, unsigned int);
basic_block, rtx, unsigned int));
extern int df_insn_dominates_all_uses_p PARAMS ((struct df *, extern int df_insn_dominates_all_uses_p (struct df *, basic_block, rtx);
basic_block, rtx));
extern int df_insn_dominates_uses_p PARAMS ((struct df *, basic_block, extern int df_insn_dominates_uses_p (struct df *, basic_block, rtx, bitmap);
rtx, bitmap));
extern int df_bb_reg_live_start_p PARAMS ((struct df *, basic_block, rtx)); extern int df_bb_reg_live_start_p (struct df *, basic_block, rtx);
extern int df_bb_reg_live_end_p PARAMS ((struct df *, basic_block, rtx)); extern int df_bb_reg_live_end_p (struct df *, basic_block, rtx);
extern int df_bb_regs_lives_compare PARAMS ((struct df *, basic_block, extern int df_bb_regs_lives_compare (struct df *, basic_block, rtx, rtx);
rtx, rtx));
extern rtx df_bb_single_def_use_insn_find PARAMS((struct df *, basic_block, extern rtx df_bb_single_def_use_insn_find (struct df *, basic_block, rtx,
rtx, rtx)); rtx);
/* Functions for debugging from GDB. */ /* Functions for debugging from GDB. */
extern void debug_df_insn PARAMS ((rtx)); extern void debug_df_insn (rtx);
extern void debug_df_regno PARAMS ((unsigned int)); extern void debug_df_regno (unsigned int);
extern void debug_df_reg PARAMS ((rtx)); extern void debug_df_reg (rtx);
extern void debug_df_defno PARAMS ((unsigned int)); extern void debug_df_defno (unsigned int);
extern void debug_df_useno PARAMS ((unsigned int)); extern void debug_df_useno (unsigned int);
extern void debug_df_ref PARAMS ((struct ref *)); extern void debug_df_ref (struct ref *);
extern void debug_df_chain PARAMS ((struct df_link *)); extern void debug_df_chain (struct df_link *);
extern void df_insn_debug PARAMS ((struct df *, rtx, FILE *)); extern void df_insn_debug (struct df *, rtx, FILE *);
extern void df_insn_debug_regno PARAMS ((struct df *, rtx, FILE *)); extern void df_insn_debug_regno (struct df *, rtx, FILE *);
/* Meet over any path (UNION) or meet over all paths (INTERSECTION). */ /* Meet over any path (UNION) or meet over all paths (INTERSECTION). */
...@@ -339,23 +330,22 @@ enum df_flow_dir ...@@ -339,23 +330,22 @@ enum df_flow_dir
}; };
typedef void (*transfer_function_sbitmap) PARAMS ((int, int *, sbitmap, sbitmap, typedef void (*transfer_function_sbitmap) (int, int *, sbitmap, sbitmap,
sbitmap, sbitmap, void *)); sbitmap, sbitmap, void *);
typedef void (*transfer_function_bitmap) PARAMS ((int, int *, bitmap, bitmap, typedef void (*transfer_function_bitmap) (int, int *, bitmap, bitmap,
bitmap, bitmap, void *)); bitmap, bitmap, void *);
extern void iterative_dataflow_sbitmap PARAMS ((sbitmap *, sbitmap *, extern void iterative_dataflow_sbitmap (sbitmap *, sbitmap *, sbitmap *,
sbitmap *, sbitmap *, sbitmap *, bitmap, enum df_flow_dir,
bitmap, enum df_flow_dir,
enum df_confluence_op, enum df_confluence_op,
transfer_function_sbitmap, transfer_function_sbitmap,
int *, void *)); int *, void *);
extern void iterative_dataflow_bitmap PARAMS ((bitmap *, bitmap *, bitmap *, extern void iterative_dataflow_bitmap (bitmap *, bitmap *, bitmap *,
bitmap *, bitmap, bitmap *, bitmap,
enum df_flow_dir, enum df_flow_dir,
enum df_confluence_op, enum df_confluence_op,
transfer_function_bitmap, transfer_function_bitmap,
int *, void *)); int *, void *);
extern bool read_modify_subreg_p PARAMS ((rtx)); extern bool read_modify_subreg_p (rtx);
...@@ -34,16 +34,16 @@ Software Foundation, 59 Temple Place - Suite 330, Boston, MA ...@@ -34,16 +34,16 @@ Software Foundation, 59 Temple Place - Suite 330, Boston, MA
#include "optabs.h" #include "optabs.h"
#include "langhooks.h" #include "langhooks.h"
static void do_jump_by_parts_greater PARAMS ((tree, int, rtx, rtx)); static void do_jump_by_parts_greater (tree, int, rtx, rtx);
static void do_jump_by_parts_equality PARAMS ((tree, rtx, rtx)); static void do_jump_by_parts_equality (tree, rtx, rtx);
static void do_compare_and_jump PARAMS ((tree, enum rtx_code, enum rtx_code, static void do_compare_and_jump (tree, enum rtx_code, enum rtx_code, rtx,
rtx, rtx)); rtx);
/* At the start of a function, record that we have no previously-pushed /* At the start of a function, record that we have no previously-pushed
arguments waiting to be popped. */ arguments waiting to be popped. */
void void
init_pending_stack_adjust () init_pending_stack_adjust (void)
{ {
pending_stack_adjust = 0; pending_stack_adjust = 0;
} }
...@@ -55,7 +55,7 @@ init_pending_stack_adjust () ...@@ -55,7 +55,7 @@ init_pending_stack_adjust ()
frame pointer regardless of the value of flag_omit_frame_pointer. */ frame pointer regardless of the value of flag_omit_frame_pointer. */
void void
clear_pending_stack_adjust () clear_pending_stack_adjust (void)
{ {
#ifdef EXIT_IGNORE_STACK #ifdef EXIT_IGNORE_STACK
if (optimize > 0 if (optimize > 0
...@@ -73,7 +73,7 @@ clear_pending_stack_adjust () ...@@ -73,7 +73,7 @@ clear_pending_stack_adjust ()
/* Pop any previously-pushed arguments that have not been popped yet. */ /* Pop any previously-pushed arguments that have not been popped yet. */
void void
do_pending_stack_adjust () do_pending_stack_adjust (void)
{ {
if (inhibit_defer_pop == 0) if (inhibit_defer_pop == 0)
{ {
...@@ -90,9 +90,7 @@ do_pending_stack_adjust () ...@@ -90,9 +90,7 @@ do_pending_stack_adjust ()
functions here. */ functions here. */
void void
jumpifnot (exp, label) jumpifnot (tree exp, rtx label)
tree exp;
rtx label;
{ {
do_jump (exp, label, NULL_RTX); do_jump (exp, label, NULL_RTX);
} }
...@@ -100,9 +98,7 @@ jumpifnot (exp, label) ...@@ -100,9 +98,7 @@ jumpifnot (exp, label)
/* Generate code to evaluate EXP and jump to LABEL if the value is nonzero. */ /* Generate code to evaluate EXP and jump to LABEL if the value is nonzero. */
void void
jumpif (exp, label) jumpif (tree exp, rtx label)
tree exp;
rtx label;
{ {
do_jump (exp, NULL_RTX, label); do_jump (exp, NULL_RTX, label);
} }
...@@ -120,9 +116,7 @@ jumpif (exp, label) ...@@ -120,9 +116,7 @@ jumpif (exp, label)
&&, || and comparison operators in EXP. */ &&, || and comparison operators in EXP. */
void void
do_jump (exp, if_false_label, if_true_label) do_jump (tree exp, rtx if_false_label, rtx if_true_label)
tree exp;
rtx if_false_label, if_true_label;
{ {
enum tree_code code = TREE_CODE (exp); enum tree_code code = TREE_CODE (exp);
/* Some cases need to create a label to jump to /* Some cases need to create a label to jump to
...@@ -617,10 +611,8 @@ do_jump (exp, if_false_label, if_true_label) ...@@ -617,10 +611,8 @@ do_jump (exp, if_false_label, if_true_label)
and LT if SWAP is 1. */ and LT if SWAP is 1. */
static void static void
do_jump_by_parts_greater (exp, swap, if_false_label, if_true_label) do_jump_by_parts_greater (tree exp, int swap, rtx if_false_label,
tree exp; rtx if_true_label)
int swap;
rtx if_false_label, if_true_label;
{ {
rtx op0 = expand_expr (TREE_OPERAND (exp, swap), NULL_RTX, VOIDmode, 0); rtx op0 = expand_expr (TREE_OPERAND (exp, swap), NULL_RTX, VOIDmode, 0);
rtx op1 = expand_expr (TREE_OPERAND (exp, !swap), NULL_RTX, VOIDmode, 0); rtx op1 = expand_expr (TREE_OPERAND (exp, !swap), NULL_RTX, VOIDmode, 0);
...@@ -635,11 +627,8 @@ do_jump_by_parts_greater (exp, swap, if_false_label, if_true_label) ...@@ -635,11 +627,8 @@ do_jump_by_parts_greater (exp, swap, if_false_label, if_true_label)
Jump to IF_TRUE_LABEL if OP0 is greater, IF_FALSE_LABEL otherwise. */ Jump to IF_TRUE_LABEL if OP0 is greater, IF_FALSE_LABEL otherwise. */
void void
do_jump_by_parts_greater_rtx (mode, unsignedp, op0, op1, if_false_label, if_true_label) do_jump_by_parts_greater_rtx (enum machine_mode mode, int unsignedp, rtx op0,
enum machine_mode mode; rtx op1, rtx if_false_label, rtx if_true_label)
int unsignedp;
rtx op0, op1;
rtx if_false_label, if_true_label;
{ {
int nwords = (GET_MODE_SIZE (mode) / UNITS_PER_WORD); int nwords = (GET_MODE_SIZE (mode) / UNITS_PER_WORD);
rtx drop_through_label = 0; rtx drop_through_label = 0;
...@@ -688,9 +677,7 @@ do_jump_by_parts_greater_rtx (mode, unsignedp, op0, op1, if_false_label, if_true ...@@ -688,9 +677,7 @@ do_jump_by_parts_greater_rtx (mode, unsignedp, op0, op1, if_false_label, if_true
with one insn, test the comparison and jump to the appropriate label. */ with one insn, test the comparison and jump to the appropriate label. */
static void static void
do_jump_by_parts_equality (exp, if_false_label, if_true_label) do_jump_by_parts_equality (tree exp, rtx if_false_label, rtx if_true_label)
tree exp;
rtx if_false_label, if_true_label;
{ {
rtx op0 = expand_expr (TREE_OPERAND (exp, 0), NULL_RTX, VOIDmode, 0); rtx op0 = expand_expr (TREE_OPERAND (exp, 0), NULL_RTX, VOIDmode, 0);
rtx op1 = expand_expr (TREE_OPERAND (exp, 1), NULL_RTX, VOIDmode, 0); rtx op1 = expand_expr (TREE_OPERAND (exp, 1), NULL_RTX, VOIDmode, 0);
...@@ -719,9 +706,7 @@ do_jump_by_parts_equality (exp, if_false_label, if_true_label) ...@@ -719,9 +706,7 @@ do_jump_by_parts_equality (exp, if_false_label, if_true_label)
for the available compare insns. */ for the available compare insns. */
void void
do_jump_by_parts_equality_rtx (op0, if_false_label, if_true_label) do_jump_by_parts_equality_rtx (rtx op0, rtx if_false_label, rtx if_true_label)
rtx op0;
rtx if_false_label, if_true_label;
{ {
int nwords = GET_MODE_SIZE (GET_MODE (op0)) / UNITS_PER_WORD; int nwords = GET_MODE_SIZE (GET_MODE (op0)) / UNITS_PER_WORD;
rtx part; rtx part;
...@@ -776,12 +761,8 @@ do_jump_by_parts_equality_rtx (op0, if_false_label, if_true_label) ...@@ -776,12 +761,8 @@ do_jump_by_parts_equality_rtx (op0, if_false_label, if_true_label)
compared. */ compared. */
rtx rtx
compare_from_rtx (op0, op1, code, unsignedp, mode, size) compare_from_rtx (rtx op0, rtx op1, enum rtx_code code, int unsignedp,
rtx op0, op1; enum machine_mode mode, rtx size)
enum rtx_code code;
int unsignedp;
enum machine_mode mode;
rtx size;
{ {
enum rtx_code ucode; enum rtx_code ucode;
rtx tem; rtx tem;
...@@ -847,14 +828,9 @@ compare_from_rtx (op0, op1, code, unsignedp, mode, size) ...@@ -847,14 +828,9 @@ compare_from_rtx (op0, op1, code, unsignedp, mode, size)
compared. */ compared. */
void void
do_compare_rtx_and_jump (op0, op1, code, unsignedp, mode, size, do_compare_rtx_and_jump (rtx op0, rtx op1, enum rtx_code code, int unsignedp,
if_false_label, if_true_label) enum machine_mode mode, rtx size, rtx if_false_label,
rtx op0, op1; rtx if_true_label)
enum rtx_code code;
int unsignedp;
enum machine_mode mode;
rtx size;
rtx if_false_label, if_true_label;
{ {
enum rtx_code ucode; enum rtx_code ucode;
rtx tem; rtx tem;
...@@ -952,11 +928,9 @@ do_compare_rtx_and_jump (op0, op1, code, unsignedp, mode, size, ...@@ -952,11 +928,9 @@ do_compare_rtx_and_jump (op0, op1, code, unsignedp, mode, size,
things pushed on the stack that aren't yet used. */ things pushed on the stack that aren't yet used. */
static void static void
do_compare_and_jump (exp, signed_code, unsigned_code, if_false_label, do_compare_and_jump (tree exp, enum rtx_code signed_code,
if_true_label) enum rtx_code unsigned_code, rtx if_false_label,
tree exp; rtx if_true_label)
enum rtx_code signed_code, unsigned_code;
rtx if_false_label, if_true_label;
{ {
rtx op0, op1; rtx op0, op1;
tree type; tree type;
......
/* Perform doloop optimizations /* Perform doloop optimizations
Copyright (C) 1999, 2000, 2001, 2002 Free Software Foundation, Inc. Copyright (C) 1999, 2000, 2001, 2002, 2003
Free Software Foundation, Inc.
Contributed by Michael P. Hayes (m.hayes@elec.canterbury.ac.nz) Contributed by Michael P. Hayes (m.hayes@elec.canterbury.ac.nz)
This file is part of GCC. This file is part of GCC.
...@@ -59,23 +60,19 @@ Software Foundation, 59 Temple Place - Suite 330, Boston, MA ...@@ -59,23 +60,19 @@ Software Foundation, 59 Temple Place - Suite 330, Boston, MA
#ifdef HAVE_doloop_end #ifdef HAVE_doloop_end
static rtx doloop_condition_get static rtx doloop_condition_get (rtx);
PARAMS ((rtx)); static unsigned HOST_WIDE_INT doloop_iterations_max (const struct loop_info *,
static unsigned HOST_WIDE_INT doloop_iterations_max enum machine_mode, int);
PARAMS ((const struct loop_info *, enum machine_mode, int)); static int doloop_valid_p (const struct loop *, rtx);
static int doloop_valid_p static int doloop_modify (const struct loop *, rtx, rtx, rtx, rtx, rtx);
PARAMS ((const struct loop *, rtx)); static int doloop_modify_runtime (const struct loop *, rtx, rtx, rtx,
static int doloop_modify enum machine_mode, rtx);
PARAMS ((const struct loop *, rtx, rtx, rtx, rtx, rtx));
static int doloop_modify_runtime
PARAMS ((const struct loop *, rtx, rtx, rtx, enum machine_mode, rtx));
/* Return the loop termination condition for PATTERN or zero /* Return the loop termination condition for PATTERN or zero
if it is not a decrement and branch jump insn. */ if it is not a decrement and branch jump insn. */
static rtx static rtx
doloop_condition_get (pattern) doloop_condition_get (rtx pattern)
rtx pattern;
{ {
rtx cmp; rtx cmp;
rtx inc; rtx inc;
...@@ -146,10 +143,8 @@ doloop_condition_get (pattern) ...@@ -146,10 +143,8 @@ doloop_condition_get (pattern)
MODE is the mode of the iteration count and NONNEG is nonzero if MODE is the mode of the iteration count and NONNEG is nonzero if
the iteration count has been proved to be non-negative. */ the iteration count has been proved to be non-negative. */
static unsigned HOST_WIDE_INT static unsigned HOST_WIDE_INT
doloop_iterations_max (loop_info, mode, nonneg) doloop_iterations_max (const struct loop_info *loop_info,
const struct loop_info *loop_info; enum machine_mode mode, int nonneg)
enum machine_mode mode;
int nonneg;
{ {
unsigned HOST_WIDE_INT n_iterations_max; unsigned HOST_WIDE_INT n_iterations_max;
enum rtx_code code; enum rtx_code code;
...@@ -255,9 +250,7 @@ doloop_iterations_max (loop_info, mode, nonneg) ...@@ -255,9 +250,7 @@ doloop_iterations_max (loop_info, mode, nonneg)
/* Return nonzero if the loop specified by LOOP is suitable for /* Return nonzero if the loop specified by LOOP is suitable for
the use of special low-overhead looping instructions. */ the use of special low-overhead looping instructions. */
static int static int
doloop_valid_p (loop, jump_insn) doloop_valid_p (const struct loop *loop, rtx jump_insn)
const struct loop *loop;
rtx jump_insn;
{ {
const struct loop_info *loop_info = LOOP_INFO (loop); const struct loop_info *loop_info = LOOP_INFO (loop);
...@@ -405,14 +398,8 @@ doloop_valid_p (loop, jump_insn) ...@@ -405,14 +398,8 @@ doloop_valid_p (loop, jump_insn)
low-overhead looping insn to emit at the end of the loop. This low-overhead looping insn to emit at the end of the loop. This
returns nonzero if it was successful. */ returns nonzero if it was successful. */
static int static int
doloop_modify (loop, iterations, iterations_max, doloop_modify (const struct loop *loop, rtx iterations, rtx iterations_max,
doloop_seq, start_label, condition) rtx doloop_seq, rtx start_label, rtx condition)
const struct loop *loop;
rtx iterations;
rtx iterations_max;
rtx doloop_seq;
rtx start_label;
rtx condition;
{ {
rtx counter_reg; rtx counter_reg;
rtx count; rtx count;
...@@ -545,14 +532,9 @@ doloop_modify (loop, iterations, iterations_max, ...@@ -545,14 +532,9 @@ doloop_modify (loop, iterations, iterations_max,
number of loop iterations. DOLOOP_INSN is the low-overhead looping number of loop iterations. DOLOOP_INSN is the low-overhead looping
insn to insert. Returns nonzero if loop successfully modified. */ insn to insert. Returns nonzero if loop successfully modified. */
static int static int
doloop_modify_runtime (loop, iterations_max, doloop_modify_runtime (const struct loop *loop, rtx iterations_max,
doloop_seq, start_label, mode, condition) rtx doloop_seq, rtx start_label,
const struct loop *loop; enum machine_mode mode, rtx condition)
rtx iterations_max;
rtx doloop_seq;
rtx start_label;
enum machine_mode mode;
rtx condition;
{ {
const struct loop_info *loop_info = LOOP_INFO (loop); const struct loop_info *loop_info = LOOP_INFO (loop);
HOST_WIDE_INT abs_inc; HOST_WIDE_INT abs_inc;
...@@ -759,8 +741,7 @@ doloop_modify_runtime (loop, iterations_max, ...@@ -759,8 +741,7 @@ doloop_modify_runtime (loop, iterations_max,
is a candidate for this optimization. Returns nonzero if loop is a candidate for this optimization. Returns nonzero if loop
successfully modified. */ successfully modified. */
int int
doloop_optimize (loop) doloop_optimize (const struct loop *loop)
const struct loop *loop;
{ {
struct loop_info *loop_info = LOOP_INFO (loop); struct loop_info *loop_info = LOOP_INFO (loop);
rtx initial_value; rtx initial_value;
......
/* Calculate (post)dominators in slightly super-linear time. /* Calculate (post)dominators in slightly super-linear time.
Copyright (C) 2000 Free Software Foundation, Inc. Copyright (C) 2000, 2003 Free Software Foundation, Inc.
Contributed by Michael Matz (matz@ifh.de). Contributed by Michael Matz (matz@ifh.de).
This file is part of GCC. This file is part of GCC.
...@@ -115,19 +115,16 @@ struct dom_info ...@@ -115,19 +115,16 @@ struct dom_info
unsigned int nodes; unsigned int nodes;
}; };
static void init_dom_info PARAMS ((struct dom_info *)); static void init_dom_info (struct dom_info *);
static void free_dom_info PARAMS ((struct dom_info *)); static void free_dom_info (struct dom_info *);
static void calc_dfs_tree_nonrec PARAMS ((struct dom_info *, static void calc_dfs_tree_nonrec (struct dom_info *, basic_block,
basic_block, enum cdi_direction);
enum cdi_direction)); static void calc_dfs_tree (struct dom_info *, enum cdi_direction);
static void calc_dfs_tree PARAMS ((struct dom_info *, static void compress (struct dom_info *, TBB);
enum cdi_direction)); static TBB eval (struct dom_info *, TBB);
static void compress PARAMS ((struct dom_info *, TBB)); static void link_roots (struct dom_info *, TBB, TBB);
static TBB eval PARAMS ((struct dom_info *, TBB)); static void calc_idoms (struct dom_info *, enum cdi_direction);
static void link_roots PARAMS ((struct dom_info *, TBB, TBB)); void debug_dominance_info (dominance_info);
static void calc_idoms PARAMS ((struct dom_info *,
enum cdi_direction));
void debug_dominance_info PARAMS ((dominance_info));
/* Helper macro for allocating and initializing an array, /* Helper macro for allocating and initializing an array,
for aesthetic reasons. */ for aesthetic reasons. */
...@@ -150,8 +147,7 @@ void debug_dominance_info PARAMS ((dominance_info)); ...@@ -150,8 +147,7 @@ void debug_dominance_info PARAMS ((dominance_info));
This initializes the contents of DI, which already must be allocated. */ This initializes the contents of DI, which already must be allocated. */
static void static void
init_dom_info (di) init_dom_info (struct dom_info *di)
struct dom_info *di;
{ {
/* We need memory for n_basic_blocks nodes and the ENTRY_BLOCK or /* We need memory for n_basic_blocks nodes and the ENTRY_BLOCK or
EXIT_BLOCK. */ EXIT_BLOCK. */
...@@ -180,8 +176,7 @@ init_dom_info (di) ...@@ -180,8 +176,7 @@ init_dom_info (di)
/* Free all allocated memory in DI, but not DI itself. */ /* Free all allocated memory in DI, but not DI itself. */
static void static void
free_dom_info (di) free_dom_info (struct dom_info *di)
struct dom_info *di;
{ {
free (di->dfs_parent); free (di->dfs_parent);
free (di->path_min); free (di->path_min);
...@@ -203,10 +198,7 @@ free_dom_info (di) ...@@ -203,10 +198,7 @@ free_dom_info (di)
assigned their dfs number and are linked together to form a tree. */ assigned their dfs number and are linked together to form a tree. */
static void static void
calc_dfs_tree_nonrec (di, bb, reverse) calc_dfs_tree_nonrec (struct dom_info *di, basic_block bb, enum cdi_direction reverse)
struct dom_info *di;
basic_block bb;
enum cdi_direction reverse;
{ {
/* We never call this with bb==EXIT_BLOCK_PTR (ENTRY_BLOCK_PTR if REVERSE). */ /* We never call this with bb==EXIT_BLOCK_PTR (ENTRY_BLOCK_PTR if REVERSE). */
/* We call this _only_ if bb is not already visited. */ /* We call this _only_ if bb is not already visited. */
...@@ -321,9 +313,7 @@ calc_dfs_tree_nonrec (di, bb, reverse) ...@@ -321,9 +313,7 @@ calc_dfs_tree_nonrec (di, bb, reverse)
because there may be nodes from which the EXIT_BLOCK is unreachable. */ because there may be nodes from which the EXIT_BLOCK is unreachable. */
static void static void
calc_dfs_tree (di, reverse) calc_dfs_tree (struct dom_info *di, enum cdi_direction reverse)
struct dom_info *di;
enum cdi_direction reverse;
{ {
/* The first block is the ENTRY_BLOCK (or EXIT_BLOCK if REVERSE). */ /* The first block is the ENTRY_BLOCK (or EXIT_BLOCK if REVERSE). */
basic_block begin = reverse ? EXIT_BLOCK_PTR : ENTRY_BLOCK_PTR; basic_block begin = reverse ? EXIT_BLOCK_PTR : ENTRY_BLOCK_PTR;
...@@ -364,9 +354,7 @@ calc_dfs_tree (di, reverse) ...@@ -364,9 +354,7 @@ calc_dfs_tree (di, reverse)
from V to that root. */ from V to that root. */
static void static void
compress (di, v) compress (struct dom_info *di, TBB v)
struct dom_info *di;
TBB v;
{ {
/* Btw. It's not worth to unrecurse compress() as the depth is usually not /* Btw. It's not worth to unrecurse compress() as the depth is usually not
greater than 5 even for huge graphs (I've not seen call depth > 4). greater than 5 even for huge graphs (I've not seen call depth > 4).
...@@ -386,9 +374,7 @@ compress (di, v) ...@@ -386,9 +374,7 @@ compress (di, v)
value on the path from V to the root. */ value on the path from V to the root. */
static inline TBB static inline TBB
eval (di, v) eval (struct dom_info *di, TBB v)
struct dom_info *di;
TBB v;
{ {
/* The representant of the set V is in, also called root (as the set /* The representant of the set V is in, also called root (as the set
representation is a tree). */ representation is a tree). */
...@@ -417,9 +403,7 @@ eval (di, v) ...@@ -417,9 +403,7 @@ eval (di, v)
of W. */ of W. */
static void static void
link_roots (di, v, w) link_roots (struct dom_info *di, TBB v, TBB w)
struct dom_info *di;
TBB v, w;
{ {
TBB s = w; TBB s = w;
...@@ -461,9 +445,7 @@ link_roots (di, v, w) ...@@ -461,9 +445,7 @@ link_roots (di, v, w)
On return the immediate dominator to node V is in di->dom[V]. */ On return the immediate dominator to node V is in di->dom[V]. */
static void static void
calc_idoms (di, reverse) calc_idoms (struct dom_info *di, enum cdi_direction reverse)
struct dom_info *di;
enum cdi_direction reverse;
{ {
TBB v, w, k, par; TBB v, w, k, par;
basic_block en_block; basic_block en_block;
...@@ -557,8 +539,7 @@ calc_idoms (di, reverse) ...@@ -557,8 +539,7 @@ calc_idoms (di, reverse)
immediate resp. all dominators). */ immediate resp. all dominators). */
dominance_info dominance_info
calculate_dominance_info (reverse) calculate_dominance_info (enum cdi_direction reverse)
enum cdi_direction reverse;
{ {
struct dom_info di; struct dom_info di;
dominance_info info; dominance_info info;
...@@ -596,8 +577,7 @@ calculate_dominance_info (reverse) ...@@ -596,8 +577,7 @@ calculate_dominance_info (reverse)
/* Free dominance information. */ /* Free dominance information. */
void void
free_dominance_info (info) free_dominance_info (dominance_info info)
dominance_info info;
{ {
basic_block bb; basic_block bb;
...@@ -616,9 +596,7 @@ free_dominance_info (info) ...@@ -616,9 +596,7 @@ free_dominance_info (info)
/* Return the immediate dominator of basic block BB. */ /* Return the immediate dominator of basic block BB. */
basic_block basic_block
get_immediate_dominator (dom, bb) get_immediate_dominator (dominance_info dom, basic_block bb)
dominance_info dom;
basic_block bb;
{ {
return et_forest_node_value (dom->forest, return et_forest_node_value (dom->forest,
et_forest_parent (dom->forest, et_forest_parent (dom->forest,
...@@ -628,9 +606,7 @@ get_immediate_dominator (dom, bb) ...@@ -628,9 +606,7 @@ get_immediate_dominator (dom, bb)
/* Set the immediate dominator of the block possibly removing /* Set the immediate dominator of the block possibly removing
existing edge. NULL can be used to remove any edge. */ existing edge. NULL can be used to remove any edge. */
inline void inline void
set_immediate_dominator (dom, bb, dominated_by) set_immediate_dominator (dominance_info dom, basic_block bb, basic_block dominated_by)
dominance_info dom;
basic_block bb, dominated_by;
{ {
void *aux_bb_node; void *aux_bb_node;
et_forest_node_t bb_node = BB_NODE (dom, bb); et_forest_node_t bb_node = BB_NODE (dom, bb);
...@@ -649,10 +625,7 @@ set_immediate_dominator (dom, bb, dominated_by) ...@@ -649,10 +625,7 @@ set_immediate_dominator (dom, bb, dominated_by)
/* Store all basic blocks dominated by BB into BBS and return their number. */ /* Store all basic blocks dominated by BB into BBS and return their number. */
int int
get_dominated_by (dom, bb, bbs) get_dominated_by (dominance_info dom, basic_block bb, basic_block **bbs)
dominance_info dom;
basic_block bb;
basic_block **bbs;
{ {
int n, i; int n, i;
...@@ -665,10 +638,7 @@ get_dominated_by (dom, bb, bbs) ...@@ -665,10 +638,7 @@ get_dominated_by (dom, bb, bbs)
/* Redirect all edges pointing to BB to TO. */ /* Redirect all edges pointing to BB to TO. */
void void
redirect_immediate_dominators (dom, bb, to) redirect_immediate_dominators (dominance_info dom, basic_block bb, basic_block to)
dominance_info dom;
basic_block bb;
basic_block to;
{ {
et_forest_node_t *bbs = xmalloc (n_basic_blocks * sizeof (basic_block)); et_forest_node_t *bbs = xmalloc (n_basic_blocks * sizeof (basic_block));
et_forest_node_t node = BB_NODE (dom, bb); et_forest_node_t node = BB_NODE (dom, bb);
...@@ -686,10 +656,7 @@ redirect_immediate_dominators (dom, bb, to) ...@@ -686,10 +656,7 @@ redirect_immediate_dominators (dom, bb, to)
/* Find first basic block in the tree dominating both BB1 and BB2. */ /* Find first basic block in the tree dominating both BB1 and BB2. */
basic_block basic_block
nearest_common_dominator (dom, bb1, bb2) nearest_common_dominator (dominance_info dom, basic_block bb1, basic_block bb2)
dominance_info dom;
basic_block bb1;
basic_block bb2;
{ {
if (!bb1) if (!bb1)
return bb2; return bb2;
...@@ -704,18 +671,14 @@ nearest_common_dominator (dom, bb1, bb2) ...@@ -704,18 +671,14 @@ nearest_common_dominator (dom, bb1, bb2)
/* Return TRUE in case BB1 is dominated by BB2. */ /* Return TRUE in case BB1 is dominated by BB2. */
bool bool
dominated_by_p (dom, bb1, bb2) dominated_by_p (dominance_info dom, basic_block bb1, basic_block bb2)
dominance_info dom;
basic_block bb1;
basic_block bb2;
{ {
return nearest_common_dominator (dom, bb1, bb2) == bb2; return nearest_common_dominator (dom, bb1, bb2) == bb2;
} }
/* Verify invariants of dominator structure. */ /* Verify invariants of dominator structure. */
void void
verify_dominators (dom) verify_dominators (dominance_info dom)
dominance_info dom;
{ {
int err = 0; int err = 0;
basic_block bb; basic_block bb;
...@@ -738,9 +701,7 @@ verify_dominators (dom) ...@@ -738,9 +701,7 @@ verify_dominators (dom)
/* Recount dominator of BB. */ /* Recount dominator of BB. */
basic_block basic_block
recount_dominator (dom, bb) recount_dominator (dominance_info dom, basic_block bb)
dominance_info dom;
basic_block bb;
{ {
basic_block dom_bb = NULL; basic_block dom_bb = NULL;
edge e; edge e;
...@@ -757,10 +718,7 @@ recount_dominator (dom, bb) ...@@ -757,10 +718,7 @@ recount_dominator (dom, bb)
/* Iteratively recount dominators of BBS. The change is supposed to be local /* Iteratively recount dominators of BBS. The change is supposed to be local
and not to grow further. */ and not to grow further. */
void void
iterate_fix_dominators (dom, bbs, n) iterate_fix_dominators (dominance_info dom, basic_block *bbs, int n)
dominance_info dom;
basic_block *bbs;
int n;
{ {
int i, changed = 1; int i, changed = 1;
basic_block old_dom, new_dom; basic_block old_dom, new_dom;
...@@ -782,9 +740,7 @@ iterate_fix_dominators (dom, bbs, n) ...@@ -782,9 +740,7 @@ iterate_fix_dominators (dom, bbs, n)
} }
void void
add_to_dominance_info (dom, bb) add_to_dominance_info (dominance_info dom, basic_block bb)
dominance_info dom;
basic_block bb;
{ {
VARRAY_GROW (dom->varray, last_basic_block + 3); VARRAY_GROW (dom->varray, last_basic_block + 3);
#ifdef ENABLE_CHECKING #ifdef ENABLE_CHECKING
...@@ -795,17 +751,14 @@ add_to_dominance_info (dom, bb) ...@@ -795,17 +751,14 @@ add_to_dominance_info (dom, bb)
} }
void void
delete_from_dominance_info (dom, bb) delete_from_dominance_info (dominance_info dom, basic_block bb)
dominance_info dom;
basic_block bb;
{ {
et_forest_remove_node (dom->forest, BB_NODE (dom, bb)); et_forest_remove_node (dom->forest, BB_NODE (dom, bb));
SET_BB_NODE (dom, bb, NULL); SET_BB_NODE (dom, bb, NULL);
} }
void void
debug_dominance_info (dom) debug_dominance_info (dominance_info dom)
dominance_info dom;
{ {
basic_block bb, bb2; basic_block bb, bb2;
FOR_EACH_BB (bb) FOR_EACH_BB (bb)
......
/* Dwarf2 assembler output helper routines. /* Dwarf2 assembler output helper routines.
Copyright (C) 2001, 2002 Free Software Foundation, Inc. Copyright (C) 2001, 2002, 2003 Free Software Foundation, Inc.
This file is part of GCC. This file is part of GCC.
...@@ -45,9 +45,7 @@ Software Foundation, 59 Temple Place - Suite 330, Boston, MA ...@@ -45,9 +45,7 @@ Software Foundation, 59 Temple Place - Suite 330, Boston, MA
to print a newline, since the caller may want to add a comment. */ to print a newline, since the caller may want to add a comment. */
void void
dw2_assemble_integer (size, x) dw2_assemble_integer (int size, rtx x)
int size;
rtx x;
{ {
const char *op = integer_asm_op (size, FALSE); const char *op = integer_asm_op (size, FALSE);
...@@ -275,8 +273,7 @@ dw2_asm_output_nstring (const char *str, size_t orig_len, ...@@ -275,8 +273,7 @@ dw2_asm_output_nstring (const char *str, size_t orig_len,
/* Return the size of an unsigned LEB128 quantity. */ /* Return the size of an unsigned LEB128 quantity. */
int int
size_of_uleb128 (value) size_of_uleb128 (unsigned HOST_WIDE_INT value)
unsigned HOST_WIDE_INT value;
{ {
int size = 0; int size = 0;
...@@ -293,8 +290,7 @@ size_of_uleb128 (value) ...@@ -293,8 +290,7 @@ size_of_uleb128 (value)
/* Return the size of a signed LEB128 quantity. */ /* Return the size of a signed LEB128 quantity. */
int int
size_of_sleb128 (value) size_of_sleb128 (HOST_WIDE_INT value)
HOST_WIDE_INT value;
{ {
int size = 0, byte; int size = 0, byte;
...@@ -315,8 +311,7 @@ size_of_sleb128 (value) ...@@ -315,8 +311,7 @@ size_of_sleb128 (value)
include leb128. */ include leb128. */
int int
size_of_encoded_value (encoding) size_of_encoded_value (int encoding)
int encoding;
{ {
if (encoding == DW_EH_PE_omit) if (encoding == DW_EH_PE_omit)
return 0; return 0;
...@@ -338,8 +333,7 @@ size_of_encoded_value (encoding) ...@@ -338,8 +333,7 @@ size_of_encoded_value (encoding)
/* Yield a name for a given pointer encoding. */ /* Yield a name for a given pointer encoding. */
const char * const char *
eh_data_format_name (format) eh_data_format_name (int format)
int format;
{ {
#if HAVE_DESIGNATED_INITIALIZERS #if HAVE_DESIGNATED_INITIALIZERS
#define S(p, v) [p] = v, #define S(p, v) [p] = v,
...@@ -675,8 +669,8 @@ dw2_asm_output_delta_sleb128 (const char *lab1 ATTRIBUTE_UNUSED, ...@@ -675,8 +669,8 @@ dw2_asm_output_delta_sleb128 (const char *lab1 ATTRIBUTE_UNUSED,
va_end (ap); va_end (ap);
} }
static rtx dw2_force_const_mem PARAMS ((rtx)); static rtx dw2_force_const_mem (rtx);
static int dw2_output_indirect_constant_1 PARAMS ((splay_tree_node, void *)); static int dw2_output_indirect_constant_1 (splay_tree_node, void *);
static GTY((param1_is (char *), param2_is (tree))) splay_tree indirect_pool; static GTY((param1_is (char *), param2_is (tree))) splay_tree indirect_pool;
...@@ -694,8 +688,7 @@ static GTY(()) int dw2_const_labelno; ...@@ -694,8 +688,7 @@ static GTY(()) int dw2_const_labelno;
"near" the function in any interesting sense. */ "near" the function in any interesting sense. */
static rtx static rtx
dw2_force_const_mem (x) dw2_force_const_mem (rtx x)
rtx x;
{ {
splay_tree_node node; splay_tree_node node;
const char *str; const char *str;
...@@ -755,9 +748,8 @@ dw2_force_const_mem (x) ...@@ -755,9 +748,8 @@ dw2_force_const_mem (x)
splay_tree_foreach. Emit one queued constant to memory. */ splay_tree_foreach. Emit one queued constant to memory. */
static int static int
dw2_output_indirect_constant_1 (node, data) dw2_output_indirect_constant_1 (splay_tree_node node,
splay_tree_node node; void *data ATTRIBUTE_UNUSED)
void* data ATTRIBUTE_UNUSED;
{ {
const char *sym; const char *sym;
rtx sym_ref; rtx sym_ref;
...@@ -775,7 +767,7 @@ dw2_output_indirect_constant_1 (node, data) ...@@ -775,7 +767,7 @@ dw2_output_indirect_constant_1 (node, data)
/* Emit the constants queued through dw2_force_const_mem. */ /* Emit the constants queued through dw2_force_const_mem. */
void void
dw2_output_indirect_constants () dw2_output_indirect_constants (void)
{ {
if (indirect_pool) if (indirect_pool)
splay_tree_foreach (indirect_pool, dw2_output_indirect_constant_1, NULL); splay_tree_foreach (indirect_pool, dw2_output_indirect_constant_1, NULL);
......
This source diff could not be displayed because it is too large. You can view the blob instead.
/* dwarf2out.h - Various declarations for functions found in dwarf2out.c /* dwarf2out.h - Various declarations for functions found in dwarf2out.c
Copyright (C) 1998, 1999, 2000 Free Software Foundation, Inc. Copyright (C) 1998, 1999, 2000, 2003
Free Software Foundation, Inc.
This file is part of GCC. This file is part of GCC.
...@@ -18,11 +19,11 @@ along with GCC; see the file COPYING. If not, write to the Free ...@@ -18,11 +19,11 @@ along with GCC; see the file COPYING. If not, write to the Free
Software Foundation, 59 Temple Place - Suite 330, Boston, MA Software Foundation, 59 Temple Place - Suite 330, Boston, MA
02111-1307, USA. */ 02111-1307, USA. */
extern void dwarf2out_decl PARAMS ((tree)); extern void dwarf2out_decl (tree);
extern void dwarf2out_frame_debug PARAMS ((rtx)); extern void dwarf2out_frame_debug (rtx);
extern void debug_dwarf PARAMS ((void)); extern void debug_dwarf (void);
struct die_struct; struct die_struct;
extern void debug_dwarf_die PARAMS ((struct die_struct *)); extern void debug_dwarf_die (struct die_struct *);
extern void dwarf2out_set_demangle_name_func PARAMS ((const char *(*) (const char *))); extern void dwarf2out_set_demangle_name_func (const char *(*) (const char *));
extern void dwarf2out_add_library_unit_info PARAMS ((const char *, const char *)); extern void dwarf2out_add_library_unit_info (const char *, const char *);
...@@ -775,158 +775,157 @@ static int in_class; ...@@ -775,158 +775,157 @@ static int in_class;
/* Forward declarations for functions defined in this file. */ /* Forward declarations for functions defined in this file. */
static void dwarfout_init PARAMS ((const char *)); static void dwarfout_init (const char *);
static void dwarfout_finish PARAMS ((const char *)); static void dwarfout_finish (const char *);
static void dwarfout_define PARAMS ((unsigned int, const char *)); static void dwarfout_define (unsigned int, const char *);
static void dwarfout_undef PARAMS ((unsigned int, const char *)); static void dwarfout_undef (unsigned int, const char *);
static void dwarfout_start_source_file PARAMS ((unsigned, const char *)); static void dwarfout_start_source_file (unsigned, const char *);
static void dwarfout_start_source_file_check PARAMS ((unsigned, const char *)); static void dwarfout_start_source_file_check (unsigned, const char *);
static void dwarfout_end_source_file PARAMS ((unsigned)); static void dwarfout_end_source_file (unsigned);
static void dwarfout_end_source_file_check PARAMS ((unsigned)); static void dwarfout_end_source_file_check (unsigned);
static void dwarfout_begin_block PARAMS ((unsigned, unsigned)); static void dwarfout_begin_block (unsigned, unsigned);
static void dwarfout_end_block PARAMS ((unsigned, unsigned)); static void dwarfout_end_block (unsigned, unsigned);
static void dwarfout_end_epilogue PARAMS ((unsigned int, const char *)); static void dwarfout_end_epilogue (unsigned int, const char *);
static void dwarfout_source_line PARAMS ((unsigned int, const char *)); static void dwarfout_source_line (unsigned int, const char *);
static void dwarfout_end_prologue PARAMS ((unsigned int, const char *)); static void dwarfout_end_prologue (unsigned int, const char *);
static void dwarfout_end_function PARAMS ((unsigned int)); static void dwarfout_end_function (unsigned int);
static void dwarfout_function_decl PARAMS ((tree)); static void dwarfout_function_decl (tree);
static void dwarfout_global_decl PARAMS ((tree)); static void dwarfout_global_decl (tree);
static void dwarfout_deferred_inline_function PARAMS ((tree)); static void dwarfout_deferred_inline_function (tree);
static void dwarfout_file_scope_decl PARAMS ((tree , int)); static void dwarfout_file_scope_decl (tree , int);
static const char *dwarf_tag_name PARAMS ((unsigned)); static const char *dwarf_tag_name (unsigned);
static const char *dwarf_attr_name PARAMS ((unsigned)); static const char *dwarf_attr_name (unsigned);
static const char *dwarf_stack_op_name PARAMS ((unsigned)); static const char *dwarf_stack_op_name (unsigned);
static const char *dwarf_typemod_name PARAMS ((unsigned)); static const char *dwarf_typemod_name (unsigned);
static const char *dwarf_fmt_byte_name PARAMS ((unsigned)); static const char *dwarf_fmt_byte_name (unsigned);
static const char *dwarf_fund_type_name PARAMS ((unsigned)); static const char *dwarf_fund_type_name (unsigned);
static tree decl_ultimate_origin PARAMS ((tree)); static tree decl_ultimate_origin (tree);
static tree block_ultimate_origin PARAMS ((tree)); static tree block_ultimate_origin (tree);
static tree decl_class_context PARAMS ((tree)); static tree decl_class_context (tree);
#if 0 #if 0
static void output_unsigned_leb128 PARAMS ((unsigned long)); static void output_unsigned_leb128 (unsigned long);
static void output_signed_leb128 PARAMS ((long)); static void output_signed_leb128 (long);
#endif #endif
static int fundamental_type_code PARAMS ((tree)); static int fundamental_type_code (tree);
static tree root_type_1 PARAMS ((tree, int)); static tree root_type_1 (tree, int);
static tree root_type PARAMS ((tree)); static tree root_type (tree);
static void write_modifier_bytes_1 PARAMS ((tree, int, int, int)); static void write_modifier_bytes_1 (tree, int, int, int);
static void write_modifier_bytes PARAMS ((tree, int, int)); static void write_modifier_bytes (tree, int, int);
static inline int type_is_fundamental PARAMS ((tree)); static inline int type_is_fundamental (tree);
static void equate_decl_number_to_die_number PARAMS ((tree)); static void equate_decl_number_to_die_number (tree);
static inline void equate_type_number_to_die_number PARAMS ((tree)); static inline void equate_type_number_to_die_number (tree);
static void output_reg_number PARAMS ((rtx)); static void output_reg_number (rtx);
static void output_mem_loc_descriptor PARAMS ((rtx)); static void output_mem_loc_descriptor (rtx);
static void output_loc_descriptor PARAMS ((rtx)); static void output_loc_descriptor (rtx);
static void output_bound_representation PARAMS ((tree, unsigned, int)); static void output_bound_representation (tree, unsigned, char);
static void output_enumeral_list PARAMS ((tree)); static void output_enumeral_list (tree);
static inline HOST_WIDE_INT ceiling PARAMS ((HOST_WIDE_INT, unsigned int)); static inline HOST_WIDE_INT ceiling (HOST_WIDE_INT, unsigned int);
static inline tree field_type PARAMS ((tree)); static inline tree field_type (tree);
static inline unsigned int simple_type_align_in_bits PARAMS ((tree)); static inline unsigned int simple_type_align_in_bits (tree);
static inline unsigned HOST_WIDE_INT simple_type_size_in_bits PARAMS ((tree)); static inline unsigned HOST_WIDE_INT simple_type_size_in_bits (tree);
static HOST_WIDE_INT field_byte_offset PARAMS ((tree)); static HOST_WIDE_INT field_byte_offset (tree);
static inline void sibling_attribute PARAMS ((void)); static inline void sibling_attribute (void);
static void location_attribute PARAMS ((rtx)); static void location_attribute (rtx);
static void data_member_location_attribute PARAMS ((tree)); static void data_member_location_attribute (tree);
static void const_value_attribute PARAMS ((rtx)); static void const_value_attribute (rtx);
static void location_or_const_value_attribute PARAMS ((tree)); static void location_or_const_value_attribute (tree);
static inline void name_attribute PARAMS ((const char *)); static inline void name_attribute (const char *);
static inline void fund_type_attribute PARAMS ((unsigned)); static inline void fund_type_attribute (unsigned);
static void mod_fund_type_attribute PARAMS ((tree, int, int)); static void mod_fund_type_attribute (tree, int, int);
static inline void user_def_type_attribute PARAMS ((tree)); static inline void user_def_type_attribute (tree);
static void mod_u_d_type_attribute PARAMS ((tree, int, int)); static void mod_u_d_type_attribute (tree, int, int);
#ifdef USE_ORDERING_ATTRIBUTE #ifdef USE_ORDERING_ATTRIBUTE
static inline void ordering_attribute PARAMS ((unsigned)); static inline void ordering_attribute (unsigned);
#endif /* defined(USE_ORDERING_ATTRIBUTE) */ #endif /* defined(USE_ORDERING_ATTRIBUTE) */
static void subscript_data_attribute PARAMS ((tree)); static void subscript_data_attribute (tree);
static void byte_size_attribute PARAMS ((tree)); static void byte_size_attribute (tree);
static inline void bit_offset_attribute PARAMS ((tree)); static inline void bit_offset_attribute (tree);
static inline void bit_size_attribute PARAMS ((tree)); static inline void bit_size_attribute (tree);
static inline void element_list_attribute PARAMS ((tree)); static inline void element_list_attribute (tree);
static inline void stmt_list_attribute PARAMS ((const char *)); static inline void stmt_list_attribute (const char *);
static inline void low_pc_attribute PARAMS ((const char *)); static inline void low_pc_attribute (const char *);
static inline void high_pc_attribute PARAMS ((const char *)); static inline void high_pc_attribute (const char *);
static inline void body_begin_attribute PARAMS ((const char *)); static inline void body_begin_attribute (const char *);
static inline void body_end_attribute PARAMS ((const char *)); static inline void body_end_attribute (const char *);
static inline void language_attribute PARAMS ((unsigned)); static inline void language_attribute (unsigned);
static inline void member_attribute PARAMS ((tree)); static inline void member_attribute (tree);
#if 0 #if 0
static inline void string_length_attribute PARAMS ((tree)); static inline void string_length_attribute (tree);
#endif #endif
static inline void comp_dir_attribute PARAMS ((const char *)); static inline void comp_dir_attribute (const char *);
static inline void sf_names_attribute PARAMS ((const char *)); static inline void sf_names_attribute (const char *);
static inline void src_info_attribute PARAMS ((const char *)); static inline void src_info_attribute (const char *);
static inline void mac_info_attribute PARAMS ((const char *)); static inline void mac_info_attribute (const char *);
static inline void prototyped_attribute PARAMS ((tree)); static inline void prototyped_attribute (tree);
static inline void producer_attribute PARAMS ((const char *)); static inline void producer_attribute (const char *);
static inline void inline_attribute PARAMS ((tree)); static inline void inline_attribute (tree);
static inline void containing_type_attribute PARAMS ((tree)); static inline void containing_type_attribute (tree);
static inline void abstract_origin_attribute PARAMS ((tree)); static inline void abstract_origin_attribute (tree);
#ifdef DWARF_DECL_COORDINATES #ifdef DWARF_DECL_COORDINATES
static inline void src_coords_attribute PARAMS ((unsigned, unsigned)); static inline void src_coords_attribute (unsigned, unsigned);
#endif /* defined(DWARF_DECL_COORDINATES) */ #endif /* defined(DWARF_DECL_COORDINATES) */
static inline void pure_or_virtual_attribute PARAMS ((tree)); static inline void pure_or_virtual_attribute (tree);
static void name_and_src_coords_attributes PARAMS ((tree)); static void name_and_src_coords_attributes (tree);
static void type_attribute PARAMS ((tree, int, int)); static void type_attribute (tree, int, int);
static const char *type_tag PARAMS ((tree)); static const char *type_tag (tree);
static inline void dienum_push PARAMS ((void)); static inline void dienum_push (void);
static inline void dienum_pop PARAMS ((void)); static inline void dienum_pop (void);
static inline tree member_declared_type PARAMS ((tree)); static inline tree member_declared_type (tree);
static const char *function_start_label PARAMS ((tree)); static const char *function_start_label (tree);
static void output_array_type_die PARAMS ((void *)); static void output_array_type_die (void *);
static void output_set_type_die PARAMS ((void *)); static void output_set_type_die (void *);
#if 0 #if 0
static void output_entry_point_die PARAMS ((void *)); static void output_entry_point_die (void *);
#endif #endif
static void output_inlined_enumeration_type_die PARAMS ((void *)); static void output_inlined_enumeration_type_die (void *);
static void output_inlined_structure_type_die PARAMS ((void *)); static void output_inlined_structure_type_die (void *);
static void output_inlined_union_type_die PARAMS ((void *)); static void output_inlined_union_type_die (void *);
static void output_enumeration_type_die PARAMS ((void *)); static void output_enumeration_type_die (void *);
static void output_formal_parameter_die PARAMS ((void *)); static void output_formal_parameter_die (void *);
static void output_global_subroutine_die PARAMS ((void *)); static void output_global_subroutine_die (void *);
static void output_global_variable_die PARAMS ((void *)); static void output_global_variable_die (void *);
static void output_label_die PARAMS ((void *)); static void output_label_die (void *);
static void output_lexical_block_die PARAMS ((void *)); static void output_lexical_block_die (void *);
static void output_inlined_subroutine_die PARAMS ((void *)); static void output_inlined_subroutine_die (void *);
static void output_local_variable_die PARAMS ((void *)); static void output_local_variable_die (void *);
static void output_member_die PARAMS ((void *)); static void output_member_die (void *);
#if 0 #if 0
static void output_pointer_type_die PARAMS ((void *)); static void output_pointer_type_die (void *);
static void output_reference_type_die PARAMS ((void *)); static void output_reference_type_die (void *);
#endif #endif
static void output_ptr_to_mbr_type_die PARAMS ((void *)); static void output_ptr_to_mbr_type_die (void *);
static void output_compile_unit_die PARAMS ((void *)); static void output_compile_unit_die (void *);
static void output_string_type_die PARAMS ((void *)); static void output_string_type_die (void *);
static void output_inheritance_die PARAMS ((void *)); static void output_inheritance_die (void *);
static void output_structure_type_die PARAMS ((void *)); static void output_structure_type_die (void *);
static void output_local_subroutine_die PARAMS ((void *)); static void output_local_subroutine_die (void *);
static void output_subroutine_type_die PARAMS ((void *)); static void output_subroutine_type_die (void *);
static void output_typedef_die PARAMS ((void *)); static void output_typedef_die (void *);
static void output_union_type_die PARAMS ((void *)); static void output_union_type_die (void *);
static void output_unspecified_parameters_die PARAMS ((void *)); static void output_unspecified_parameters_die (void *);
static void output_padded_null_die PARAMS ((void *)); static void output_padded_null_die (void *);
static void output_die PARAMS ((void (*)(void *), void *)); static void output_die (void (*)(void *), void *);
static void end_sibling_chain PARAMS ((void)); static void end_sibling_chain (void);
static void output_formal_types PARAMS ((tree)); static void output_formal_types (tree);
static void pend_type PARAMS ((tree)); static void pend_type (tree);
static int type_ok_for_scope PARAMS ((tree, tree)); static int type_ok_for_scope (tree, tree);
static void output_pending_types_for_scope PARAMS ((tree)); static void output_pending_types_for_scope (tree);
static void output_type PARAMS ((tree, tree)); static void output_type (tree, tree);
static void output_tagged_type_instantiation PARAMS ((tree)); static void output_tagged_type_instantiation (tree);
static void output_block PARAMS ((tree, int)); static void output_block (tree, int);
static void output_decls_for_scope PARAMS ((tree, int)); static void output_decls_for_scope (tree, int);
static void output_decl PARAMS ((tree, tree)); static void output_decl (tree, tree);
static void shuffle_filename_entry PARAMS ((filename_entry *)); static void shuffle_filename_entry (filename_entry *);
static void generate_new_sfname_entry PARAMS ((void)); static void generate_new_sfname_entry (void);
static unsigned lookup_filename PARAMS ((const char *)); static unsigned lookup_filename (const char *);
static void generate_srcinfo_entry PARAMS ((unsigned, unsigned)); static void generate_srcinfo_entry (unsigned, unsigned);
static void generate_macinfo_entry PARAMS ((unsigned int, rtx, static void generate_macinfo_entry (unsigned int, rtx, const char *);
const char *)); static int is_pseudo_reg (rtx);
static int is_pseudo_reg PARAMS ((rtx)); static tree type_main_variant (tree);
static tree type_main_variant PARAMS ((tree)); static int is_tagged_type (tree);
static int is_tagged_type PARAMS ((tree)); static int is_redundant_typedef (tree);
static int is_redundant_typedef PARAMS ((tree)); static void add_incomplete_type (tree);
static void add_incomplete_type PARAMS ((tree)); static void retry_incomplete_types (void);
static void retry_incomplete_types PARAMS ((void));
/* Definitions of defaults for assembler-dependent names of various /* Definitions of defaults for assembler-dependent names of various
pseudo-ops and section names. pseudo-ops and section names.
...@@ -1301,8 +1300,7 @@ const struct gcc_debug_hooks dwarf_debug_hooks = ...@@ -1301,8 +1300,7 @@ const struct gcc_debug_hooks dwarf_debug_hooks =
/************************ general utility functions **************************/ /************************ general utility functions **************************/
static inline int static inline int
is_pseudo_reg (rtl) is_pseudo_reg (rtx rtl)
rtx rtl;
{ {
return (((GET_CODE (rtl) == REG) && (REGNO (rtl) >= FIRST_PSEUDO_REGISTER)) return (((GET_CODE (rtl) == REG) && (REGNO (rtl) >= FIRST_PSEUDO_REGISTER))
|| ((GET_CODE (rtl) == SUBREG) || ((GET_CODE (rtl) == SUBREG)
...@@ -1310,8 +1308,7 @@ is_pseudo_reg (rtl) ...@@ -1310,8 +1308,7 @@ is_pseudo_reg (rtl)
} }
static inline tree static inline tree
type_main_variant (type) type_main_variant (tree type)
tree type;
{ {
type = TYPE_MAIN_VARIANT (type); type = TYPE_MAIN_VARIANT (type);
...@@ -1332,8 +1329,7 @@ type_main_variant (type) ...@@ -1332,8 +1329,7 @@ type_main_variant (type)
/* Return nonzero if the given type node represents a tagged type. */ /* Return nonzero if the given type node represents a tagged type. */
static inline int static inline int
is_tagged_type (type) is_tagged_type (tree type)
tree type;
{ {
enum tree_code code = TREE_CODE (type); enum tree_code code = TREE_CODE (type);
...@@ -1342,8 +1338,7 @@ is_tagged_type (type) ...@@ -1342,8 +1338,7 @@ is_tagged_type (type)
} }
static const char * static const char *
dwarf_tag_name (tag) dwarf_tag_name (unsigned int tag)
unsigned tag;
{ {
switch (tag) switch (tag)
{ {
...@@ -1392,8 +1387,7 @@ dwarf_tag_name (tag) ...@@ -1392,8 +1387,7 @@ dwarf_tag_name (tag)
} }
static const char * static const char *
dwarf_attr_name (attr) dwarf_attr_name (unsigned int attr)
unsigned attr;
{ {
switch (attr) switch (attr)
{ {
...@@ -1470,8 +1464,7 @@ dwarf_attr_name (attr) ...@@ -1470,8 +1464,7 @@ dwarf_attr_name (attr)
} }
static const char * static const char *
dwarf_stack_op_name (op) dwarf_stack_op_name (unsigned int op)
unsigned op;
{ {
switch (op) switch (op)
{ {
...@@ -1487,8 +1480,7 @@ dwarf_stack_op_name (op) ...@@ -1487,8 +1480,7 @@ dwarf_stack_op_name (op)
} }
static const char * static const char *
dwarf_typemod_name (mod) dwarf_typemod_name (unsigned int mod)
unsigned mod;
{ {
switch (mod) switch (mod)
{ {
...@@ -1501,8 +1493,7 @@ dwarf_typemod_name (mod) ...@@ -1501,8 +1493,7 @@ dwarf_typemod_name (mod)
} }
static const char * static const char *
dwarf_fmt_byte_name (fmt) dwarf_fmt_byte_name (unsigned int fmt)
unsigned fmt;
{ {
switch (fmt) switch (fmt)
{ {
...@@ -1520,8 +1511,7 @@ dwarf_fmt_byte_name (fmt) ...@@ -1520,8 +1511,7 @@ dwarf_fmt_byte_name (fmt)
} }
static const char * static const char *
dwarf_fund_type_name (ft) dwarf_fund_type_name (unsigned int ft)
unsigned ft;
{ {
switch (ft) switch (ft)
{ {
...@@ -1586,8 +1576,7 @@ dwarf_fund_type_name (ft) ...@@ -1586,8 +1576,7 @@ dwarf_fund_type_name (ft)
served as the original seed for the given block. */ served as the original seed for the given block. */
static tree static tree
decl_ultimate_origin (decl) decl_ultimate_origin (tree decl)
tree decl;
{ {
#ifdef ENABLE_CHECKING #ifdef ENABLE_CHECKING
if (DECL_FROM_INLINE (DECL_ORIGIN (decl))) if (DECL_FROM_INLINE (DECL_ORIGIN (decl)))
...@@ -1606,8 +1595,7 @@ decl_ultimate_origin (decl) ...@@ -1606,8 +1595,7 @@ decl_ultimate_origin (decl)
served as the original seed for the given block. */ served as the original seed for the given block. */
static tree static tree
block_ultimate_origin (block) block_ultimate_origin (tree block)
tree block;
{ {
tree immediate_origin = BLOCK_ABSTRACT_ORIGIN (block); tree immediate_origin = BLOCK_ABSTRACT_ORIGIN (block);
...@@ -1635,8 +1623,7 @@ block_ultimate_origin (block) ...@@ -1635,8 +1623,7 @@ block_ultimate_origin (block)
parameter. */ parameter. */
static tree static tree
decl_class_context (decl) decl_class_context (tree decl)
tree decl;
{ {
tree context = NULL_TREE; tree context = NULL_TREE;
if (TREE_CODE (decl) != FUNCTION_DECL || ! DECL_VINDEX (decl)) if (TREE_CODE (decl) != FUNCTION_DECL || ! DECL_VINDEX (decl))
...@@ -1653,8 +1640,7 @@ decl_class_context (decl) ...@@ -1653,8 +1640,7 @@ decl_class_context (decl)
#if 0 #if 0
static void static void
output_unsigned_leb128 (value) output_unsigned_leb128 (unsigned long value)
unsigned long value;
{ {
unsigned long orig_value = value; unsigned long orig_value = value;
...@@ -1672,8 +1658,7 @@ output_unsigned_leb128 (value) ...@@ -1672,8 +1658,7 @@ output_unsigned_leb128 (value)
} }
static void static void
output_signed_leb128 (value) output_signed_leb128 (long value)
long value;
{ {
long orig_value = value; long orig_value = value;
int negative = (value < 0); int negative = (value < 0);
...@@ -1728,8 +1713,7 @@ output_signed_leb128 (value) ...@@ -1728,8 +1713,7 @@ output_signed_leb128 (value)
draft specification is probably never even useful in practice. */ draft specification is probably never even useful in practice. */
static int static int
fundamental_type_code (type) fundamental_type_code (tree type)
tree type;
{ {
if (TREE_CODE (type) == ERROR_MARK) if (TREE_CODE (type) == ERROR_MARK)
return 0; return 0;
...@@ -1870,9 +1854,7 @@ fundamental_type_code (type) ...@@ -1870,9 +1854,7 @@ fundamental_type_code (type)
qualifiers. */ qualifiers. */
static tree static tree
root_type_1 (type, count) root_type_1 (tree type, int count)
tree type;
int count;
{ {
/* Give up after searching 1000 levels, in case this is a recursive /* Give up after searching 1000 levels, in case this is a recursive
pointer type. Such types are possible in Ada, but it is not possible pointer type. Such types are possible in Ada, but it is not possible
...@@ -1895,8 +1877,7 @@ root_type_1 (type, count) ...@@ -1895,8 +1877,7 @@ root_type_1 (type, count)
} }
static tree static tree
root_type (type) root_type (tree type)
tree type;
{ {
type = root_type_1 (type, 0); type = root_type_1 (type, 0);
if (type != error_mark_node) if (type != error_mark_node)
...@@ -1908,11 +1889,7 @@ root_type (type) ...@@ -1908,11 +1889,7 @@ root_type (type)
of zero or more Dwarf "type-modifier" bytes applicable to the type. */ of zero or more Dwarf "type-modifier" bytes applicable to the type. */
static void static void
write_modifier_bytes_1 (type, decl_const, decl_volatile, count) write_modifier_bytes_1 (tree type, int decl_const, int decl_volatile, int count)
tree type;
int decl_const;
int decl_volatile;
int count;
{ {
if (TREE_CODE (type) == ERROR_MARK) if (TREE_CODE (type) == ERROR_MARK)
return; return;
...@@ -1946,10 +1923,7 @@ write_modifier_bytes_1 (type, decl_const, decl_volatile, count) ...@@ -1946,10 +1923,7 @@ write_modifier_bytes_1 (type, decl_const, decl_volatile, count)
} }
static void static void
write_modifier_bytes (type, decl_const, decl_volatile) write_modifier_bytes (tree type, int decl_const, int decl_volatile)
tree type;
int decl_const;
int decl_volatile;
{ {
write_modifier_bytes_1 (type, decl_const, decl_volatile, 0); write_modifier_bytes_1 (type, decl_const, decl_volatile, 0);
} }
...@@ -1958,8 +1932,7 @@ write_modifier_bytes (type, decl_const, decl_volatile) ...@@ -1958,8 +1932,7 @@ write_modifier_bytes (type, decl_const, decl_volatile)
given input type is a Dwarf "fundamental" type. Otherwise return zero. */ given input type is a Dwarf "fundamental" type. Otherwise return zero. */
static inline int static inline int
type_is_fundamental (type) type_is_fundamental (tree type)
tree type;
{ {
switch (TREE_CODE (type)) switch (TREE_CODE (type))
{ {
...@@ -2008,8 +1981,7 @@ type_is_fundamental (type) ...@@ -2008,8 +1981,7 @@ type_is_fundamental (type)
UID number. */ UID number. */
static void static void
equate_decl_number_to_die_number (decl) equate_decl_number_to_die_number (tree decl)
tree decl;
{ {
/* In the case where we are generating a DIE for some ..._DECL node /* In the case where we are generating a DIE for some ..._DECL node
which represents either some inline function declaration or some which represents either some inline function declaration or some
...@@ -2040,8 +2012,7 @@ equate_decl_number_to_die_number (decl) ...@@ -2040,8 +2012,7 @@ equate_decl_number_to_die_number (decl)
UID number. */ UID number. */
static inline void static inline void
equate_type_number_to_die_number (type) equate_type_number_to_die_number (tree type)
tree type;
{ {
char type_label[MAX_ARTIFICIAL_LABEL_BYTES]; char type_label[MAX_ARTIFICIAL_LABEL_BYTES];
char die_label[MAX_ARTIFICIAL_LABEL_BYTES]; char die_label[MAX_ARTIFICIAL_LABEL_BYTES];
...@@ -2059,8 +2030,7 @@ equate_type_number_to_die_number (type) ...@@ -2059,8 +2030,7 @@ equate_type_number_to_die_number (type)
} }
static void static void
output_reg_number (rtl) output_reg_number (rtx rtl)
rtx rtl;
{ {
unsigned regno = REGNO (rtl); unsigned regno = REGNO (rtl);
...@@ -2091,8 +2061,7 @@ output_reg_number (rtl) ...@@ -2091,8 +2061,7 @@ output_reg_number (rtl)
RTL tree, turning it into Dwarf postfix code as it goes. */ RTL tree, turning it into Dwarf postfix code as it goes. */
static void static void
output_mem_loc_descriptor (rtl) output_mem_loc_descriptor (rtx rtl)
rtx rtl;
{ {
/* Note that for a dynamically sized array, the location we will /* Note that for a dynamically sized array, the location we will
generate a description of here will be the lowest numbered location generate a description of here will be the lowest numbered location
...@@ -2182,8 +2151,7 @@ output_mem_loc_descriptor (rtl) ...@@ -2182,8 +2151,7 @@ output_mem_loc_descriptor (rtl)
generate the (dynamic) address of the object onto the address stack. */ generate the (dynamic) address of the object onto the address stack. */
static void static void
output_loc_descriptor (rtl) output_loc_descriptor (rtx rtl)
rtx rtl;
{ {
switch (GET_CODE (rtl)) switch (GET_CODE (rtl))
{ {
...@@ -2213,13 +2181,12 @@ output_loc_descriptor (rtl) ...@@ -2213,13 +2181,12 @@ output_loc_descriptor (rtl)
} }
/* Given a tree node describing an array bound (either lower or upper) /* Given a tree node describing an array bound (either lower or upper)
output a representation for that bound. */ output a representation for that bound. DIM_NUM is used for
multi-dimensional arrays and U_OR_L disgnates upper or lower
bound. */
static void static void
output_bound_representation (bound, dim_num, u_or_l) output_bound_representation (tree bound, unsigned int dim_num, char u_or_l)
tree bound;
unsigned dim_num; /* For multi-dimensional arrays. */
char u_or_l; /* Designates upper or lower bound. */
{ {
switch (TREE_CODE (bound)) switch (TREE_CODE (bound))
{ {
...@@ -2300,8 +2267,7 @@ output_bound_representation (bound, dim_num, u_or_l) ...@@ -2300,8 +2267,7 @@ output_bound_representation (bound, dim_num, u_or_l)
enumeration_type_die. */ enumeration_type_die. */
static void static void
output_enumeral_list (link) output_enumeral_list (tree link)
tree link;
{ {
if (link) if (link)
{ {
...@@ -2320,9 +2286,7 @@ output_enumeral_list (link) ...@@ -2320,9 +2286,7 @@ output_enumeral_list (link)
which is not less than the value itself. */ which is not less than the value itself. */
static inline HOST_WIDE_INT static inline HOST_WIDE_INT
ceiling (value, boundary) ceiling (HOST_WIDE_INT value, unsigned int boundary)
HOST_WIDE_INT value;
unsigned int boundary;
{ {
return (((value + boundary - 1) / boundary) * boundary); return (((value + boundary - 1) / boundary) * boundary);
} }
...@@ -2332,8 +2296,7 @@ ceiling (value, boundary) ...@@ -2332,8 +2296,7 @@ ceiling (value, boundary)
`integer_type_node' if the given node turns out to be an ERROR_MARK node. */ `integer_type_node' if the given node turns out to be an ERROR_MARK node. */
static inline tree static inline tree
field_type (decl) field_type (tree decl)
tree decl;
{ {
tree type; tree type;
...@@ -2351,8 +2314,7 @@ field_type (decl) ...@@ -2351,8 +2314,7 @@ field_type (decl)
BITS_PER_WORD if the node actually turns out to be an ERROR_MARK node. */ BITS_PER_WORD if the node actually turns out to be an ERROR_MARK node. */
static inline unsigned int static inline unsigned int
simple_type_align_in_bits (type) simple_type_align_in_bits (tree type)
tree type;
{ {
return (TREE_CODE (type) != ERROR_MARK) ? TYPE_ALIGN (type) : BITS_PER_WORD; return (TREE_CODE (type) != ERROR_MARK) ? TYPE_ALIGN (type) : BITS_PER_WORD;
} }
...@@ -2364,8 +2326,7 @@ simple_type_align_in_bits (type) ...@@ -2364,8 +2326,7 @@ simple_type_align_in_bits (type)
to be an ERROR_MARK node. */ to be an ERROR_MARK node. */
static inline unsigned HOST_WIDE_INT static inline unsigned HOST_WIDE_INT
simple_type_size_in_bits (type) simple_type_size_in_bits (tree type)
tree type;
{ {
tree type_size_tree; tree type_size_tree;
...@@ -2388,8 +2349,7 @@ simple_type_size_in_bits (type) ...@@ -2388,8 +2349,7 @@ simple_type_size_in_bits (type)
(We can't handle the latter case just yet.) */ (We can't handle the latter case just yet.) */
static HOST_WIDE_INT static HOST_WIDE_INT
field_byte_offset (decl) field_byte_offset (tree decl)
tree decl;
{ {
unsigned int type_align_in_bytes; unsigned int type_align_in_bytes;
unsigned int type_align_in_bits; unsigned int type_align_in_bits;
...@@ -2534,7 +2494,7 @@ field_byte_offset (decl) ...@@ -2534,7 +2494,7 @@ field_byte_offset (decl)
/* Generate an AT_sibling attribute. */ /* Generate an AT_sibling attribute. */
static inline void static inline void
sibling_attribute () sibling_attribute (void)
{ {
char label[MAX_ARTIFICIAL_LABEL_BYTES]; char label[MAX_ARTIFICIAL_LABEL_BYTES];
...@@ -2548,8 +2508,7 @@ sibling_attribute () ...@@ -2548,8 +2508,7 @@ sibling_attribute ()
are generated by the routine `data_member_location_attribute' below. */ are generated by the routine `data_member_location_attribute' below. */
static void static void
location_attribute (rtl) location_attribute (rtx rtl)
rtx rtl;
{ {
char begin_label[MAX_ARTIFICIAL_LABEL_BYTES]; char begin_label[MAX_ARTIFICIAL_LABEL_BYTES];
char end_label[MAX_ARTIFICIAL_LABEL_BYTES]; char end_label[MAX_ARTIFICIAL_LABEL_BYTES];
...@@ -2611,8 +2570,7 @@ location_attribute (rtl) ...@@ -2611,8 +2570,7 @@ location_attribute (rtl)
(See the `bit_offset_attribute' function below.) */ (See the `bit_offset_attribute' function below.) */
static void static void
data_member_location_attribute (t) data_member_location_attribute (tree t)
tree t;
{ {
unsigned object_offset_in_bytes; unsigned object_offset_in_bytes;
char begin_label[MAX_ARTIFICIAL_LABEL_BYTES]; char begin_label[MAX_ARTIFICIAL_LABEL_BYTES];
...@@ -2641,8 +2599,7 @@ data_member_location_attribute (t) ...@@ -2641,8 +2599,7 @@ data_member_location_attribute (t)
declared constants do not necessarily get memory "homes". */ declared constants do not necessarily get memory "homes". */
static void static void
const_value_attribute (rtl) const_value_attribute (rtx rtl)
rtx rtl;
{ {
char begin_label[MAX_ARTIFICIAL_LABEL_BYTES]; char begin_label[MAX_ARTIFICIAL_LABEL_BYTES];
char end_label[MAX_ARTIFICIAL_LABEL_BYTES]; char end_label[MAX_ARTIFICIAL_LABEL_BYTES];
...@@ -2726,8 +2683,7 @@ const_value_attribute (rtl) ...@@ -2726,8 +2683,7 @@ const_value_attribute (rtl)
call evaluates to a compile-time constant address. */ call evaluates to a compile-time constant address. */
static void static void
location_or_const_value_attribute (decl) location_or_const_value_attribute (tree decl)
tree decl;
{ {
rtx rtl; rtx rtl;
...@@ -2886,8 +2842,7 @@ location_or_const_value_attribute (decl) ...@@ -2886,8 +2842,7 @@ location_or_const_value_attribute (decl)
the value of the attribute. */ the value of the attribute. */
static inline void static inline void
name_attribute (name_string) name_attribute (const char *name_string)
const char *name_string;
{ {
if (name_string && *name_string) if (name_string && *name_string)
{ {
...@@ -2897,18 +2852,14 @@ name_attribute (name_string) ...@@ -2897,18 +2852,14 @@ name_attribute (name_string)
} }
static inline void static inline void
fund_type_attribute (ft_code) fund_type_attribute (unsigned int ft_code)
unsigned ft_code;
{ {
ASM_OUTPUT_DWARF_ATTRIBUTE (asm_out_file, AT_fund_type); ASM_OUTPUT_DWARF_ATTRIBUTE (asm_out_file, AT_fund_type);
ASM_OUTPUT_DWARF_FUND_TYPE (asm_out_file, ft_code); ASM_OUTPUT_DWARF_FUND_TYPE (asm_out_file, ft_code);
} }
static void static void
mod_fund_type_attribute (type, decl_const, decl_volatile) mod_fund_type_attribute (tree type, int decl_const, int decl_volatile)
tree type;
int decl_const;
int decl_volatile;
{ {
char begin_label[MAX_ARTIFICIAL_LABEL_BYTES]; char begin_label[MAX_ARTIFICIAL_LABEL_BYTES];
char end_label[MAX_ARTIFICIAL_LABEL_BYTES]; char end_label[MAX_ARTIFICIAL_LABEL_BYTES];
...@@ -2925,8 +2876,7 @@ mod_fund_type_attribute (type, decl_const, decl_volatile) ...@@ -2925,8 +2876,7 @@ mod_fund_type_attribute (type, decl_const, decl_volatile)
} }
static inline void static inline void
user_def_type_attribute (type) user_def_type_attribute (tree type)
tree type;
{ {
char ud_type_name[MAX_ARTIFICIAL_LABEL_BYTES]; char ud_type_name[MAX_ARTIFICIAL_LABEL_BYTES];
...@@ -2936,10 +2886,7 @@ user_def_type_attribute (type) ...@@ -2936,10 +2886,7 @@ user_def_type_attribute (type)
} }
static void static void
mod_u_d_type_attribute (type, decl_const, decl_volatile) mod_u_d_type_attribute (tree type, int decl_const, int decl_volatile)
tree type;
int decl_const;
int decl_volatile;
{ {
char begin_label[MAX_ARTIFICIAL_LABEL_BYTES]; char begin_label[MAX_ARTIFICIAL_LABEL_BYTES];
char end_label[MAX_ARTIFICIAL_LABEL_BYTES]; char end_label[MAX_ARTIFICIAL_LABEL_BYTES];
...@@ -2958,8 +2905,7 @@ mod_u_d_type_attribute (type, decl_const, decl_volatile) ...@@ -2958,8 +2905,7 @@ mod_u_d_type_attribute (type, decl_const, decl_volatile)
#ifdef USE_ORDERING_ATTRIBUTE #ifdef USE_ORDERING_ATTRIBUTE
static inline void static inline void
ordering_attribute (ordering) ordering_attribute (unsigned ordering)
unsigned ordering;
{ {
ASM_OUTPUT_DWARF_ATTRIBUTE (asm_out_file, AT_ordering); ASM_OUTPUT_DWARF_ATTRIBUTE (asm_out_file, AT_ordering);
ASM_OUTPUT_DWARF_DATA2 (asm_out_file, ordering); ASM_OUTPUT_DWARF_DATA2 (asm_out_file, ordering);
...@@ -2970,8 +2916,7 @@ ordering_attribute (ordering) ...@@ -2970,8 +2916,7 @@ ordering_attribute (ordering)
includes information about the element type of type given array type. */ includes information about the element type of type given array type. */
static void static void
subscript_data_attribute (type) subscript_data_attribute (tree type)
tree type;
{ {
unsigned dimension_number; unsigned dimension_number;
char begin_label[MAX_ARTIFICIAL_LABEL_BYTES]; char begin_label[MAX_ARTIFICIAL_LABEL_BYTES];
...@@ -3069,8 +3014,7 @@ subscript_data_attribute (type) ...@@ -3069,8 +3014,7 @@ subscript_data_attribute (type)
} }
static void static void
byte_size_attribute (tree_node) byte_size_attribute (tree tree_node)
tree tree_node;
{ {
unsigned size; unsigned size;
...@@ -3129,8 +3073,7 @@ byte_size_attribute (tree_node) ...@@ -3129,8 +3073,7 @@ byte_size_attribute (tree_node)
bit-field. (See `byte_size_attribute' above.) */ bit-field. (See `byte_size_attribute' above.) */
static inline void static inline void
bit_offset_attribute (decl) bit_offset_attribute (tree decl)
tree decl;
{ {
HOST_WIDE_INT object_offset_in_bytes = field_byte_offset (decl); HOST_WIDE_INT object_offset_in_bytes = field_byte_offset (decl);
tree type = DECL_BIT_FIELD_TYPE (decl); tree type = DECL_BIT_FIELD_TYPE (decl);
...@@ -3182,8 +3125,7 @@ bit_offset_attribute (decl) ...@@ -3182,8 +3125,7 @@ bit_offset_attribute (decl)
which specifies the length in bits of the given field. */ which specifies the length in bits of the given field. */
static inline void static inline void
bit_size_attribute (decl) bit_size_attribute (tree decl)
tree decl;
{ {
/* Must be a field and a bit field. */ /* Must be a field and a bit field. */
if (TREE_CODE (decl) != FIELD_DECL if (TREE_CODE (decl) != FIELD_DECL
...@@ -3204,8 +3146,7 @@ bit_size_attribute (decl) ...@@ -3204,8 +3146,7 @@ bit_size_attribute (decl)
type. */ type. */
static inline void static inline void
element_list_attribute (element) element_list_attribute (tree element)
tree element;
{ {
char begin_label[MAX_ARTIFICIAL_LABEL_BYTES]; char begin_label[MAX_ARTIFICIAL_LABEL_BYTES];
char end_label[MAX_ARTIFICIAL_LABEL_BYTES]; char end_label[MAX_ARTIFICIAL_LABEL_BYTES];
...@@ -3230,8 +3171,7 @@ element_list_attribute (element) ...@@ -3230,8 +3171,7 @@ element_list_attribute (element)
DIEs with a TAG_compile_unit tag. */ DIEs with a TAG_compile_unit tag. */
static inline void static inline void
stmt_list_attribute (label) stmt_list_attribute (const char *label)
const char *label;
{ {
ASM_OUTPUT_DWARF_ATTRIBUTE (asm_out_file, AT_stmt_list); ASM_OUTPUT_DWARF_ATTRIBUTE (asm_out_file, AT_stmt_list);
/* Don't use ASM_OUTPUT_DWARF_DATA4 here. */ /* Don't use ASM_OUTPUT_DWARF_DATA4 here. */
...@@ -3242,8 +3182,7 @@ stmt_list_attribute (label) ...@@ -3242,8 +3182,7 @@ stmt_list_attribute (label)
for a subroutine DIE. */ for a subroutine DIE. */
static inline void static inline void
low_pc_attribute (asm_low_label) low_pc_attribute (const char *asm_low_label)
const char *asm_low_label;
{ {
ASM_OUTPUT_DWARF_ATTRIBUTE (asm_out_file, AT_low_pc); ASM_OUTPUT_DWARF_ATTRIBUTE (asm_out_file, AT_low_pc);
ASM_OUTPUT_DWARF_ADDR (asm_out_file, asm_low_label); ASM_OUTPUT_DWARF_ADDR (asm_out_file, asm_low_label);
...@@ -3253,8 +3192,7 @@ low_pc_attribute (asm_low_label) ...@@ -3253,8 +3192,7 @@ low_pc_attribute (asm_low_label)
subroutine DIE. */ subroutine DIE. */
static inline void static inline void
high_pc_attribute (asm_high_label) high_pc_attribute (const char *asm_high_label)
const char *asm_high_label;
{ {
ASM_OUTPUT_DWARF_ATTRIBUTE (asm_out_file, AT_high_pc); ASM_OUTPUT_DWARF_ATTRIBUTE (asm_out_file, AT_high_pc);
ASM_OUTPUT_DWARF_ADDR (asm_out_file, asm_high_label); ASM_OUTPUT_DWARF_ADDR (asm_out_file, asm_high_label);
...@@ -3263,8 +3201,7 @@ high_pc_attribute (asm_high_label) ...@@ -3263,8 +3201,7 @@ high_pc_attribute (asm_high_label)
/* Generate an AT_body_begin attribute for a subroutine DIE. */ /* Generate an AT_body_begin attribute for a subroutine DIE. */
static inline void static inline void
body_begin_attribute (asm_begin_label) body_begin_attribute (const char *asm_begin_label)
const char *asm_begin_label;
{ {
ASM_OUTPUT_DWARF_ATTRIBUTE (asm_out_file, AT_body_begin); ASM_OUTPUT_DWARF_ATTRIBUTE (asm_out_file, AT_body_begin);
ASM_OUTPUT_DWARF_ADDR (asm_out_file, asm_begin_label); ASM_OUTPUT_DWARF_ADDR (asm_out_file, asm_begin_label);
...@@ -3273,8 +3210,7 @@ body_begin_attribute (asm_begin_label) ...@@ -3273,8 +3210,7 @@ body_begin_attribute (asm_begin_label)
/* Generate an AT_body_end attribute for a subroutine DIE. */ /* Generate an AT_body_end attribute for a subroutine DIE. */
static inline void static inline void
body_end_attribute (asm_end_label) body_end_attribute (const char *asm_end_label)
const char *asm_end_label;
{ {
ASM_OUTPUT_DWARF_ATTRIBUTE (asm_out_file, AT_body_end); ASM_OUTPUT_DWARF_ATTRIBUTE (asm_out_file, AT_body_end);
ASM_OUTPUT_DWARF_ADDR (asm_out_file, asm_end_label); ASM_OUTPUT_DWARF_ADDR (asm_out_file, asm_end_label);
...@@ -3284,16 +3220,14 @@ body_end_attribute (asm_end_label) ...@@ -3284,16 +3220,14 @@ body_end_attribute (asm_end_label)
are used only within TAG_compile_unit DIEs. */ are used only within TAG_compile_unit DIEs. */
static inline void static inline void
language_attribute (language_code) language_attribute (unsigned int language_code)
unsigned language_code;
{ {
ASM_OUTPUT_DWARF_ATTRIBUTE (asm_out_file, AT_language); ASM_OUTPUT_DWARF_ATTRIBUTE (asm_out_file, AT_language);
ASM_OUTPUT_DWARF_DATA4 (asm_out_file, language_code); ASM_OUTPUT_DWARF_DATA4 (asm_out_file, language_code);
} }
static inline void static inline void
member_attribute (context) member_attribute (tree context)
tree context;
{ {
char label[MAX_ARTIFICIAL_LABEL_BYTES]; char label[MAX_ARTIFICIAL_LABEL_BYTES];
...@@ -3316,8 +3250,7 @@ member_attribute (context) ...@@ -3316,8 +3250,7 @@ member_attribute (context)
#endif #endif
static inline void static inline void
string_length_attribute (upper_bound) string_length_attribute (tree upper_bound)
tree upper_bound;
{ {
char begin_label[MAX_ARTIFICIAL_LABEL_BYTES]; char begin_label[MAX_ARTIFICIAL_LABEL_BYTES];
char end_label[MAX_ARTIFICIAL_LABEL_BYTES]; char end_label[MAX_ARTIFICIAL_LABEL_BYTES];
...@@ -3333,16 +3266,14 @@ string_length_attribute (upper_bound) ...@@ -3333,16 +3266,14 @@ string_length_attribute (upper_bound)
#endif #endif
static inline void static inline void
comp_dir_attribute (dirname) comp_dir_attribute (const char *dirname)
const char *dirname;
{ {
ASM_OUTPUT_DWARF_ATTRIBUTE (asm_out_file, AT_comp_dir); ASM_OUTPUT_DWARF_ATTRIBUTE (asm_out_file, AT_comp_dir);
ASM_OUTPUT_DWARF_STRING_NEWLINE (asm_out_file, dirname); ASM_OUTPUT_DWARF_STRING_NEWLINE (asm_out_file, dirname);
} }
static inline void static inline void
sf_names_attribute (sf_names_start_label) sf_names_attribute (const char *sf_names_start_label)
const char *sf_names_start_label;
{ {
ASM_OUTPUT_DWARF_ATTRIBUTE (asm_out_file, AT_sf_names); ASM_OUTPUT_DWARF_ATTRIBUTE (asm_out_file, AT_sf_names);
/* Don't use ASM_OUTPUT_DWARF_DATA4 here. */ /* Don't use ASM_OUTPUT_DWARF_DATA4 here. */
...@@ -3350,8 +3281,7 @@ sf_names_attribute (sf_names_start_label) ...@@ -3350,8 +3281,7 @@ sf_names_attribute (sf_names_start_label)
} }
static inline void static inline void
src_info_attribute (src_info_start_label) src_info_attribute (const char *src_info_start_label)
const char *src_info_start_label;
{ {
ASM_OUTPUT_DWARF_ATTRIBUTE (asm_out_file, AT_src_info); ASM_OUTPUT_DWARF_ATTRIBUTE (asm_out_file, AT_src_info);
/* Don't use ASM_OUTPUT_DWARF_DATA4 here. */ /* Don't use ASM_OUTPUT_DWARF_DATA4 here. */
...@@ -3359,8 +3289,7 @@ src_info_attribute (src_info_start_label) ...@@ -3359,8 +3289,7 @@ src_info_attribute (src_info_start_label)
} }
static inline void static inline void
mac_info_attribute (mac_info_start_label) mac_info_attribute (const char *mac_info_start_label)
const char *mac_info_start_label;
{ {
ASM_OUTPUT_DWARF_ATTRIBUTE (asm_out_file, AT_mac_info); ASM_OUTPUT_DWARF_ATTRIBUTE (asm_out_file, AT_mac_info);
/* Don't use ASM_OUTPUT_DWARF_DATA4 here. */ /* Don't use ASM_OUTPUT_DWARF_DATA4 here. */
...@@ -3368,8 +3297,7 @@ mac_info_attribute (mac_info_start_label) ...@@ -3368,8 +3297,7 @@ mac_info_attribute (mac_info_start_label)
} }
static inline void static inline void
prototyped_attribute (func_type) prototyped_attribute (tree func_type)
tree func_type;
{ {
if ((strcmp (lang_hooks.name, "GNU C") == 0) if ((strcmp (lang_hooks.name, "GNU C") == 0)
&& (TYPE_ARG_TYPES (func_type) != NULL)) && (TYPE_ARG_TYPES (func_type) != NULL))
...@@ -3380,16 +3308,14 @@ prototyped_attribute (func_type) ...@@ -3380,16 +3308,14 @@ prototyped_attribute (func_type)
} }
static inline void static inline void
producer_attribute (producer) producer_attribute (const char *producer)
const char *producer;
{ {
ASM_OUTPUT_DWARF_ATTRIBUTE (asm_out_file, AT_producer); ASM_OUTPUT_DWARF_ATTRIBUTE (asm_out_file, AT_producer);
ASM_OUTPUT_DWARF_STRING_NEWLINE (asm_out_file, producer); ASM_OUTPUT_DWARF_STRING_NEWLINE (asm_out_file, producer);
} }
static inline void static inline void
inline_attribute (decl) inline_attribute (tree decl)
tree decl;
{ {
if (DECL_INLINE (decl)) if (DECL_INLINE (decl))
{ {
...@@ -3399,8 +3325,7 @@ inline_attribute (decl) ...@@ -3399,8 +3325,7 @@ inline_attribute (decl)
} }
static inline void static inline void
containing_type_attribute (containing_type) containing_type_attribute (tree containing_type)
tree containing_type;
{ {
char label[MAX_ARTIFICIAL_LABEL_BYTES]; char label[MAX_ARTIFICIAL_LABEL_BYTES];
...@@ -3410,8 +3335,7 @@ containing_type_attribute (containing_type) ...@@ -3410,8 +3335,7 @@ containing_type_attribute (containing_type)
} }
static inline void static inline void
abstract_origin_attribute (origin) abstract_origin_attribute (tree origin)
tree origin;
{ {
char label[MAX_ARTIFICIAL_LABEL_BYTES]; char label[MAX_ARTIFICIAL_LABEL_BYTES];
...@@ -3435,9 +3359,7 @@ abstract_origin_attribute (origin) ...@@ -3435,9 +3359,7 @@ abstract_origin_attribute (origin)
#ifdef DWARF_DECL_COORDINATES #ifdef DWARF_DECL_COORDINATES
static inline void static inline void
src_coords_attribute (src_fileno, src_lineno) src_coords_attribute (unsigned src_fileno, unsigned src_lineno)
unsigned src_fileno;
unsigned src_lineno;
{ {
ASM_OUTPUT_DWARF_ATTRIBUTE (asm_out_file, AT_src_coords); ASM_OUTPUT_DWARF_ATTRIBUTE (asm_out_file, AT_src_coords);
ASM_OUTPUT_DWARF_DATA2 (asm_out_file, src_fileno); ASM_OUTPUT_DWARF_DATA2 (asm_out_file, src_fileno);
...@@ -3446,8 +3368,7 @@ src_coords_attribute (src_fileno, src_lineno) ...@@ -3446,8 +3368,7 @@ src_coords_attribute (src_fileno, src_lineno)
#endif /* defined(DWARF_DECL_COORDINATES) */ #endif /* defined(DWARF_DECL_COORDINATES) */
static inline void static inline void
pure_or_virtual_attribute (func_decl) pure_or_virtual_attribute (tree func_decl)
tree func_decl;
{ {
if (DECL_VIRTUAL_P (func_decl)) if (DECL_VIRTUAL_P (func_decl))
{ {
...@@ -3469,8 +3390,7 @@ pure_or_virtual_attribute (func_decl) ...@@ -3469,8 +3390,7 @@ pure_or_virtual_attribute (func_decl)
given decl, but only if it actually has a name. */ given decl, but only if it actually has a name. */
static void static void
name_and_src_coords_attributes (decl) name_and_src_coords_attributes (tree decl)
tree decl;
{ {
tree decl_name = DECL_NAME (decl); tree decl_name = DECL_NAME (decl);
...@@ -3505,10 +3425,7 @@ name_and_src_coords_attributes (decl) ...@@ -3505,10 +3425,7 @@ name_and_src_coords_attributes (decl)
routine writes out these "type descriptor" parts. */ routine writes out these "type descriptor" parts. */
static void static void
type_attribute (type, decl_const, decl_volatile) type_attribute (tree type, int decl_const, int decl_volatile)
tree type;
int decl_const;
int decl_volatile;
{ {
enum tree_code code = TREE_CODE (type); enum tree_code code = TREE_CODE (type);
int root_type_modified; int root_type_modified;
...@@ -3563,8 +3480,7 @@ type_attribute (type, decl_const, decl_volatile) ...@@ -3563,8 +3480,7 @@ type_attribute (type, decl_const, decl_volatile)
type was declared without a tag. */ type was declared without a tag. */
static const char * static const char *
type_tag (type) type_tag (tree type)
tree type;
{ {
const char *name = 0; const char *name = 0;
...@@ -3592,7 +3508,7 @@ type_tag (type) ...@@ -3592,7 +3508,7 @@ type_tag (type)
} }
static inline void static inline void
dienum_push () dienum_push (void)
{ {
/* Start by checking if the pending_sibling_stack needs to be expanded. /* Start by checking if the pending_sibling_stack needs to be expanded.
If necessary, expand it. */ If necessary, expand it. */
...@@ -3613,14 +3529,13 @@ dienum_push () ...@@ -3613,14 +3529,13 @@ dienum_push ()
NEXT_DIE_NUM. */ NEXT_DIE_NUM. */
static inline void static inline void
dienum_pop () dienum_pop (void)
{ {
pending_siblings--; pending_siblings--;
} }
static inline tree static inline tree
member_declared_type (member) member_declared_type (tree member)
tree member;
{ {
return (DECL_BIT_FIELD_TYPE (member)) return (DECL_BIT_FIELD_TYPE (member))
? DECL_BIT_FIELD_TYPE (member) ? DECL_BIT_FIELD_TYPE (member)
...@@ -3632,8 +3547,7 @@ member_declared_type (member) ...@@ -3632,8 +3547,7 @@ member_declared_type (member)
in the source file. */ in the source file. */
static const char * static const char *
function_start_label (decl) function_start_label (tree decl)
tree decl;
{ {
rtx x; rtx x;
const char *fnname; const char *fnname;
...@@ -3656,8 +3570,7 @@ function_start_label (decl) ...@@ -3656,8 +3570,7 @@ function_start_label (decl)
/* Note that every type of DIE (except a null DIE) gets a sibling. */ /* Note that every type of DIE (except a null DIE) gets a sibling. */
static void static void
output_array_type_die (arg) output_array_type_die (void *arg)
void *arg;
{ {
tree type = arg; tree type = arg;
...@@ -3683,8 +3596,7 @@ output_array_type_die (arg) ...@@ -3683,8 +3596,7 @@ output_array_type_die (arg)
} }
static void static void
output_set_type_die (arg) output_set_type_die (void *arg)
void *arg;
{ {
tree type = arg; tree type = arg;
...@@ -3699,8 +3611,7 @@ output_set_type_die (arg) ...@@ -3699,8 +3611,7 @@ output_set_type_die (arg)
/* Implement this when there is a GNU FORTRAN or GNU Ada front end. */ /* Implement this when there is a GNU FORTRAN or GNU Ada front end. */
static void static void
output_entry_point_die (arg) output_entry_point_die (void *arg)
void *arg;
{ {
tree decl = arg; tree decl = arg;
tree origin = decl_ultimate_origin (decl); tree origin = decl_ultimate_origin (decl);
...@@ -3726,8 +3637,7 @@ output_entry_point_die (arg) ...@@ -3726,8 +3637,7 @@ output_entry_point_die (arg)
/* Output a DIE to represent an inlined instance of an enumeration type. */ /* Output a DIE to represent an inlined instance of an enumeration type. */
static void static void
output_inlined_enumeration_type_die (arg) output_inlined_enumeration_type_die (void *arg)
void *arg;
{ {
tree type = arg; tree type = arg;
...@@ -3741,8 +3651,7 @@ output_inlined_enumeration_type_die (arg) ...@@ -3741,8 +3651,7 @@ output_inlined_enumeration_type_die (arg)
/* Output a DIE to represent an inlined instance of a structure type. */ /* Output a DIE to represent an inlined instance of a structure type. */
static void static void
output_inlined_structure_type_die (arg) output_inlined_structure_type_die (void *arg)
void *arg;
{ {
tree type = arg; tree type = arg;
...@@ -3756,8 +3665,7 @@ output_inlined_structure_type_die (arg) ...@@ -3756,8 +3665,7 @@ output_inlined_structure_type_die (arg)
/* Output a DIE to represent an inlined instance of a union type. */ /* Output a DIE to represent an inlined instance of a union type. */
static void static void
output_inlined_union_type_die (arg) output_inlined_union_type_die (void *arg)
void *arg;
{ {
tree type = arg; tree type = arg;
...@@ -3773,8 +3681,7 @@ output_inlined_union_type_die (arg) ...@@ -3773,8 +3681,7 @@ output_inlined_union_type_die (arg)
This information is encoded into the element_list attribute. */ This information is encoded into the element_list attribute. */
static void static void
output_enumeration_type_die (arg) output_enumeration_type_die (void *arg)
void *arg;
{ {
tree type = arg; tree type = arg;
...@@ -3809,8 +3716,7 @@ output_enumeration_type_die (arg) ...@@ -3809,8 +3716,7 @@ output_enumeration_type_die (arg)
formal argument type of some subprogram type. */ formal argument type of some subprogram type. */
static void static void
output_formal_parameter_die (arg) output_formal_parameter_die (void *arg)
void *arg;
{ {
tree node = arg; tree node = arg;
...@@ -3851,8 +3757,7 @@ output_formal_parameter_die (arg) ...@@ -3851,8 +3757,7 @@ output_formal_parameter_die (arg)
or block-local) which has "external linkage" (according to ANSI-C). */ or block-local) which has "external linkage" (according to ANSI-C). */
static void static void
output_global_subroutine_die (arg) output_global_subroutine_die (void *arg)
void *arg;
{ {
tree decl = arg; tree decl = arg;
tree origin = decl_ultimate_origin (decl); tree origin = decl_ultimate_origin (decl);
...@@ -3901,8 +3806,7 @@ output_global_subroutine_die (arg) ...@@ -3901,8 +3806,7 @@ output_global_subroutine_die (arg)
or block-local) which has "external linkage" (according to ANSI-C). */ or block-local) which has "external linkage" (according to ANSI-C). */
static void static void
output_global_variable_die (arg) output_global_variable_die (void *arg)
void *arg;
{ {
tree decl = arg; tree decl = arg;
tree origin = decl_ultimate_origin (decl); tree origin = decl_ultimate_origin (decl);
...@@ -3929,8 +3833,7 @@ output_global_variable_die (arg) ...@@ -3929,8 +3833,7 @@ output_global_variable_die (arg)
} }
static void static void
output_label_die (arg) output_label_die (void *arg)
void *arg;
{ {
tree decl = arg; tree decl = arg;
tree origin = decl_ultimate_origin (decl); tree origin = decl_ultimate_origin (decl);
...@@ -3972,8 +3875,7 @@ output_label_die (arg) ...@@ -3972,8 +3875,7 @@ output_label_die (arg)
} }
static void static void
output_lexical_block_die (arg) output_lexical_block_die (void *arg)
void *arg;
{ {
tree stmt = arg; tree stmt = arg;
...@@ -3993,8 +3895,7 @@ output_lexical_block_die (arg) ...@@ -3993,8 +3895,7 @@ output_lexical_block_die (arg)
} }
static void static void
output_inlined_subroutine_die (arg) output_inlined_subroutine_die (void *arg)
void *arg;
{ {
tree stmt = arg; tree stmt = arg;
...@@ -4018,8 +3919,7 @@ output_inlined_subroutine_die (arg) ...@@ -4018,8 +3919,7 @@ output_inlined_subroutine_die (arg)
or block-local) which has "internal linkage" (according to ANSI-C). */ or block-local) which has "internal linkage" (according to ANSI-C). */
static void static void
output_local_variable_die (arg) output_local_variable_die (void *arg)
void *arg;
{ {
tree decl = arg; tree decl = arg;
tree origin = decl_ultimate_origin (decl); tree origin = decl_ultimate_origin (decl);
...@@ -4042,8 +3942,7 @@ output_local_variable_die (arg) ...@@ -4042,8 +3942,7 @@ output_local_variable_die (arg)
} }
static void static void
output_member_die (arg) output_member_die (void *arg)
void *arg;
{ {
tree decl = arg; tree decl = arg;
...@@ -4071,8 +3970,7 @@ output_member_die (arg) ...@@ -4071,8 +3970,7 @@ output_member_die (arg)
someday. */ someday. */
static void static void
output_pointer_type_die (arg) output_pointer_type_die (void *arg)
void *arg;
{ {
tree type = arg; tree type = arg;
...@@ -4084,8 +3982,7 @@ output_pointer_type_die (arg) ...@@ -4084,8 +3982,7 @@ output_pointer_type_die (arg)
} }
static void static void
output_reference_type_die (arg) output_reference_type_die (void *arg)
void *arg;
{ {
tree type = arg; tree type = arg;
...@@ -4098,8 +3995,7 @@ output_reference_type_die (arg) ...@@ -4098,8 +3995,7 @@ output_reference_type_die (arg)
#endif #endif
static void static void
output_ptr_to_mbr_type_die (arg) output_ptr_to_mbr_type_die (void *arg)
void *arg;
{ {
tree type = arg; tree type = arg;
...@@ -4112,8 +4008,7 @@ output_ptr_to_mbr_type_die (arg) ...@@ -4112,8 +4008,7 @@ output_ptr_to_mbr_type_die (arg)
} }
static void static void
output_compile_unit_die (arg) output_compile_unit_die (void *arg)
void *arg;
{ {
const char *main_input_filename = arg; const char *main_input_filename = arg;
const char *language_string = lang_hooks.name; const char *language_string = lang_hooks.name;
...@@ -4163,8 +4058,7 @@ output_compile_unit_die (arg) ...@@ -4163,8 +4058,7 @@ output_compile_unit_die (arg)
} }
static void static void
output_string_type_die (arg) output_string_type_die (void *arg)
void *arg;
{ {
tree type = arg; tree type = arg;
...@@ -4177,8 +4071,7 @@ output_string_type_die (arg) ...@@ -4177,8 +4071,7 @@ output_string_type_die (arg)
} }
static void static void
output_inheritance_die (arg) output_inheritance_die (void *arg)
void *arg;
{ {
tree binfo = ((tree *)arg)[0]; tree binfo = ((tree *)arg)[0];
tree access = ((tree *)arg)[1]; tree access = ((tree *)arg)[1];
...@@ -4205,8 +4098,7 @@ output_inheritance_die (arg) ...@@ -4205,8 +4098,7 @@ output_inheritance_die (arg)
} }
static void static void
output_structure_type_die (arg) output_structure_type_die (void *arg)
void *arg;
{ {
tree type = arg; tree type = arg;
...@@ -4233,8 +4125,7 @@ output_structure_type_die (arg) ...@@ -4233,8 +4125,7 @@ output_structure_type_die (arg)
or block-local) which has "internal linkage" (according to ANSI-C). */ or block-local) which has "internal linkage" (according to ANSI-C). */
static void static void
output_local_subroutine_die (arg) output_local_subroutine_die (void *arg)
void *arg;
{ {
tree decl = arg; tree decl = arg;
tree origin = decl_ultimate_origin (decl); tree origin = decl_ultimate_origin (decl);
...@@ -4281,8 +4172,7 @@ output_local_subroutine_die (arg) ...@@ -4281,8 +4172,7 @@ output_local_subroutine_die (arg)
} }
static void static void
output_subroutine_type_die (arg) output_subroutine_type_die (void *arg)
void *arg;
{ {
tree type = arg; tree type = arg;
tree return_type = TREE_TYPE (type); tree return_type = TREE_TYPE (type);
...@@ -4297,8 +4187,7 @@ output_subroutine_type_die (arg) ...@@ -4297,8 +4187,7 @@ output_subroutine_type_die (arg)
} }
static void static void
output_typedef_die (arg) output_typedef_die (void *arg)
void *arg;
{ {
tree decl = arg; tree decl = arg;
tree origin = decl_ultimate_origin (decl); tree origin = decl_ultimate_origin (decl);
...@@ -4319,8 +4208,7 @@ output_typedef_die (arg) ...@@ -4319,8 +4208,7 @@ output_typedef_die (arg)
} }
static void static void
output_union_type_die (arg) output_union_type_die (void *arg)
void *arg;
{ {
tree type = arg; tree type = arg;
...@@ -4347,8 +4235,7 @@ output_union_type_die (arg) ...@@ -4347,8 +4235,7 @@ output_union_type_die (arg)
at the end of an (ANSI prototyped) formal parameters list. */ at the end of an (ANSI prototyped) formal parameters list. */
static void static void
output_unspecified_parameters_die (arg) output_unspecified_parameters_die (void *arg)
void *arg;
{ {
tree decl_or_type = arg; tree decl_or_type = arg;
...@@ -4373,8 +4260,7 @@ output_unspecified_parameters_die (arg) ...@@ -4373,8 +4260,7 @@ output_unspecified_parameters_die (arg)
} }
static void static void
output_padded_null_die (arg) output_padded_null_die (void *arg ATTRIBUTE_UNUSED)
void *arg ATTRIBUTE_UNUSED;
{ {
ASM_OUTPUT_ALIGN (asm_out_file, 2); /* 2**2 == 4 */ ASM_OUTPUT_ALIGN (asm_out_file, 2); /* 2**2 == 4 */
} }
...@@ -4388,9 +4274,7 @@ output_padded_null_die (arg) ...@@ -4388,9 +4274,7 @@ output_padded_null_die (arg)
of the DIE, there must always be a terminator label for the DIE. */ of the DIE, there must always be a terminator label for the DIE. */
static void static void
output_die (die_specific_output_function, param) output_die (void (*die_specific_output_function) (void *), void *param)
void (*die_specific_output_function) PARAMS ((void *));
void *param;
{ {
char begin_label[MAX_ARTIFICIAL_LABEL_BYTES]; char begin_label[MAX_ARTIFICIAL_LABEL_BYTES];
char end_label[MAX_ARTIFICIAL_LABEL_BYTES]; char end_label[MAX_ARTIFICIAL_LABEL_BYTES];
...@@ -4420,7 +4304,7 @@ output_die (die_specific_output_function, param) ...@@ -4420,7 +4304,7 @@ output_die (die_specific_output_function, param)
} }
static void static void
end_sibling_chain () end_sibling_chain (void)
{ {
char begin_label[MAX_ARTIFICIAL_LABEL_BYTES]; char begin_label[MAX_ARTIFICIAL_LABEL_BYTES];
...@@ -4452,8 +4336,7 @@ end_sibling_chain () ...@@ -4452,8 +4336,7 @@ end_sibling_chain ()
the formal parameter list. */ the formal parameter list. */
static void static void
output_formal_types (function_or_method_type) output_formal_types (tree function_or_method_type)
tree function_or_method_type;
{ {
tree link; tree link;
tree formal_type = NULL; tree formal_type = NULL;
...@@ -4517,8 +4400,7 @@ output_formal_types (function_or_method_type) ...@@ -4517,8 +4400,7 @@ output_formal_types (function_or_method_type)
/* Remember a type in the pending_types_list. */ /* Remember a type in the pending_types_list. */
static void static void
pend_type (type) pend_type (tree type)
tree type;
{ {
if (pending_types == pending_types_allocated) if (pending_types == pending_types_allocated)
{ {
...@@ -4573,9 +4455,7 @@ pend_type (type) ...@@ -4573,9 +4455,7 @@ pend_type (type)
true scope of the types we temporarily pended. */ true scope of the types we temporarily pended. */
static inline int static inline int
type_ok_for_scope (type, scope) type_ok_for_scope (tree type, tree scope)
tree type;
tree scope;
{ {
/* Tagged types (i.e. struct, union, and enum types) must always be /* Tagged types (i.e. struct, union, and enum types) must always be
output only in the scopes where they actually belong (or else the output only in the scopes where they actually belong (or else the
...@@ -4610,8 +4490,7 @@ type_ok_for_scope (type, scope) ...@@ -4610,8 +4490,7 @@ type_ok_for_scope (type, scope)
of them too. */ of them too. */
static void static void
output_pending_types_for_scope (containing_scope) output_pending_types_for_scope (tree containing_scope)
tree containing_scope;
{ {
unsigned i; unsigned i;
...@@ -4648,8 +4527,7 @@ output_pending_types_for_scope (containing_scope) ...@@ -4648,8 +4527,7 @@ output_pending_types_for_scope (containing_scope)
/* Remember a type in the incomplete_types_list. */ /* Remember a type in the incomplete_types_list. */
static void static void
add_incomplete_type (type) add_incomplete_type (tree type)
tree type;
{ {
if (incomplete_types == incomplete_types_allocated) if (incomplete_types == incomplete_types_allocated)
{ {
...@@ -4666,7 +4544,7 @@ add_incomplete_type (type) ...@@ -4666,7 +4544,7 @@ add_incomplete_type (type)
emit full debugging info for them. */ emit full debugging info for them. */
static void static void
retry_incomplete_types () retry_incomplete_types (void)
{ {
tree type; tree type;
...@@ -4680,9 +4558,7 @@ retry_incomplete_types () ...@@ -4680,9 +4558,7 @@ retry_incomplete_types ()
} }
static void static void
output_type (type, containing_scope) output_type (tree type, tree containing_scope)
tree type;
tree containing_scope;
{ {
if (type == 0 || type == error_mark_node) if (type == 0 || type == error_mark_node)
return; return;
...@@ -4982,8 +4858,7 @@ output_type (type, containing_scope) ...@@ -4982,8 +4858,7 @@ output_type (type, containing_scope)
} }
static void static void
output_tagged_type_instantiation (type) output_tagged_type_instantiation (tree type)
tree type;
{ {
if (type == 0 || type == error_mark_node) if (type == 0 || type == error_mark_node)
return; return;
...@@ -5026,9 +4901,7 @@ output_tagged_type_instantiation (type) ...@@ -5026,9 +4901,7 @@ output_tagged_type_instantiation (type)
the things which are local to the given block. */ the things which are local to the given block. */
static void static void
output_block (stmt, depth) output_block (tree stmt, int depth)
tree stmt;
int depth;
{ {
int must_output_die = 0; int must_output_die = 0;
tree origin; tree origin;
...@@ -5120,9 +4993,7 @@ output_block (stmt, depth) ...@@ -5120,9 +4993,7 @@ output_block (stmt, depth)
a `binding contour') and (recursively) all of it's sub-blocks. */ a `binding contour') and (recursively) all of it's sub-blocks. */
static void static void
output_decls_for_scope (stmt, depth) output_decls_for_scope (tree stmt, int depth)
tree stmt;
int depth;
{ {
/* Ignore blocks never really used to make RTL. */ /* Ignore blocks never really used to make RTL. */
...@@ -5158,8 +5029,7 @@ output_decls_for_scope (stmt, depth) ...@@ -5158,8 +5029,7 @@ output_decls_for_scope (stmt, depth)
/* Is this a typedef we can avoid emitting? */ /* Is this a typedef we can avoid emitting? */
static inline int static inline int
is_redundant_typedef (decl) is_redundant_typedef (tree decl)
tree decl;
{ {
if (TYPE_DECL_IS_STUB (decl)) if (TYPE_DECL_IS_STUB (decl))
return 1; return 1;
...@@ -5176,9 +5046,7 @@ is_redundant_typedef (decl) ...@@ -5176,9 +5046,7 @@ is_redundant_typedef (decl)
/* Output Dwarf .debug information for a decl described by DECL. */ /* Output Dwarf .debug information for a decl described by DECL. */
static void static void
output_decl (decl, containing_scope) output_decl (tree decl, tree containing_scope)
tree decl;
tree containing_scope;
{ {
/* Make a note of the decl node we are going to be working on. We may /* Make a note of the decl node we are going to be working on. We may
need to give the user the source coordinates of where it appeared in need to give the user the source coordinates of where it appeared in
...@@ -5501,7 +5369,7 @@ output_decl (decl, containing_scope) ...@@ -5501,7 +5369,7 @@ output_decl (decl, containing_scope)
function. */ function. */
{ {
void (*func) PARAMS ((void *)); void (*func) (void *);
register tree origin = decl_ultimate_origin (decl); register tree origin = decl_ultimate_origin (decl);
if (origin != NULL && TREE_CODE (origin) == PARM_DECL) if (origin != NULL && TREE_CODE (origin) == PARM_DECL)
...@@ -5547,8 +5415,7 @@ output_decl (decl, containing_scope) ...@@ -5547,8 +5415,7 @@ output_decl (decl, containing_scope)
/* Output debug information for a function. */ /* Output debug information for a function. */
static void static void
dwarfout_function_decl (decl) dwarfout_function_decl (tree decl)
tree decl;
{ {
dwarfout_file_scope_decl (decl, 0); dwarfout_file_scope_decl (decl, 0);
} }
...@@ -5556,8 +5423,7 @@ dwarfout_function_decl (decl) ...@@ -5556,8 +5423,7 @@ dwarfout_function_decl (decl)
/* Debug information for a global DECL. Called from toplev.c after /* Debug information for a global DECL. Called from toplev.c after
compilation proper has finished. */ compilation proper has finished. */
static void static void
dwarfout_global_decl (decl) dwarfout_global_decl (tree decl)
tree decl;
{ {
/* Output DWARF information for file-scope tentative data object /* Output DWARF information for file-scope tentative data object
declarations, file-scope (extern) function declarations (which declarations, file-scope (extern) function declarations (which
...@@ -5572,8 +5438,7 @@ dwarfout_global_decl (decl) ...@@ -5572,8 +5438,7 @@ dwarfout_global_decl (decl)
being output at this point. (We're putting that off until we need being output at this point. (We're putting that off until we need
to do it.) */ to do it.) */
static void static void
dwarfout_deferred_inline_function (decl) dwarfout_deferred_inline_function (tree decl)
tree decl;
{ {
/* Generate the DWARF info for the "abstract" instance of a function /* Generate the DWARF info for the "abstract" instance of a function
which we may later generate inlined and/or out-of-line instances which we may later generate inlined and/or out-of-line instances
...@@ -5601,9 +5466,7 @@ dwarfout_deferred_inline_function (decl) ...@@ -5601,9 +5466,7 @@ dwarfout_deferred_inline_function (decl)
} }
static void static void
dwarfout_file_scope_decl (decl, set_finalizing) dwarfout_file_scope_decl (tree decl, int set_finalizing)
tree decl;
int set_finalizing;
{ {
if (TREE_CODE (decl) == ERROR_MARK) if (TREE_CODE (decl) == ERROR_MARK)
return; return;
...@@ -5814,9 +5677,8 @@ dwarfout_file_scope_decl (decl, set_finalizing) ...@@ -5814,9 +5677,8 @@ dwarfout_file_scope_decl (decl, set_finalizing)
for a lexical block. */ for a lexical block. */
static void static void
dwarfout_begin_block (line, blocknum) dwarfout_begin_block (unsigned int line ATTRIBUTE_UNUSED,
unsigned int line ATTRIBUTE_UNUSED; unsigned int blocknum)
unsigned int blocknum;
{ {
char label[MAX_ARTIFICIAL_LABEL_BYTES]; char label[MAX_ARTIFICIAL_LABEL_BYTES];
...@@ -5829,9 +5691,7 @@ dwarfout_begin_block (line, blocknum) ...@@ -5829,9 +5691,7 @@ dwarfout_begin_block (line, blocknum)
for a lexical block. */ for a lexical block. */
static void static void
dwarfout_end_block (line, blocknum) dwarfout_end_block (unsigned int line ATTRIBUTE_UNUSED, unsigned int blocknum)
unsigned int line ATTRIBUTE_UNUSED;
unsigned int blocknum;
{ {
char label[MAX_ARTIFICIAL_LABEL_BYTES]; char label[MAX_ARTIFICIAL_LABEL_BYTES];
...@@ -5845,9 +5705,8 @@ dwarfout_end_block (line, blocknum) ...@@ -5845,9 +5705,8 @@ dwarfout_end_block (line, blocknum)
to their home locations). */ to their home locations). */
static void static void
dwarfout_end_prologue (line, file) dwarfout_end_prologue (unsigned int line ATTRIBUTE_UNUSED,
unsigned int line ATTRIBUTE_UNUSED; const char *file ATTRIBUTE_UNUSED)
const char *file ATTRIBUTE_UNUSED;
{ {
char label[MAX_ARTIFICIAL_LABEL_BYTES]; char label[MAX_ARTIFICIAL_LABEL_BYTES];
...@@ -5863,8 +5722,7 @@ dwarfout_end_prologue (line, file) ...@@ -5863,8 +5722,7 @@ dwarfout_end_prologue (line, file)
the real body of the function ends (just before the epilogue code). */ the real body of the function ends (just before the epilogue code). */
static void static void
dwarfout_end_function (line) dwarfout_end_function (unsigned int line ATTRIBUTE_UNUSED)
unsigned int line ATTRIBUTE_UNUSED;
{ {
char label[MAX_ARTIFICIAL_LABEL_BYTES]; char label[MAX_ARTIFICIAL_LABEL_BYTES];
...@@ -5880,9 +5738,8 @@ dwarfout_end_function (line) ...@@ -5880,9 +5738,8 @@ dwarfout_end_function (line)
has been generated. */ has been generated. */
static void static void
dwarfout_end_epilogue (line, file) dwarfout_end_epilogue (unsigned int line ATTRIBUTE_UNUSED,
unsigned int line ATTRIBUTE_UNUSED; const char *file ATTRIBUTE_UNUSED)
const char *file ATTRIBUTE_UNUSED;
{ {
char label[MAX_ARTIFICIAL_LABEL_BYTES]; char label[MAX_ARTIFICIAL_LABEL_BYTES];
...@@ -5894,8 +5751,7 @@ dwarfout_end_epilogue (line, file) ...@@ -5894,8 +5751,7 @@ dwarfout_end_epilogue (line, file)
} }
static void static void
shuffle_filename_entry (new_zeroth) shuffle_filename_entry (filename_entry *new_zeroth)
filename_entry *new_zeroth;
{ {
filename_entry temp_entry; filename_entry temp_entry;
filename_entry *limit_p; filename_entry *limit_p;
...@@ -5920,7 +5776,7 @@ shuffle_filename_entry (new_zeroth) ...@@ -5920,7 +5776,7 @@ shuffle_filename_entry (new_zeroth)
/* Create a new (string) entry for the .debug_sfnames section. */ /* Create a new (string) entry for the .debug_sfnames section. */
static void static void
generate_new_sfname_entry () generate_new_sfname_entry (void)
{ {
char label[MAX_ARTIFICIAL_LABEL_BYTES]; char label[MAX_ARTIFICIAL_LABEL_BYTES];
...@@ -5967,8 +5823,7 @@ generate_new_sfname_entry () ...@@ -5967,8 +5823,7 @@ generate_new_sfname_entry ()
before them.) */ before them.) */
static unsigned static unsigned
lookup_filename (file_name) lookup_filename (const char *file_name)
const char *file_name;
{ {
filename_entry *search_p; filename_entry *search_p;
filename_entry *limit_p = &filename_table[ft_entries]; filename_entry *limit_p = &filename_table[ft_entries];
...@@ -6018,9 +5873,7 @@ lookup_filename (file_name) ...@@ -6018,9 +5873,7 @@ lookup_filename (file_name)
} }
static void static void
generate_srcinfo_entry (line_entry_num, files_entry_num) generate_srcinfo_entry (unsigned int line_entry_num, unsigned int files_entry_num)
unsigned line_entry_num;
unsigned files_entry_num;
{ {
char label[MAX_ARTIFICIAL_LABEL_BYTES]; char label[MAX_ARTIFICIAL_LABEL_BYTES];
...@@ -6034,9 +5887,7 @@ generate_srcinfo_entry (line_entry_num, files_entry_num) ...@@ -6034,9 +5887,7 @@ generate_srcinfo_entry (line_entry_num, files_entry_num)
} }
static void static void
dwarfout_source_line (line, filename) dwarfout_source_line (unsigned int line, const char *filename)
unsigned int line;
const char *filename;
{ {
if (debug_info_level >= DINFO_LEVEL_NORMAL if (debug_info_level >= DINFO_LEVEL_NORMAL
/* We can't emit line number info for functions in separate sections, /* We can't emit line number info for functions in separate sections,
...@@ -6089,10 +5940,7 @@ dwarfout_source_line (line, filename) ...@@ -6089,10 +5940,7 @@ dwarfout_source_line (line, filename)
/* Generate an entry in the .debug_macinfo section. */ /* Generate an entry in the .debug_macinfo section. */
static void static void
generate_macinfo_entry (type, offset, string) generate_macinfo_entry (unsigned int type, rtx offset, const char *string)
unsigned int type;
rtx offset;
const char *string;
{ {
if (! use_gnu_debug_info_extensions) if (! use_gnu_debug_info_extensions)
return; return;
...@@ -6107,18 +5955,15 @@ generate_macinfo_entry (type, offset, string) ...@@ -6107,18 +5955,15 @@ generate_macinfo_entry (type, offset, string)
/* Wrapper for toplev.c callback to check debug info level. */ /* Wrapper for toplev.c callback to check debug info level. */
static void static void
dwarfout_start_source_file_check (line, filename) dwarfout_start_source_file_check (unsigned int line, const char *filename)
unsigned int line;
const char *filename;
{ {
if (debug_info_level == DINFO_LEVEL_VERBOSE) if (debug_info_level == DINFO_LEVEL_VERBOSE)
dwarfout_start_source_file (line, filename); dwarfout_start_source_file (line, filename);
} }
static void static void
dwarfout_start_source_file (line, filename) dwarfout_start_source_file (unsigned int line ATTRIBUTE_UNUSED,
unsigned int line ATTRIBUTE_UNUSED; const char *filename)
const char *filename;
{ {
char label[MAX_ARTIFICIAL_LABEL_BYTES]; char label[MAX_ARTIFICIAL_LABEL_BYTES];
const char *label1, *label2; const char *label1, *label2;
...@@ -6135,16 +5980,14 @@ dwarfout_start_source_file (line, filename) ...@@ -6135,16 +5980,14 @@ dwarfout_start_source_file (line, filename)
/* Wrapper for toplev.c callback to check debug info level. */ /* Wrapper for toplev.c callback to check debug info level. */
static void static void
dwarfout_end_source_file_check (lineno) dwarfout_end_source_file_check (unsigned int lineno)
unsigned lineno;
{ {
if (debug_info_level == DINFO_LEVEL_VERBOSE) if (debug_info_level == DINFO_LEVEL_VERBOSE)
dwarfout_end_source_file (lineno); dwarfout_end_source_file (lineno);
} }
static void static void
dwarfout_end_source_file (lineno) dwarfout_end_source_file (unsigned int lineno)
unsigned lineno;
{ {
generate_macinfo_entry (MACINFO_resume, GEN_INT (lineno), ""); generate_macinfo_entry (MACINFO_resume, GEN_INT (lineno), "");
} }
...@@ -6155,9 +5998,7 @@ dwarfout_end_source_file (lineno) ...@@ -6155,9 +5998,7 @@ dwarfout_end_source_file (lineno)
whitespace part. */ whitespace part. */
static void static void
dwarfout_define (lineno, buffer) dwarfout_define (unsigned int lineno, const char *buffer)
unsigned lineno;
const char *buffer;
{ {
static int initialized = 0; static int initialized = 0;
...@@ -6175,9 +6016,7 @@ dwarfout_define (lineno, buffer) ...@@ -6175,9 +6016,7 @@ dwarfout_define (lineno, buffer)
whitespace part. */ whitespace part. */
static void static void
dwarfout_undef (lineno, buffer) dwarfout_undef (unsigned int lineno, const char *buffer)
unsigned lineno;
const char *buffer;
{ {
generate_macinfo_entry (MACINFO_undef, GEN_INT (lineno), buffer); generate_macinfo_entry (MACINFO_undef, GEN_INT (lineno), buffer);
} }
...@@ -6185,8 +6024,7 @@ dwarfout_undef (lineno, buffer) ...@@ -6185,8 +6024,7 @@ dwarfout_undef (lineno, buffer)
/* Set up for Dwarf output at the start of compilation. */ /* Set up for Dwarf output at the start of compilation. */
static void static void
dwarfout_init (main_input_filename) dwarfout_init (const char *main_input_filename)
const char *main_input_filename;
{ {
warning ("support for the DWARF1 debugging format is deprecated"); warning ("support for the DWARF1 debugging format is deprecated");
...@@ -6376,8 +6214,7 @@ dwarfout_init (main_input_filename) ...@@ -6376,8 +6214,7 @@ dwarfout_init (main_input_filename)
/* Output stuff that dwarf requires at the end of every file. */ /* Output stuff that dwarf requires at the end of every file. */
static void static void
dwarfout_finish (main_input_filename) dwarfout_finish (const char *main_input_filename ATTRIBUTE_UNUSED)
const char *main_input_filename ATTRIBUTE_UNUSED;
{ {
char label[MAX_ARTIFICIAL_LABEL_BYTES]; char label[MAX_ARTIFICIAL_LABEL_BYTES];
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment