From: Andrew Burgess <aburgess@redhat.com>
To: gdb-patches@sourceware.org
Cc: Andrew Burgess <aburgess@redhat.com>
Subject: [PATCHv3 0/7] Inline Function Optimised Code Debug Improvements
Date: Thu, 16 Oct 2025 18:49:46 +0100 [thread overview]
Message-ID: <cover.1760636870.git.aburgess@redhat.com> (raw)
In-Reply-To: <cover.1754038556.git.aburgess@redhat.com>
In v3:
- Rebased to current upstream HEAD. Resolved merged conflicts, and
retested.
- Reread all the patches, and updated / tweaked some of the comment
and commit messages, but no changes to the code other than as
required to fix merge conflicts.
- Updated the tests to take account of changes to the DWARF assembler.
In v2:
- Fixes to the test added in patch (2) to address failures reported
from Linaro CI. The issues all relate to compiling the DWARF
assembler test with `-pie` which is on by default for the Linaro
CI machines. The issues were all DWARF generation issues.
- Rebased series to more recent upstream/master.
---
This series presents some improvements to debugging inline functions,
especially in optimised code.
The first two patches of this series have been posted previously here:
https://inbox.sourceware.org/gdb-patches/cover.1736865029.git.aburgess@redhat.com
This series replaces that earlier work, though the patches are
basically unchanged.
This entire series is an alternative solution to the patches that were
posted here:
https://inbox.sourceware.org/gdb-patches/AS1PR01MB946510286FBF2497A6F03E83E4922@AS1PR01MB9465.eurprd01.prod.exchangelabs.com/
My reasons for writing an alternative patch set can be found in the
commit messages of patches (2) and (7), I'm not going to repeat them
here. However, Bernd, the original patch author, did amazing work
identifying the problems GDB was having, and these patches likely
wouldn't exist without the original patch series, so a big thanks
there.
For reviewing, this series can be considered in 3 parts:
+ Patches (1) and (2) are independent from the rest of the series,
though related in theme. Both these patches could be approved and
merged ahead of remaining work, and do offer an improvement to GDB
on their own.
+ Patches (3), (4), (5), and (6) are refactoring work to support the
last patch. These can be reviewed, but shouldn't be merged until
the last patch is approved.
+ Patch (7) covers the final parts of this work, which deal with
non-empty inline functions.
All thoughts and feedback are welcome.
Thanks,
Andrew
---
Andrew Burgess (7):
gdb: improve line number lookup around inline functions
gdb: handle empty ranges for inline subroutines
gdb: split dwarf line table parsing in two
gdb: move block range recording into its own function
gdb: create address map after parsing all DIE
gdb: record block end addresses while parsing DIEs
gdb: fix-up truncated inline function block ranges
gdb/buildsym.c | 42 +-
gdb/buildsym.h | 13 +-
gdb/dwarf2/cu.h | 7 +
gdb/dwarf2/line-program.c | 120 +++-
gdb/dwarf2/line-program.h | 25 +-
gdb/dwarf2/read.c | 181 +++++-
gdb/symtab.c | 25 +-
gdb/testsuite/gdb.cp/step-and-next-inline.exp | 171 ++++--
.../gdb.dwarf2/dw2-empty-inline-low-high.c | 39 ++
.../gdb.dwarf2/dw2-empty-inline-low-high.exp | 128 ++++
.../gdb.dwarf2/dw2-empty-inline-ranges.c | 54 ++
.../gdb.dwarf2/dw2-empty-inline-ranges.exp | 262 ++++++++
.../gdb.dwarf2/dw2-extend-inline-block.c | 78 +++
.../gdb.dwarf2/dw2-extend-inline-block.exp | 574 ++++++++++++++++++
gdb/testsuite/gdb.dwarf2/dw2-inline-bt.c | 79 +++
gdb/testsuite/gdb.dwarf2/dw2-inline-bt.exp | 227 +++++++
.../gdb.dwarf2/dw2-unexpected-entry-pc.exp | 75 ++-
gdb/testsuite/gdb.opt/empty-inline-cxx.cc | 65 ++
gdb/testsuite/gdb.opt/empty-inline-cxx.exp | 95 +++
gdb/testsuite/gdb.opt/empty-inline.c | 40 ++
gdb/testsuite/gdb.opt/empty-inline.exp | 130 ++++
gdb/testsuite/gdb.opt/inline-bt.c | 28 +
gdb/testsuite/gdb.opt/inline-bt.exp | 119 ++--
23 files changed, 2352 insertions(+), 225 deletions(-)
create mode 100644 gdb/testsuite/gdb.dwarf2/dw2-empty-inline-low-high.c
create mode 100644 gdb/testsuite/gdb.dwarf2/dw2-empty-inline-low-high.exp
create mode 100644 gdb/testsuite/gdb.dwarf2/dw2-empty-inline-ranges.c
create mode 100644 gdb/testsuite/gdb.dwarf2/dw2-empty-inline-ranges.exp
create mode 100644 gdb/testsuite/gdb.dwarf2/dw2-extend-inline-block.c
create mode 100644 gdb/testsuite/gdb.dwarf2/dw2-extend-inline-block.exp
create mode 100644 gdb/testsuite/gdb.dwarf2/dw2-inline-bt.c
create mode 100644 gdb/testsuite/gdb.dwarf2/dw2-inline-bt.exp
create mode 100644 gdb/testsuite/gdb.opt/empty-inline-cxx.cc
create mode 100644 gdb/testsuite/gdb.opt/empty-inline-cxx.exp
create mode 100644 gdb/testsuite/gdb.opt/empty-inline.c
create mode 100644 gdb/testsuite/gdb.opt/empty-inline.exp
base-commit: b6753354fbbe7c2c66ae9f452ba7aa049db0fe0c
--
2.47.1
next prev parent reply other threads:[~2025-10-16 17:51 UTC|newest]
Thread overview: 37+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-07-20 10:20 [PATCH " Andrew Burgess
2025-07-20 10:20 ` [PATCH 1/7] gdb: improve line number lookup around inline functions Andrew Burgess
2025-07-20 10:20 ` [PATCH 2/7] gdb: handle empty ranges for inline subroutines Andrew Burgess
2025-07-20 10:20 ` [PATCH 3/7] gdb: split dwarf line table parsing in two Andrew Burgess
2025-07-20 10:20 ` [PATCH 4/7] gdb: move block range recording into its own function Andrew Burgess
2025-07-20 10:20 ` [PATCH 5/7] gdb: create address map after parsing all DIE Andrew Burgess
2025-07-20 10:20 ` [PATCH 6/7] gdb: record block end addresses while parsing DIEs Andrew Burgess
2025-07-20 10:20 ` [PATCH 7/7] gdb: fix-up truncated inline function block ranges Andrew Burgess
2025-08-01 8:58 ` [PATCHv2 0/7] Inline Function Optimised Code Debug Improvements Andrew Burgess
2025-08-01 8:58 ` [PATCHv2 1/7] gdb: improve line number lookup around inline functions Andrew Burgess
2025-08-01 8:58 ` [PATCHv2 2/7] gdb: handle empty ranges for inline subroutines Andrew Burgess
2025-08-01 8:58 ` [PATCHv2 3/7] gdb: split dwarf line table parsing in two Andrew Burgess
2025-08-01 8:58 ` [PATCHv2 4/7] gdb: move block range recording into its own function Andrew Burgess
2025-08-01 8:58 ` [PATCHv2 5/7] gdb: create address map after parsing all DIE Andrew Burgess
2025-08-01 8:58 ` [PATCHv2 6/7] gdb: record block end addresses while parsing DIEs Andrew Burgess
2025-08-01 8:58 ` [PATCHv2 7/7] gdb: fix-up truncated inline function block ranges Andrew Burgess
2025-10-16 17:49 ` Andrew Burgess [this message]
2025-10-16 17:49 ` [PATCHv3 1/7] gdb: improve line number lookup around inline functions Andrew Burgess
2025-10-27 22:22 ` Tom Tromey
2025-12-17 14:32 ` Andrew Burgess
2025-12-17 14:48 ` Tom de Vries
2025-12-18 14:46 ` Andrew Burgess
2025-10-16 17:49 ` [PATCHv3 2/7] gdb: handle empty ranges for inline subroutines Andrew Burgess
2025-10-16 17:49 ` [PATCHv3 3/7] gdb: split dwarf line table parsing in two Andrew Burgess
2025-10-16 17:49 ` [PATCHv3 4/7] gdb: move block range recording into its own function Andrew Burgess
2025-10-27 22:45 ` Tom Tromey
2025-10-16 17:49 ` [PATCHv3 5/7] gdb: create address map after parsing all DIE Andrew Burgess
2025-10-27 22:56 ` Tom Tromey
2026-01-02 16:36 ` Andrew Burgess
2026-01-05 20:03 ` Tom Tromey
2026-01-05 21:37 ` Andrew Burgess
2026-01-06 0:53 ` Tom Tromey
2025-10-16 17:49 ` [PATCHv3 6/7] gdb: record block end addresses while parsing DIEs Andrew Burgess
2025-10-27 23:00 ` Tom Tromey
2025-10-16 17:49 ` [PATCHv3 7/7] gdb: fix-up truncated inline function block ranges Andrew Burgess
2026-02-04 10:43 ` [PATCHv3 0/7] Inline Function Optimised Code Debug Improvements Andrew Burgess
2025-08-01 15:41 ` [PATCH " Sam James
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=cover.1760636870.git.aburgess@redhat.com \
--to=aburgess@redhat.com \
--cc=gdb-patches@sourceware.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox