summaryrefslogtreecommitdiff
path: root/gcc/except.c
diff options
context:
space:
mode:
authorAndreas Jaeger <aj@suse.de>2003-06-29 18:21:58 +0200
committerAndreas Jaeger <aj@gcc.gnu.org>2003-06-29 18:21:58 +0200
commit502b832280c67d89300d92b91e73a9d3093db4a8 (patch)
treed12a59c660881801d6279dba52e7bd166ec393fb /gcc/except.c
parent7080f7359418d87feb8ec8dfacf327d32b5a070c (diff)
downloadgcc-502b832280c67d89300d92b91e73a9d3093db4a8.tar.gz
except.c: Convert prototypes to ISO C90.
* except.c: Convert prototypes to ISO C90. * except.h: Likewise. * emit-rtl.c: Likewise. * et-forest.c: Likewise. * et-forest.h: Likewise. * except.c: Likewise. * explow.c: Likewise. * expmed.c: Likewise. * expr.c: Likewise. * expr.h: Likewise. From-SVN: r68674
Diffstat (limited to 'gcc/except.c')
-rw-r--r--gcc/except.c411
1 files changed, 158 insertions, 253 deletions
diff --git a/gcc/except.c b/gcc/except.c
index 39e72dfa70d..63a35702b91 100644
--- a/gcc/except.c
+++ b/gcc/except.c
@@ -1,6 +1,6 @@
/* Implements exception handling.
Copyright (C) 1989, 1992, 1993, 1994, 1995, 1996, 1997, 1998,
- 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
+ 1999, 2000, 2001, 2002, 2003 Free Software Foundation, Inc.
Contributed by Mike Stump <mrs@cygnus.com>.
This file is part of GCC.
@@ -86,13 +86,13 @@ int flag_non_call_exceptions;
/* Protect cleanup actions with must-not-throw regions, with a call
to the given failure handler. */
-tree (*lang_protect_cleanup_actions) PARAMS ((void));
+tree (*lang_protect_cleanup_actions) (void);
/* Return true if type A catches type B. */
-int (*lang_eh_type_covers) PARAMS ((tree a, tree b));
+int (*lang_eh_type_covers) (tree a, tree b);
/* Map a type to a runtime object to match type. */
-tree (*lang_eh_runtime_type) PARAMS ((tree));
+tree (*lang_eh_runtime_type) (tree);
/* A hash table of label to region number. */
@@ -241,7 +241,7 @@ struct eh_status GTY(())
htab_t GTY ((param_is (struct ehl_map_entry))) exception_handler_label_map;
- struct call_site_record * GTY ((length ("%h.call_site_data_used")))
+ struct call_site_record * GTY ((length ("%h.call_site_data_used")))
call_site_data;
int call_site_data_used;
int call_site_data_size;
@@ -255,61 +255,50 @@ struct eh_status GTY(())
};
-static int t2r_eq PARAMS ((const void *,
- const void *));
-static hashval_t t2r_hash PARAMS ((const void *));
-static void add_type_for_runtime PARAMS ((tree));
-static tree lookup_type_for_runtime PARAMS ((tree));
-
-static struct eh_region *expand_eh_region_end PARAMS ((void));
-
-static rtx get_exception_filter PARAMS ((struct function *));
-
-static void collect_eh_region_array PARAMS ((void));
-static void resolve_fixup_regions PARAMS ((void));
-static void remove_fixup_regions PARAMS ((void));
-static void remove_unreachable_regions PARAMS ((rtx));
-static void convert_from_eh_region_ranges_1 PARAMS ((rtx *, int *, int));
-
-static struct eh_region *duplicate_eh_region_1 PARAMS ((struct eh_region *,
- struct inline_remap *));
-static void duplicate_eh_region_2 PARAMS ((struct eh_region *,
- struct eh_region **));
-static int ttypes_filter_eq PARAMS ((const void *,
- const void *));
-static hashval_t ttypes_filter_hash PARAMS ((const void *));
-static int ehspec_filter_eq PARAMS ((const void *,
- const void *));
-static hashval_t ehspec_filter_hash PARAMS ((const void *));
-static int add_ttypes_entry PARAMS ((htab_t, tree));
-static int add_ehspec_entry PARAMS ((htab_t, htab_t,
- tree));
-static void assign_filter_values PARAMS ((void));
-static void build_post_landing_pads PARAMS ((void));
-static void connect_post_landing_pads PARAMS ((void));
-static void dw2_build_landing_pads PARAMS ((void));
+static int t2r_eq (const void *, const void *);
+static hashval_t t2r_hash (const void *);
+static void add_type_for_runtime (tree);
+static tree lookup_type_for_runtime (tree);
+
+static struct eh_region *expand_eh_region_end (void);
+
+static rtx get_exception_filter (struct function *);
+
+static void collect_eh_region_array (void);
+static void resolve_fixup_regions (void);
+static void remove_fixup_regions (void);
+static void remove_unreachable_regions (rtx);
+static void convert_from_eh_region_ranges_1 (rtx *, int *, int);
+
+static struct eh_region *duplicate_eh_region_1 (struct eh_region *,
+ struct inline_remap *);
+static void duplicate_eh_region_2 (struct eh_region *, struct eh_region **);
+static int ttypes_filter_eq (const void *, const void *);
+static hashval_t ttypes_filter_hash (const void *);
+static int ehspec_filter_eq (const void *, const void *);
+static hashval_t ehspec_filter_hash (const void *);
+static int add_ttypes_entry (htab_t, tree);
+static int add_ehspec_entry (htab_t, htab_t, tree);
+static void assign_filter_values (void);
+static void build_post_landing_pads (void);
+static void connect_post_landing_pads (void);
+static void dw2_build_landing_pads (void);
struct sjlj_lp_info;
-static bool sjlj_find_directly_reachable_regions
- PARAMS ((struct sjlj_lp_info *));
-static void sjlj_assign_call_site_values
- PARAMS ((rtx, struct sjlj_lp_info *));
-static void sjlj_mark_call_sites
- PARAMS ((struct sjlj_lp_info *));
-static void sjlj_emit_function_enter PARAMS ((rtx));
-static void sjlj_emit_function_exit PARAMS ((void));
-static void sjlj_emit_dispatch_table
- PARAMS ((rtx, struct sjlj_lp_info *));
-static void sjlj_build_landing_pads PARAMS ((void));
-
-static hashval_t ehl_hash PARAMS ((const void *));
-static int ehl_eq PARAMS ((const void *,
- const void *));
-static void add_ehl_entry PARAMS ((rtx,
- struct eh_region *));
-static void remove_exception_handler_label PARAMS ((rtx));
-static void remove_eh_handler PARAMS ((struct eh_region *));
-static int for_each_eh_label_1 PARAMS ((void **, void *));
+static bool sjlj_find_directly_reachable_regions (struct sjlj_lp_info *);
+static void sjlj_assign_call_site_values (rtx, struct sjlj_lp_info *);
+static void sjlj_mark_call_sites (struct sjlj_lp_info *);
+static void sjlj_emit_function_enter (rtx);
+static void sjlj_emit_function_exit (void);
+static void sjlj_emit_dispatch_table (rtx, struct sjlj_lp_info *);
+static void sjlj_build_landing_pads (void);
+
+static hashval_t ehl_hash (const void *);
+static int ehl_eq (const void *, const void *);
+static void add_ehl_entry (rtx, struct eh_region *);
+static void remove_exception_handler_label (rtx);
+static void remove_eh_handler (struct eh_region *);
+static int for_each_eh_label_1 (void **, void *);
struct reachable_info;
@@ -326,30 +315,26 @@ enum reachable_code
RNL_BLOCKED
};
-static int check_handled PARAMS ((tree, tree));
-static void add_reachable_handler
- PARAMS ((struct reachable_info *, struct eh_region *,
- struct eh_region *));
-static enum reachable_code reachable_next_level
- PARAMS ((struct eh_region *, tree, struct reachable_info *));
-
-static int action_record_eq PARAMS ((const void *,
- const void *));
-static hashval_t action_record_hash PARAMS ((const void *));
-static int add_action_record PARAMS ((htab_t, int, int));
-static int collect_one_action_chain PARAMS ((htab_t,
- struct eh_region *));
-static int add_call_site PARAMS ((rtx, int));
-
-static void push_uleb128 PARAMS ((varray_type *,
- unsigned int));
-static void push_sleb128 PARAMS ((varray_type *, int));
+static int check_handled (tree, tree);
+static void add_reachable_handler (struct reachable_info *,
+ struct eh_region *, struct eh_region *);
+static enum reachable_code reachable_next_level (struct eh_region *, tree,
+ struct reachable_info *);
+
+static int action_record_eq (const void *, const void *);
+static hashval_t action_record_hash (const void *);
+static int add_action_record (htab_t, int, int);
+static int collect_one_action_chain (htab_t, struct eh_region *);
+static int add_call_site (rtx, int);
+
+static void push_uleb128 (varray_type *, unsigned int);
+static void push_sleb128 (varray_type *, int);
#ifndef HAVE_AS_LEB128
-static int dw2_size_of_call_site_table PARAMS ((void));
-static int sjlj_size_of_call_site_table PARAMS ((void));
+static int dw2_size_of_call_site_table (void);
+static int sjlj_size_of_call_site_table (void);
#endif
-static void dw2_output_call_site_table PARAMS ((void));
-static void sjlj_output_call_site_table PARAMS ((void));
+static void dw2_output_call_site_table (void);
+static void sjlj_output_call_site_table (void);
/* Routine to see if exception handling is turned on.
@@ -360,8 +345,7 @@ static void sjlj_output_call_site_table PARAMS ((void));
compiler tries to use any exception-specific functions. */
int
-doing_eh (do_warn)
- int do_warn;
+doing_eh (int do_warn)
{
if (! flag_exceptions)
{
@@ -378,7 +362,7 @@ doing_eh (do_warn)
void
-init_eh ()
+init_eh (void)
{
if (! flag_exceptions)
return;
@@ -472,9 +456,9 @@ init_eh ()
}
void
-init_eh_for_function ()
+init_eh_for_function (void)
{
- cfun->eh = (struct eh_status *)
+ cfun->eh = (struct eh_status *)
ggc_alloc_cleared (sizeof (struct eh_status));
}
@@ -483,7 +467,7 @@ init_eh_for_function ()
expand_eh_region_end is invoked. */
void
-expand_eh_region_start ()
+expand_eh_region_start (void)
{
struct eh_region *new_region;
struct eh_region *cur_region;
@@ -517,7 +501,7 @@ expand_eh_region_start ()
/* Common code to end a region. Returns the region just ended. */
static struct eh_region *
-expand_eh_region_end ()
+expand_eh_region_end (void)
{
struct eh_region *cur_region = cfun->eh->cur_region;
rtx note;
@@ -536,8 +520,7 @@ expand_eh_region_end ()
expression to expand for the cleanup. */
void
-expand_eh_region_end_cleanup (handler)
- tree handler;
+expand_eh_region_end_cleanup (tree handler)
{
struct eh_region *region;
tree protect_cleanup_actions;
@@ -603,7 +586,7 @@ expand_eh_region_end_cleanup (handler)
for subsequent calls to expand_start_catch. */
void
-expand_start_all_catch ()
+expand_start_all_catch (void)
{
struct eh_region *region;
@@ -626,8 +609,7 @@ expand_start_all_catch ()
is useful e.g. for Ada. */
void
-expand_start_catch (type_or_list)
- tree type_or_list;
+expand_start_catch (tree type_or_list)
{
struct eh_region *t, *c, *l;
tree type_list;
@@ -674,7 +656,7 @@ expand_start_catch (type_or_list)
/* End a catch clause. Control will resume after the try/catch block. */
void
-expand_end_catch ()
+expand_end_catch (void)
{
struct eh_region *try_region;
@@ -690,7 +672,7 @@ expand_end_catch ()
/* End a sequence of catch handlers for a try block. */
void
-expand_end_all_catch ()
+expand_end_all_catch (void)
{
struct eh_region *try_region;
@@ -712,8 +694,7 @@ expand_end_all_catch ()
rethrowing satisfies the "filter" of the catch type. */
void
-expand_eh_region_end_allowed (allowed, failure)
- tree allowed, failure;
+expand_eh_region_end_allowed (tree allowed, tree failure)
{
struct eh_region *region;
rtx around_label;
@@ -755,8 +736,7 @@ expand_eh_region_end_allowed (allowed, failure)
the C++ LSDA. */
void
-expand_eh_region_end_must_not_throw (failure)
- tree failure;
+expand_eh_region_end_must_not_throw (tree failure)
{
struct eh_region *region;
rtx around_label;
@@ -786,8 +766,7 @@ expand_eh_region_end_must_not_throw (failure)
is being thrown. */
void
-expand_eh_region_end_throw (type)
- tree type;
+expand_eh_region_end_throw (tree type)
{
struct eh_region *region;
@@ -810,8 +789,7 @@ expand_eh_region_end_throw (type)
the proper notion of "enclosing" in convert_from_eh_region_ranges. */
void
-expand_eh_region_end_fixup (handler)
- tree handler;
+expand_eh_region_end_fixup (tree handler)
{
struct eh_region *fixup;
@@ -827,7 +805,7 @@ expand_eh_region_end_fixup (handler)
call to a function which itself may contain a throw. */
void
-note_eh_region_may_contain_throw ()
+note_eh_region_may_contain_throw (void)
{
struct eh_region *region;
@@ -843,8 +821,7 @@ note_eh_region_may_contain_throw ()
within a handler. */
rtx
-get_exception_pointer (fun)
- struct function *fun;
+get_exception_pointer (struct function *fun)
{
rtx exc_ptr = fun->eh->exc_ptr;
if (fun == cfun && ! exc_ptr)
@@ -859,8 +836,7 @@ get_exception_pointer (fun)
within a handler. */
static rtx
-get_exception_filter (fun)
- struct function *fun;
+get_exception_filter (struct function *fun)
{
rtx filter = fun->eh->filter;
if (fun == cfun && ! filter)
@@ -878,7 +854,7 @@ get_exception_filter (fun)
without having to realloc memory. */
static void
-collect_eh_region_array ()
+collect_eh_region_array (void)
{
struct eh_region **array, *i;
@@ -914,7 +890,7 @@ collect_eh_region_array ()
}
static void
-resolve_fixup_regions ()
+resolve_fixup_regions (void)
{
int i, j, n = cfun->eh->last_region_number;
@@ -944,7 +920,7 @@ resolve_fixup_regions ()
we can shuffle pointers and remove them from the tree. */
static void
-remove_fixup_regions ()
+remove_fixup_regions (void)
{
int i;
rtx insn, note;
@@ -1014,8 +990,7 @@ remove_fixup_regions ()
/* Remove all regions whose labels are not reachable from insns. */
static void
-remove_unreachable_regions (insns)
- rtx insns;
+remove_unreachable_regions (rtx insns)
{
int i, *uid_region_num;
bool *reachable;
@@ -1078,10 +1053,7 @@ remove_unreachable_regions (insns)
can_throw instruction in the region. */
static void
-convert_from_eh_region_ranges_1 (pinsns, orig_sp, cur)
- rtx *pinsns;
- int *orig_sp;
- int cur;
+convert_from_eh_region_ranges_1 (rtx *pinsns, int *orig_sp, int cur)
{
int *sp = orig_sp;
rtx insn, next;
@@ -1162,7 +1134,7 @@ convert_from_eh_region_ranges_1 (pinsns, orig_sp, cur)
}
void
-convert_from_eh_region_ranges ()
+convert_from_eh_region_ranges (void)
{
int *stack;
rtx insns;
@@ -1180,9 +1152,7 @@ convert_from_eh_region_ranges ()
}
static void
-add_ehl_entry (label, region)
- rtx label;
- struct eh_region *region;
+add_ehl_entry (rtx label, struct eh_region *region)
{
struct ehl_map_entry **slot, *entry;
@@ -1206,7 +1176,7 @@ add_ehl_entry (label, region)
}
void
-find_exception_handler_labels ()
+find_exception_handler_labels (void)
{
int i;
@@ -1247,7 +1217,7 @@ find_exception_handler_labels ()
}
bool
-current_function_has_exception_handlers ()
+current_function_has_exception_handlers (void)
{
int i;
@@ -1265,9 +1235,7 @@ current_function_has_exception_handlers ()
}
static struct eh_region *
-duplicate_eh_region_1 (o, map)
- struct eh_region *o;
- struct inline_remap *map;
+duplicate_eh_region_1 (struct eh_region *o, struct inline_remap *map)
{
struct eh_region *n
= (struct eh_region *) ggc_alloc_cleared (sizeof (struct eh_region));
@@ -1316,9 +1284,7 @@ duplicate_eh_region_1 (o, map)
}
static void
-duplicate_eh_region_2 (o, n_array)
- struct eh_region *o;
- struct eh_region **n_array;
+duplicate_eh_region_2 (struct eh_region *o, struct eh_region **n_array)
{
struct eh_region *n = n_array[o->region_number];
@@ -1349,9 +1315,7 @@ duplicate_eh_region_2 (o, n_array)
}
int
-duplicate_eh_regions (ifun, map)
- struct function *ifun;
- struct inline_remap *map;
+duplicate_eh_regions (struct function *ifun, struct inline_remap *map)
{
int ifun_last_region_number = ifun->eh->last_region_number;
struct eh_region **n_array, *root, *cur;
@@ -1417,9 +1381,7 @@ duplicate_eh_regions (ifun, map)
static int
-t2r_eq (pentry, pdata)
- const void *pentry;
- const void *pdata;
+t2r_eq (const void *pentry, const void *pdata)
{
tree entry = (tree) pentry;
tree data = (tree) pdata;
@@ -1428,16 +1390,14 @@ t2r_eq (pentry, pdata)
}
static hashval_t
-t2r_hash (pentry)
- const void *pentry;
+t2r_hash (const void *pentry)
{
tree entry = (tree) pentry;
return TYPE_HASH (TREE_PURPOSE (entry));
}
static void
-add_type_for_runtime (type)
- tree type;
+add_type_for_runtime (tree type)
{
tree *slot;
@@ -1451,8 +1411,7 @@ add_type_for_runtime (type)
}
static tree
-lookup_type_for_runtime (type)
- tree type;
+lookup_type_for_runtime (tree type)
{
tree *slot;
@@ -1476,9 +1435,7 @@ struct ttypes_filter GTY(())
(a tree) for a @TTypes type node we are thinking about adding. */
static int
-ttypes_filter_eq (pentry, pdata)
- const void *pentry;
- const void *pdata;
+ttypes_filter_eq (const void *pentry, const void *pdata)
{
const struct ttypes_filter *entry = (const struct ttypes_filter *) pentry;
tree data = (tree) pdata;
@@ -1487,8 +1444,7 @@ ttypes_filter_eq (pentry, pdata)
}
static hashval_t
-ttypes_filter_hash (pentry)
- const void *pentry;
+ttypes_filter_hash (const void *pentry)
{
const struct ttypes_filter *entry = (const struct ttypes_filter *) pentry;
return TYPE_HASH (entry->t);
@@ -1500,9 +1456,7 @@ ttypes_filter_hash (pentry)
should put these in some canonical order. */
static int
-ehspec_filter_eq (pentry, pdata)
- const void *pentry;
- const void *pdata;
+ehspec_filter_eq (const void *pentry, const void *pdata)
{
const struct ttypes_filter *entry = (const struct ttypes_filter *) pentry;
const struct ttypes_filter *data = (const struct ttypes_filter *) pdata;
@@ -1513,8 +1467,7 @@ ehspec_filter_eq (pentry, pdata)
/* Hash function for exception specification lists. */
static hashval_t
-ehspec_filter_hash (pentry)
- const void *pentry;
+ehspec_filter_hash (const void *pentry)
{
const struct ttypes_filter *entry = (const struct ttypes_filter *) pentry;
hashval_t h = 0;
@@ -1529,9 +1482,7 @@ ehspec_filter_hash (pentry)
up the search. Return the filter value to be used. */
static int
-add_ttypes_entry (ttypes_hash, type)
- htab_t ttypes_hash;
- tree type;
+add_ttypes_entry (htab_t ttypes_hash, tree type)
{
struct ttypes_filter **slot, *n;
@@ -1557,10 +1508,7 @@ add_ttypes_entry (ttypes_hash, type)
to speed up the search. Return the filter value to be used. */
static int
-add_ehspec_entry (ehspec_hash, ttypes_hash, list)
- htab_t ehspec_hash;
- htab_t ttypes_hash;
- tree list;
+add_ehspec_entry (htab_t ehspec_hash, htab_t ttypes_hash, tree list)
{
struct ttypes_filter **slot, *n;
struct ttypes_filter dummy;
@@ -1595,7 +1543,7 @@ add_ehspec_entry (ehspec_hash, ttypes_hash, list)
the same filter value, which saves table space. */
static void
-assign_filter_values ()
+assign_filter_values (void)
{
int i;
htab_t ttypes, ehspec;
@@ -1667,7 +1615,7 @@ assign_filter_values ()
landing pads. */
static void
-build_post_landing_pads ()
+build_post_landing_pads (void)
{
int i;
@@ -1783,7 +1731,7 @@ build_post_landing_pads ()
_Unwind_Resume otherwise. */
static void
-connect_post_landing_pads ()
+connect_post_landing_pads (void)
{
int i;
@@ -1824,7 +1772,7 @@ connect_post_landing_pads ()
static void
-dw2_build_landing_pads ()
+dw2_build_landing_pads (void)
{
int i;
unsigned int j;
@@ -1907,8 +1855,7 @@ struct sjlj_lp_info
};
static bool
-sjlj_find_directly_reachable_regions (lp_info)
- struct sjlj_lp_info *lp_info;
+sjlj_find_directly_reachable_regions (struct sjlj_lp_info *lp_info)
{
rtx insn;
bool found_one = false;
@@ -1956,9 +1903,7 @@ sjlj_find_directly_reachable_regions (lp_info)
}
static void
-sjlj_assign_call_site_values (dispatch_label, lp_info)
- rtx dispatch_label;
- struct sjlj_lp_info *lp_info;
+sjlj_assign_call_site_values (rtx dispatch_label, struct sjlj_lp_info *lp_info)
{
htab_t ar_hash;
int i, index;
@@ -2020,8 +1965,7 @@ sjlj_assign_call_site_values (dispatch_label, lp_info)
}
static void
-sjlj_mark_call_sites (lp_info)
- struct sjlj_lp_info *lp_info;
+sjlj_mark_call_sites (struct sjlj_lp_info *lp_info)
{
int last_call_site = -2;
rtx insn, mem;
@@ -2085,8 +2029,7 @@ sjlj_mark_call_sites (lp_info)
/* Construct the SjLj_Function_Context. */
static void
-sjlj_emit_function_enter (dispatch_label)
- rtx dispatch_label;
+sjlj_emit_function_enter (rtx dispatch_label)
{
rtx fn_begin, fc, mem, seq;
@@ -2151,14 +2094,13 @@ sjlj_emit_function_enter (dispatch_label)
the call to unwind_sjlj_unregister_libfunc if needed. */
void
-sjlj_emit_function_exit_after (after)
- rtx after;
+sjlj_emit_function_exit_after (rtx after)
{
cfun->eh->sjlj_exit_after = after;
}
static void
-sjlj_emit_function_exit ()
+sjlj_emit_function_exit (void)
{
rtx seq;
@@ -2178,9 +2120,7 @@ sjlj_emit_function_exit ()
}
static void
-sjlj_emit_dispatch_table (dispatch_label, lp_info)
- rtx dispatch_label;
- struct sjlj_lp_info *lp_info;
+sjlj_emit_dispatch_table (rtx dispatch_label, struct sjlj_lp_info *lp_info)
{
int i, first_reachable;
rtx mem, dispatch, seq, fc;
@@ -2243,7 +2183,7 @@ sjlj_emit_dispatch_table (dispatch_label, lp_info)
}
static void
-sjlj_build_landing_pads ()
+sjlj_build_landing_pads (void)
{
struct sjlj_lp_info *lp_info;
@@ -2271,7 +2211,7 @@ sjlj_build_landing_pads ()
}
void
-finish_eh_generation ()
+finish_eh_generation (void)
{
/* Nothing to do if no regions created. */
if (cfun->eh->region_tree == NULL)
@@ -2313,8 +2253,7 @@ finish_eh_generation ()
}
static hashval_t
-ehl_hash (pentry)
- const void *pentry;
+ehl_hash (const void *pentry)
{
struct ehl_map_entry *entry = (struct ehl_map_entry *) pentry;
@@ -2324,9 +2263,7 @@ ehl_hash (pentry)
}
static int
-ehl_eq (pentry, pdata)
- const void *pentry;
- const void *pdata;
+ehl_eq (const void *pentry, const void *pdata)
{
struct ehl_map_entry *entry = (struct ehl_map_entry *) pentry;
struct ehl_map_entry *data = (struct ehl_map_entry *) pdata;
@@ -2339,8 +2276,7 @@ ehl_eq (pentry, pdata)
/* Remove LABEL from exception_handler_label_map. */
static void
-remove_exception_handler_label (label)
- rtx label;
+remove_exception_handler_label (rtx label)
{
struct ehl_map_entry **slot, tmp;
@@ -2361,8 +2297,7 @@ remove_exception_handler_label (label)
/* Splice REGION from the region tree etc. */
static void
-remove_eh_handler (region)
- struct eh_region *region;
+remove_eh_handler (struct eh_region *region)
{
struct eh_region **pp, **pp_start, *p, *outer, *inner;
rtx lab;
@@ -2451,8 +2386,7 @@ remove_eh_handler (region)
delete the region. */
void
-maybe_remove_eh_handler (label)
- rtx label;
+maybe_remove_eh_handler (rtx label)
{
struct ehl_map_entry **slot, tmp;
struct eh_region *region;
@@ -2490,20 +2424,17 @@ maybe_remove_eh_handler (label)
loop hackery; should not be used by new code. */
void
-for_each_eh_label (callback)
- void (*callback) PARAMS ((rtx));
+for_each_eh_label (void (*callback) (rtx))
{
htab_traverse (cfun->eh->exception_handler_label_map, for_each_eh_label_1,
(void *)callback);
}
static int
-for_each_eh_label_1 (pentry, data)
- void **pentry;
- void *data;
+for_each_eh_label_1 (void **pentry, void *data)
{
struct ehl_map_entry *entry = *(struct ehl_map_entry **)pentry;
- void (*callback) PARAMS ((rtx)) = (void (*) PARAMS ((rtx))) data;
+ void (*callback) (rtx) = (void (*) (rtx)) data;
(*callback) (entry->label);
return 1;
@@ -2523,8 +2454,7 @@ struct reachable_info GTY(())
base class of TYPE, is in HANDLED. */
static int
-check_handled (handled, type)
- tree handled, type;
+check_handled (tree handled, tree type)
{
tree t;
@@ -2554,10 +2484,7 @@ check_handled (handled, type)
LP_REGION contains the landing pad; REGION is the handler. */
static void
-add_reachable_handler (info, lp_region, region)
- struct reachable_info *info;
- struct eh_region *lp_region;
- struct eh_region *region;
+add_reachable_handler (struct reachable_info *info, struct eh_region *lp_region, struct eh_region *region)
{
if (! info)
return;
@@ -2577,10 +2504,8 @@ add_reachable_handler (info, lp_region, region)
and caught/allowed type information between invocations. */
static enum reachable_code
-reachable_next_level (region, type_thrown, info)
- struct eh_region *region;
- tree type_thrown;
- struct reachable_info *info;
+reachable_next_level (struct eh_region *region, tree type_thrown,
+ struct reachable_info *info)
{
switch (region->type)
{
@@ -2741,8 +2666,7 @@ reachable_next_level (region, type_thrown, info)
reached by a given insn. */
rtx
-reachable_handlers (insn)
- rtx insn;
+reachable_handlers (rtx insn)
{
struct reachable_info info;
struct eh_region *region;
@@ -2793,7 +2717,7 @@ reachable_handlers (insn)
else
region = region->outer;
}
-
+
return info.handlers;
}
@@ -2801,8 +2725,7 @@ reachable_handlers (insn)
within the function. */
bool
-can_throw_internal (insn)
- rtx insn;
+can_throw_internal (rtx insn)
{
struct eh_region *region;
tree type_thrown;
@@ -2862,8 +2785,7 @@ can_throw_internal (insn)
visible outside the function. */
bool
-can_throw_external (insn)
- rtx insn;
+can_throw_external (rtx insn)
{
struct eh_region *region;
tree type_thrown;
@@ -2926,10 +2848,10 @@ can_throw_external (insn)
/* Set current_function_nothrow and cfun->all_throwers_are_sibcalls. */
void
-set_nothrow_function_flags ()
+set_nothrow_function_flags (void)
{
rtx insn;
-
+
current_function_nothrow = 1;
/* Assume cfun->all_throwers_are_sibcalls until we encounter
@@ -2942,7 +2864,7 @@ set_nothrow_function_flags ()
if (! flag_exceptions)
return;
-
+
for (insn = get_insns (); insn; insn = NEXT_INSN (insn))
if (can_throw_external (insn))
{
@@ -2976,7 +2898,7 @@ set_nothrow_function_flags ()
On the SPARC, this means flushing the register windows. */
void
-expand_builtin_unwind_init ()
+expand_builtin_unwind_init (void)
{
/* Set this so all the registers get saved in our frame; we need to be
able to copy the saved values for any registers from frames we unwind. */
@@ -2988,8 +2910,7 @@ expand_builtin_unwind_init ()
}
rtx
-expand_builtin_eh_return_data_regno (arglist)
- tree arglist;
+expand_builtin_eh_return_data_regno (tree arglist)
{
tree which = TREE_VALUE (arglist);
unsigned HOST_WIDE_INT iwhich;
@@ -3018,8 +2939,7 @@ expand_builtin_eh_return_data_regno (arglist)
return the actual address encoded in that value. */
rtx
-expand_builtin_extract_return_addr (addr_tree)
- tree addr_tree;
+expand_builtin_extract_return_addr (tree addr_tree)
{
rtx addr = expand_expr (addr_tree, NULL_RTX, Pmode, 0);
@@ -3051,8 +2971,7 @@ expand_builtin_extract_return_addr (addr_tree)
stack slot so the epilogue will return to that address. */
rtx
-expand_builtin_frob_return_addr (addr_tree)
- tree addr_tree;
+expand_builtin_frob_return_addr (tree addr_tree)
{
rtx addr = expand_expr (addr_tree, NULL_RTX, ptr_mode, 0);
@@ -3073,9 +2992,8 @@ expand_builtin_frob_return_addr (addr_tree)
exception handler. */
void
-expand_builtin_eh_return (stackadj_tree, handler_tree)
- tree stackadj_tree ATTRIBUTE_UNUSED;
- tree handler_tree;
+expand_builtin_eh_return (tree stackadj_tree ATTRIBUTE_UNUSED,
+ tree handler_tree)
{
rtx tmp;
@@ -3107,7 +3025,7 @@ expand_builtin_eh_return (stackadj_tree, handler_tree)
}
void
-expand_eh_return ()
+expand_eh_return (void)
{
rtx around_label;
@@ -3165,9 +3083,7 @@ struct action_record
};
static int
-action_record_eq (pentry, pdata)
- const void *pentry;
- const void *pdata;
+action_record_eq (const void *pentry, const void *pdata)
{
const struct action_record *entry = (const struct action_record *) pentry;
const struct action_record *data = (const struct action_record *) pdata;
@@ -3175,17 +3091,14 @@ action_record_eq (pentry, pdata)
}
static hashval_t
-action_record_hash (pentry)
- const void *pentry;
+action_record_hash (const void *pentry)
{
const struct action_record *entry = (const struct action_record *) pentry;
return entry->next * 1009 + entry->filter;
}
static int
-add_action_record (ar_hash, filter, next)
- htab_t ar_hash;
- int filter, next;
+add_action_record (htab_t ar_hash, int filter, int next)
{
struct action_record **slot, *new, tmp;
@@ -3216,9 +3129,7 @@ add_action_record (ar_hash, filter, next)
}
static int
-collect_one_action_chain (ar_hash, region)
- htab_t ar_hash;
- struct eh_region *region;
+collect_one_action_chain (htab_t ar_hash, struct eh_region *region)
{
struct eh_region *c;
int next;
@@ -3319,9 +3230,7 @@ collect_one_action_chain (ar_hash, region)
}
static int
-add_call_site (landing_pad, action)
- rtx landing_pad;
- int action;
+add_call_site (rtx landing_pad, int action)
{
struct call_site_record *data = cfun->eh->call_site_data;
int used = cfun->eh->call_site_data_used;
@@ -3349,7 +3258,7 @@ add_call_site (landing_pad, action)
instead to call site entries. */
void
-convert_to_eh_region_ranges ()
+convert_to_eh_region_ranges (void)
{
rtx insn, iter, note;
htab_t ar_hash;
@@ -3473,9 +3382,7 @@ convert_to_eh_region_ranges ()
static void
-push_uleb128 (data_area, value)
- varray_type *data_area;
- unsigned int value;
+push_uleb128 (varray_type *data_area, unsigned int value)
{
do
{
@@ -3489,9 +3396,7 @@ push_uleb128 (data_area, value)
}
static void
-push_sleb128 (data_area, value)
- varray_type *data_area;
- int value;
+push_sleb128 (varray_type *data_area, int value)
{
unsigned char byte;
int more;
@@ -3512,7 +3417,7 @@ push_sleb128 (data_area, value)
#ifndef HAVE_AS_LEB128
static int
-dw2_size_of_call_site_table ()
+dw2_size_of_call_site_table (void)
{
int n = cfun->eh->call_site_data_used;
int size = n * (4 + 4 + 4);
@@ -3528,7 +3433,7 @@ dw2_size_of_call_site_table ()
}
static int
-sjlj_size_of_call_site_table ()
+sjlj_size_of_call_site_table (void)
{
int n = cfun->eh->call_site_data_used;
int size = 0;
@@ -3546,7 +3451,7 @@ sjlj_size_of_call_site_table ()
#endif
static void
-dw2_output_call_site_table ()
+dw2_output_call_site_table (void)
{
const char *const function_start_lab
= IDENTIFIER_POINTER (current_function_func_begin_label);
@@ -3598,7 +3503,7 @@ dw2_output_call_site_table ()
}
static void
-sjlj_output_call_site_table ()
+sjlj_output_call_site_table (void)
{
int n = cfun->eh->call_site_data_used;
int i;
@@ -3619,7 +3524,7 @@ sjlj_output_call_site_table ()
table. */
void
-default_exception_section ()
+default_exception_section (void)
{
if (targetm.have_named_sections)
{
@@ -3643,7 +3548,7 @@ default_exception_section ()
}
void
-output_function_exception_table ()
+output_function_exception_table (void)
{
int tt_format, cs_format, lp_format, i, n;
#ifdef HAVE_AS_LEB128