[PATCH v4] Fix range end handling of inlined subroutines - restart
Bernd Edlinger
bernd.edlinger@hotmail.de
Sun Nov 29 14:43:15 GMT 2020
Hi,
this is a new improved version of my patch.
It addresses two issues that came up when playing and debugging
the rather big and complex gcc application.
First I found cases where a completely empty inlined subroutine
was encountered, the step command can step into the inline,
but the call stack does not reflect that. Fixed that by
making an exception in dwarf2_get_pc_bounds for empty inlined
routines.
Then if a function is called immediatly after the inline,
the call stack shows the last line of the inline, but we
have a better line, a !is-stmt one following the inline
function. Fixed that by making find_pc_sect_line prefer a
!is_stmt line over a weak one if an in-between PC is requested.
There is a new test case for those two issues.
Finally I found that a "b inline-function" does not
always find the entry_pc, and instead the breakpoint is
at the first non-zero block range of the inline block.
Fixed that by moving the block that starts at entry_pc
to the first position.
Tested successfully on x86_64-pc-linux-gnu.
Is it OK for trunk?
Thanks
Bernd.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-Fix-range-end-handling-of-inlined-subroutines.patch
Type: text/x-patch
Size: 35817 bytes
Desc: not available
URL: <https://sourceware.org/pipermail/gdb-patches/attachments/20201129/fec0b5e9/attachment-0001.bin>
More information about the Gdb-patches
mailing list