From 653e276c6536663cda57bda038a9df4e64adb96f Mon Sep 17 00:00:00 2001 From: Neil Booth Date: Tue, 17 Jul 2001 19:47:58 +0000 Subject: dbxout.c (dbxout_really_begin_function): Rename to dbxout_begin_function. * dbxout.c (dbxout_really_begin_function): Rename to dbxout_begin_function. (dbx_debug_hooks, xcoff_debug_hooks): Update. (dbxout_begin_function): Remove. (dbxout_function): Update. (dbxout_source_line): Update prototype. * dbxout.h (dbxout_begin_function): Remove. * debug.c (do_nothing_debug_hooks): Update. (debug_nothing_tree): Update. (debug_nothing_charstar_rtx): Remove. * debug.h (union tree_node): Declare. (struct rtx_def): Remove. (gcc_debug_hooks): New hooks begin_prologue, end_prologue, begin_function. Change source_line prototype. (debug_nothing_tree): New. (debug_nothing_charstar_rtx): Delete. (dwarf2out_begin_prologue): Moved from ... * tree.h: ... here. * dwarf2out.c (dwarf2_debug_hooks): Update. (dwarf2out_begin_prologue): Update prototype. If genuine dwarf2 debug info, call dwarf2out_source_line. (dwarf2out_souce_line): Update prototype. * dwarfout.c (dwarfout_begin_function): Rename dwarfout_end_prologue. Change prototype, make static. (dwarfout_source_line): Update prototype. (dwarf_debug_hooks): Update. * dwarfout.h (dwarfout_begin_function): Remove. * final.c (final_start_function, final_scan_insn): Use appropriate debug hooks, update to use notice_source_line. (output_source_line): Rename notice_source_line. Don't call the source_line debug hook. * sdbout.c (sdbout_begin_function): Rename sdbout_begin_prologue, make static, update prototype. (sdbout_mark_begin_function): Rename sdbout_begin_function, update prototype. (sdbout_end_prologue): New. (sdbout_source_line): Update prototype. (sdbout_debug_hooks): Update. (sdbout_symbol): Remove unused var. * sdbout.h (sdbout_begin_function, sdbout_mark_begin_function): Delete. * varasm.c: Include debug.h. (assemble_start_function): Use begin_function debug_hook. * xcoffout.c (xcoffout_begin_prologue): Rename xcoffout_begin_function, update with prototype. (xcoffout_source_line): Update prototype. * xcoffout.h (xcoffout_begin_prologue): Rename xcoffout_begin_function, update prototype. (xcoffout_source_line): Update prototype. From-SVN: r44087 --- gcc/xcoffout.c | 26 ++++++++++++++------------ 1 file changed, 14 insertions(+), 12 deletions(-) (limited to 'gcc/xcoffout.c') diff --git a/gcc/xcoffout.c b/gcc/xcoffout.c index e8dd43f..6955329 100644 --- a/gcc/xcoffout.c +++ b/gcc/xcoffout.c @@ -304,17 +304,19 @@ xcoffout_source_file (file, filename, inline_p) } } -/* Output a line number symbol entry into output stream FILE, - for source file FILENAME and line number NOTE. */ +/* Output a line number symbol entry for location (FILENAME, LINE). */ void -xcoffout_source_line (filename, note) +xcoffout_source_line (line, filename) + unsigned int line; const char *filename; - rtx note; { - xcoffout_source_file (asm_out_file, filename, RTX_INTEGRATED_P (note)); + bool inline_p = (strcmp (xcoff_current_function_file, filename) != 0 + || (int) line < xcoff_begin_function_line); + + xcoffout_source_file (asm_out_file, filename, inline_p); - ASM_OUTPUT_SOURCE_LINE (asm_out_file, NOTE_LINE_NUMBER (note)); + ASM_OUTPUT_SOURCE_LINE (asm_out_file, line); } /* Output the symbols defined in block number DO_BLOCK. @@ -431,17 +433,17 @@ xcoffout_declare_function (file, decl, name) name, name, name, name); } -/* Called at beginning of function body (after prologue). +/* Called at beginning of function body (at start of prologue). Record the function's starting line number, so we can output relative line numbers for the other lines. Record the file name that this function is contained in. */ void -xcoffout_begin_function (file, last_linenum) - FILE *file; - int last_linenum; +xcoffout_begin_prologue (line, file) + unsigned int line; + const char *file ATTRIBUTE_UNUSED; { - ASM_OUTPUT_LFB (file, last_linenum); + ASM_OUTPUT_LFB (asm_out_file, line); dbxout_parms (DECL_ARGUMENTS (current_function_decl)); /* Emit the symbols for the outermost BLOCK's variables. sdbout.c does this @@ -452,7 +454,7 @@ xcoffout_begin_function (file, last_linenum) xcoffout_block (DECL_INITIAL (current_function_decl), 0, DECL_ARGUMENTS (current_function_decl)); - ASM_OUTPUT_SOURCE_LINE (file, last_linenum); + ASM_OUTPUT_SOURCE_LINE (asm_out_file, line); } /* Called at end of function (before epilogue). -- cgit v1.1