From: Richard Biener Date: Tue, 2 Oct 2018 10:07:29 +0000 (+0000) Subject: tree-inline.c (expand_call_inline): Use the location of the callee declaration for... X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=cd6ae11750ba45a574cb1265aeb6ca08d30c2d7c;p=gcc.git tree-inline.c (expand_call_inline): Use the location of the callee declaration for the inline-entry marker. 2018-10-02 Richard Biener * tree-inline.c (expand_call_inline): Use the location of the callee declaration for the inline-entry marker. * final.c (notice_source_line): Remove special-casing of NOTE_INSN_INLINE_ENTRY. From-SVN: r264778 --- diff --git a/gcc/ChangeLog b/gcc/ChangeLog index b43cc388fa8..025f809eb60 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,10 @@ +2018-10-02 Richard Biener + + * tree-inline.c (expand_call_inline): Use the location of + the callee declaration for the inline-entry marker. + * final.c (notice_source_line): Remove special-casing of + NOTE_INSN_INLINE_ENTRY. + 2018-10-01 Carl Love PR 69431 diff --git a/gcc/final.c b/gcc/final.c index 6943c073d9b..6e61f1e17a8 100644 --- a/gcc/final.c +++ b/gcc/final.c @@ -3224,17 +3224,6 @@ notice_source_line (rtx_insn *insn, bool *is_stmt) if (NOTE_MARKER_P (insn)) { location_t loc = NOTE_MARKER_LOCATION (insn); - /* The inline entry markers (gimple, insn, note) carry the - location of the call, because that's what we want to carry - during compilation, but the location we want to output in - debug information for the inline entry point is the location - of the function itself. */ - if (NOTE_KIND (insn) == NOTE_INSN_INLINE_ENTRY) - { - tree block = LOCATION_BLOCK (loc); - tree fn = block_ultimate_origin (block); - loc = DECL_SOURCE_LOCATION (fn); - } expanded_location xloc = expand_location (loc); if (xloc.line == 0) { diff --git a/gcc/tree-inline.c b/gcc/tree-inline.c index 6b5ef36f6d2..ff8ee8ce78f 100644 --- a/gcc/tree-inline.c +++ b/gcc/tree-inline.c @@ -4592,7 +4592,8 @@ expand_call_inline (basic_block bb, gimple *stmt, copy_body_data *id) { gimple_stmt_iterator si = gsi_last_bb (bb); gsi_insert_after (&si, gimple_build_debug_inline_entry - (id->block, input_location), GSI_NEW_STMT); + (id->block, DECL_SOURCE_LOCATION (id->src_fn)), + GSI_NEW_STMT); } if (DECL_INITIAL (fn))