[Bug debug/94474] Incorrect DWARF range information for inlined function

2021-12-28 Thread bernd.edlinger at hotmail dot de via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=94474 --- Comment #15 from Bernd Edlinger --- While there are certainly empty subranges that could be avoided, there are also completely empty subroutines, which cannot be avoided without losing the ability to inspect the procedure variable at this loc

[Bug debug/94474] Incorrect DWARF range information for inlined function

2021-12-28 Thread bernd.edlinger at hotmail dot de via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=94474 --- Comment #14 from Bernd Edlinger --- (In reply to Andrew Burgess from comment #0) > + This bug report has a bit of history. Originally there was a GCC > patch here: >https://gcc.gnu.org/ml/gcc-patches/2019-10/msg01459.html >

[Bug debug/94474] Incorrect DWARF range information for inlined function

2020-05-17 Thread bernd.edlinger at hotmail dot de
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=94474 --- Comment #13 from Bernd Edlinger --- Hi Andrew, You are right about the instruction re-ordering, that is done in a compiler pass, which simply re-orders RTL instruction lists. But I think when the code motion happens, we just have no easy acc

[Bug debug/94474] Incorrect DWARF range information for inlined function

2020-05-17 Thread andrew.burgess at embecosm dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=94474 --- Comment #12 from Andrew Burgess --- > But what I learned from writing the patch is that gcc cannot > easily tell if a range will be empty or not. That is because > the assembler does emit the line info and the views, > and the assembler deci

[Bug debug/94474] Incorrect DWARF range information for inlined function

2020-05-16 Thread bernd.edlinger at hotmail dot de
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=94474 --- Comment #11 from Bernd Edlinger --- Andrew, (In reply to Andrew Burgess from comment #10) > Further, I've seen no mention of exit views anywhere, and I think they > would also be needed. > Yes, that is also my idea, when I say the dwarf2 s

[Bug debug/94474] Incorrect DWARF range information for inlined function

2020-04-28 Thread andrew.burgess at embecosm dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=94474 --- Comment #10 from Andrew Burgess --- Bernd, Not a problem, always happy to expand on things. This might get a little long, but hopefully it should give you an idea what I think is wrong. I have not updated the reproducer, I don't know why I

[Bug debug/94474] Incorrect DWARF range information for inlined function

2020-04-27 Thread bernd.edlinger at hotmail dot de
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=94474 --- Comment #9 from Bernd Edlinger --- Andrew, please update the reproducer, and explain in more detail what you would like to be changed. I still do not understand your idea. But I try hard to do so. Please be patient with me. Bernd.

[Bug debug/94474] Incorrect DWARF range information for inlined function

2020-04-06 Thread andrew.burgess at embecosm dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=94474 --- Comment #8 from Andrew Burgess --- Bernd, Please could you keep discussion of GDB patches to the GDB mailing list unless it is required to move this bug forward. In this bug I make the claim that the DWARF GCC produces is not correct. So

[Bug debug/94474] Incorrect DWARF range information for inlined function

2020-04-06 Thread bernd.edlinger at hotmail dot de
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=94474 --- Comment #7 from Bernd Edlinger --- > I don't understand why each range wouldn't need its own view number? Each of the sub ranges end PC can be an exit point. At least how I see it. Please have a look at my patch. It adds each of the ranges

[Bug debug/94474] Incorrect DWARF range information for inlined function

2020-04-06 Thread bernd.edlinger at hotmail dot de
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=94474 --- Comment #6 from Bernd Edlinger --- Right, #+BEGIN_EXAMPLE 0030 00400545 00400545 (start == end) 0030 00400549 00400553 0030 00400430 00400435 0030

[Bug debug/94474] Incorrect DWARF range information for inlined function

2020-04-06 Thread andrew.burgess at embecosm dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=94474 --- Comment #5 from Andrew Burgess --- Bernd, Wouldn't DW_AT_GNU_exit_view be attached to the DW_TAG_inlined_subroutine though? So, as in this case, one subroutine has 2 ranges, but would then have one end view number. I don't understand wh

[Bug debug/94474] Incorrect DWARF range information for inlined function

2020-04-06 Thread bernd.edlinger at hotmail dot de
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=94474 --- Comment #4 from Bernd Edlinger --- Can you please approve my patch now? https://sourceware.org/pipermail/gdb-patches/2020-April/167385.html Thanks Bernd.

[Bug debug/94474] Incorrect DWARF range information for inlined function

2020-04-06 Thread bernd.edlinger at hotmail dot de
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=94474 --- Comment #3 from Bernd Edlinger --- (In reply to Andrew Burgess from comment #2) > Sorry for including the wrong DWARF dump output in the bug report. I too > had seen the DW_AT_GNU_entry_view using a more recent binutils. > NP. > When you

[Bug debug/94474] Incorrect DWARF range information for inlined function

2020-04-06 Thread andrew.burgess at embecosm dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=94474 --- Comment #2 from Andrew Burgess --- Sorry for including the wrong DWARF dump output in the bug report. I too had seen the DW_AT_GNU_entry_view using a more recent binutils. When you pose the question: I am not sure if there are any view n

[Bug debug/94474] Incorrect DWARF range information for inlined function

2020-04-06 Thread bernd.edlinger at hotmail dot de
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=94474 --- Comment #1 from Bernd Edlinger --- Hi, I use a newer binutils versions FWIW, and buit GCC-10 from a few days ago using those binutils. $ readelf -version GNU readelf (GNU Binutils) 2.32 Copyright (C) 2019 Free Software Foundation, Inc. This