diff options
Diffstat (limited to 'gcc/xcoffout.c')
-rw-r--r-- | gcc/xcoffout.c | 26 |
1 files changed, 14 insertions, 12 deletions
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). |