From 93caa3957c91300fde832a03063a5f2d3dda4af9 Mon Sep 17 00:00:00 2001 From: David Malcolm Date: Mon, 30 Dec 2013 20:25:36 -0500 Subject: [PATCH 026/159] FIXME: concretize rtx in debug hooks --- gcc/dbxout.c | 8 ++++---- gcc/debug.c | 9 ++++----- gcc/debug.h | 8 ++++---- gcc/dwarf2out.c | 6 +++--- gcc/final.c | 6 +++--- gcc/sdbout.c | 2 +- gcc/vmsdbgout.c | 4 ++-- 7 files changed, 21 insertions(+), 22 deletions(-) diff --git a/gcc/dbxout.c b/gcc/dbxout.c index ad1533e..d9b99d0 100644 --- a/gcc/dbxout.c +++ b/gcc/dbxout.c @@ -371,9 +371,9 @@ const struct gcc_debug_hooks dbx_debug_hooks = debug_nothing_tree_tree_tree_bool, /* imported_module_or_decl */ debug_nothing_tree, /* deferred_inline_function */ debug_nothing_tree, /* outlining_inline_function */ - debug_nothing_rtx, /* label */ + debug_nothing_rtx_code_label, /* label */ dbxout_handle_pch, /* handle_pch */ - debug_nothing_rtx, /* var_location */ + debug_nothing_rtx_base_insn, /* var_location */ debug_nothing_void, /* switch_text_section */ debug_nothing_tree_tree, /* set_name */ 0, /* start_end_main_source_file */ @@ -407,9 +407,9 @@ const struct gcc_debug_hooks xcoff_debug_hooks = debug_nothing_tree_tree_tree_bool, /* imported_module_or_decl */ debug_nothing_tree, /* deferred_inline_function */ debug_nothing_tree, /* outlining_inline_function */ - debug_nothing_rtx, /* label */ + debug_nothing_rtx_code_label, /* label */ dbxout_handle_pch, /* handle_pch */ - debug_nothing_rtx, /* var_location */ + debug_nothing_rtx_base_insn, /* var_location */ debug_nothing_void, /* switch_text_section */ debug_nothing_tree_tree, /* set_name */ 0, /* start_end_main_source_file */ diff --git a/gcc/debug.c b/gcc/debug.c index 7ed50b4..c448c2f 100644 --- a/gcc/debug.c +++ b/gcc/debug.c @@ -48,9 +48,9 @@ const struct gcc_debug_hooks do_nothing_debug_hooks = debug_nothing_tree_tree_tree_bool, /* imported_module_or_decl */ debug_nothing_tree, /* deferred_inline_function */ debug_nothing_tree, /* outlining_inline_function */ - debug_nothing_rtx, /* label */ + debug_nothing_rtx_code_label, /* label */ debug_nothing_int, /* handle_pch */ - debug_nothing_rtx, /* var_location */ + debug_nothing_rtx_base_insn, /* var_location */ debug_nothing_void, /* switch_text_section */ debug_nothing_tree_tree, /* set_name */ 0, /* start_end_main_source_file */ @@ -91,13 +91,12 @@ debug_true_const_tree (const_tree block ATTRIBUTE_UNUSED) } void -debug_nothing_rtx (rtx insn ATTRIBUTE_UNUSED) +debug_nothing_rtx_base_insn (rtx_base_insn insn ATTRIBUTE_UNUSED) { } void -debug_nothing_rtx_rtx (rtx insn ATTRIBUTE_UNUSED, - rtx new_insn ATTRIBUTE_UNUSED) +debug_nothing_rtx_code_label (rtx_code_label label ATTRIBUTE_UNUSED) { } diff --git a/gcc/debug.h b/gcc/debug.h index 886de17..4ef64b0 100644 --- a/gcc/debug.h +++ b/gcc/debug.h @@ -119,14 +119,14 @@ struct gcc_debug_hooks /* Called from final_scan_insn for any CODE_LABEL insn whose LABEL_NAME is non-null. */ - void (* label) (rtx); + void (* label) (rtx_code_label); /* Called after the start and before the end of writing a PCH file. The parameter is 0 if after the start, 1 if before the end. */ void (* handle_pch) (unsigned int); /* Called from final_scan_insn for any NOTE_INSN_VAR_LOCATION note. */ - void (* var_location) (rtx); + void (* var_location) (rtx_base_insn); /* Called from final_scan_insn if there is a switch between hot and cold text sections. */ @@ -160,8 +160,8 @@ extern void debug_nothing_tree_tree (tree, tree); extern void debug_nothing_tree_int (tree, int); extern void debug_nothing_tree_tree_tree_bool (tree, tree, tree, bool); extern bool debug_true_const_tree (const_tree); -extern void debug_nothing_rtx (rtx); -extern void debug_nothing_rtx_rtx (rtx, rtx); +extern void debug_nothing_rtx_base_insn (rtx_base_insn); +extern void debug_nothing_rtx_code_label (rtx_code_label); /* Hooks for various debug formats. */ extern const struct gcc_debug_hooks do_nothing_debug_hooks; diff --git a/gcc/dwarf2out.c b/gcc/dwarf2out.c index 6586c93..293bd27 100644 --- a/gcc/dwarf2out.c +++ b/gcc/dwarf2out.c @@ -2381,7 +2381,7 @@ static void dwarf2out_imported_module_or_decl (tree, tree, tree, bool); static void dwarf2out_imported_module_or_decl_1 (tree, tree, tree, dw_die_ref); static void dwarf2out_abstract_function (tree); -static void dwarf2out_var_location (rtx); +static void dwarf2out_var_location (rtx_base_insn); static void dwarf2out_begin_function (tree); static void dwarf2out_end_function (unsigned int); static void dwarf2out_set_name (tree, tree); @@ -2421,7 +2421,7 @@ const struct gcc_debug_hooks dwarf2_debug_hooks = emitting the abstract description of inline functions until something tries to reference them. */ dwarf2out_abstract_function, /* outlining_inline_function */ - debug_nothing_rtx, /* label */ + debug_nothing_rtx_code_label, /* label */ debug_nothing_int, /* handle_pch */ dwarf2out_var_location, dwarf2out_switch_text_section, @@ -21044,7 +21044,7 @@ static unsigned int first_loclabel_num_not_at_text_label; our lookup table. */ static void -dwarf2out_var_location (rtx loc_note) +dwarf2out_var_location (rtx_base_insn loc_note) { char loclabel[MAX_ARTIFICIAL_LABEL_BYTES + 2]; struct var_loc_node *newloc; diff --git a/gcc/final.c b/gcc/final.c index ba4f6ea..b010493 100644 --- a/gcc/final.c +++ b/gcc/final.c @@ -2350,7 +2350,7 @@ final_scan_insn (rtx insn, FILE *file, int optimize_p ATTRIBUTE_UNUSED, case NOTE_INSN_VAR_LOCATION: case NOTE_INSN_CALL_ARG_LOCATION: if (!DECL_IGNORED_P (current_function_decl)) - debug_hooks->var_location (insn); + debug_hooks->var_location (insn->as_an_rtx_base_insn ()); break; default: @@ -2388,7 +2388,7 @@ final_scan_insn (rtx insn, FILE *file, int optimize_p ATTRIBUTE_UNUSED, CC_STATUS_INIT; if (!DECL_IGNORED_P (current_function_decl) && LABEL_NAME (insn)) - debug_hooks->label (insn); + debug_hooks->label (insn->as_an_rtx_code_label ()); app_disable (); @@ -2991,7 +2991,7 @@ final_scan_insn (rtx insn, FILE *file, int optimize_p ATTRIBUTE_UNUSED, assemble_external (t); } if (!DECL_IGNORED_P (current_function_decl)) - debug_hooks->var_location (insn); + debug_hooks->var_location (insn->as_an_rtx_base_insn ()); } /* Output assembler code from the template. */ diff --git a/gcc/sdbout.c b/gcc/sdbout.c index 8af0bc5..1d42e26 100644 --- a/gcc/sdbout.c +++ b/gcc/sdbout.c @@ -302,7 +302,7 @@ const struct gcc_debug_hooks sdb_debug_hooks = debug_nothing_tree, /* outlining_inline_function */ sdbout_label, /* label */ debug_nothing_int, /* handle_pch */ - debug_nothing_rtx, /* var_location */ + debug_nothing_rtx_base_insn, /* var_location */ debug_nothing_void, /* switch_text_section */ debug_nothing_tree_tree, /* set_name */ 0, /* start_end_main_source_file */ diff --git a/gcc/vmsdbgout.c b/gcc/vmsdbgout.c index 7972dd7..73d71fd 100644 --- a/gcc/vmsdbgout.c +++ b/gcc/vmsdbgout.c @@ -193,9 +193,9 @@ const struct gcc_debug_hooks vmsdbg_debug_hooks debug_nothing_tree_tree_tree_bool, /* imported_module_or_decl */ debug_nothing_tree, /* deferred_inline_function */ vmsdbgout_abstract_function, - debug_nothing_rtx, /* label */ + debug_nothing_rtx_base_insn, /* label */ debug_nothing_int, /* handle_pch */ - debug_nothing_rtx, /* var_location */ + debug_nothing_rtx_base_insn, /* var_location */ debug_nothing_void, /* switch_text_section */ debug_nothing_tree_tree, /* set_name */ 0, /* start_end_main_source_file */ -- 1.7.11.7