[PATCHv6 0/4] More build-id checking when opening core files
Andrew Burgess
aburgess@redhat.com
Tue Sep 3 17:24:54 GMT 2024
I'm thinking about pushing this patch pretty soon. Though this series
slightly bigger than I'd usually push with no reviews, the changes are
all constrained to the core file opening code, so is unlikely to
impact anything outside that area.
I have another 10+ patches that are building on this work that are
almost ready for posting so I'd like to get this initial work in and
have a chance to see if it causes problems for anyone before the next
set of patches are posted.
If anyone is planning to review and would like me to hold off, just
let me know and I'll keep waiting.
Thanks,
Andrew
In v6:
- Updated to current master and retested.
- Renamed a function in the final patch.
In v5:
- Updated to later master. Small merge issue where a different
patch removed a method from solib_ops while I've added a new
method. This caused some build problems as I'd added too many
fields in some cases. The fix is trivial and everything now
builds and tests OK.
In v4:
- I revisted these patches, and after reading through I figured
there's a simpler approach to solving the problem in patch #1. As
such, patch #1 is rewritten in this iteration, though the test is
unchanged.
- Rebased the series onto current master and retested.
In v3:
- I started working on the next set of patches in this series, not
ready for posting just yet, but they will eventually apply on top
of this series. While doing that I made some tweaks to patch #3
in this series, nothing huge, just moved some code around to make
it more sharable later on, the underlying logic remains the same.
- Patches #1, #2, and #4 are unchanged.
- Rebased and retested.
In v2:
- Failures were reported in the new tests from Linaro CI testing.
Nothing serious; Linaro was seeing some additional output that the
regexp I'd written were not accounting for. I've revised the new
tests to try and not be too strict, hopefully this should address
the issues that were reported.
- I've cleaned up some build vs host mistakes I think I made in some
remote_exec calls.
- And I've run the tests agsint 'make check-all-boards' and resolved
some issues that cropped up.
---
Andrew Burgess (4):
gdb/corefile: don't pretend unavailable sections are readable
gdb/corefile: improve file backed mapping handling
gdb: improve shared library build-id check for core-files
gdb: unify build-id to objfile lookup code
gdb/build-id.c | 42 +-
gdb/build-id.h | 22 +-
gdb/corelow.c | 757 ++++++++++++++----
gdb/gdbcore.h | 66 ++
gdb/solib-aix.c | 5 +
gdb/solib-darwin.c | 5 +
gdb/solib-dsbt.c | 5 +
gdb/solib-frv.c | 5 +
gdb/solib-svr4.c | 10 +
gdb/solib-target.c | 5 +
gdb/solib.c | 123 ++-
gdb/solib.h | 7 -
gdb/solist.h | 22 +
gdb/testsuite/gdb.base/corefile.exp | 39 +
gdb/testsuite/gdb.base/solib-search.exp | 6 +-
.../gdb.debuginfod/corefile-mapped-file-1.c | 24 +
.../gdb.debuginfod/corefile-mapped-file-2.c | 22 +
.../gdb.debuginfod/corefile-mapped-file-3.c | 45 ++
.../gdb.debuginfod/corefile-mapped-file.exp | 380 +++++++++
.../gdb.debuginfod/solib-with-soname-1.c | 39 +
.../gdb.debuginfod/solib-with-soname-2.c | 41 +
.../gdb.debuginfod/solib-with-soname.exp | 290 +++++++
gdb/testsuite/lib/gdb.exp | 7 +-
23 files changed, 1704 insertions(+), 263 deletions(-)
create mode 100644 gdb/testsuite/gdb.debuginfod/corefile-mapped-file-1.c
create mode 100644 gdb/testsuite/gdb.debuginfod/corefile-mapped-file-2.c
create mode 100644 gdb/testsuite/gdb.debuginfod/corefile-mapped-file-3.c
create mode 100644 gdb/testsuite/gdb.debuginfod/corefile-mapped-file.exp
create mode 100644 gdb/testsuite/gdb.debuginfod/solib-with-soname-1.c
create mode 100644 gdb/testsuite/gdb.debuginfod/solib-with-soname-2.c
create mode 100644 gdb/testsuite/gdb.debuginfod/solib-with-soname.exp
base-commit: a6ecb18b796b2a7342ab72d14c6bd440b718030f
--
2.25.4
More information about the Gdb-patches
mailing list