Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
* [PATCH 0/5] Improved support for core files with missing NT_FILE note
@ 2026-03-14 14:32 Andrew Burgess
  2026-03-14 14:32 ` [PATCH 1/5] gdb/testsuite: improve corefile-no-threads.py script Andrew Burgess
                   ` (5 more replies)
  0 siblings, 6 replies; 9+ messages in thread
From: Andrew Burgess @ 2026-03-14 14:32 UTC (permalink / raw)
  To: gdb-patches; +Cc: Andrew Burgess

This series improves GDB's support for core files without an NT_FILE
note.  When this note is missing GDB is currently unable to associate
a build-id with any of the shared libraries that loaded as the core
file is opened.  As a result GDB might load the wrong shared library
if a local library happens to have the same name (e.g. is a different
version of the same library), and GDB will not perform a build-id
based lookup either locally, or through debuginfod, for the missing
shared library.

Patches #1 and #2 rework some existing tests.  This gets these tests
into a state where they can be reused for testing the fixes that come
later in the series.

Patches #3 and #4 are minor refactoring patches removing some code
that will make the later patch in this series harder.

Patch #5 is the actual fix.  After this, on GNU/Linux, GDB will be
able to associate a build-id with a shared library, even if the
NT_FILE note is missing from a core file.

Thanks,
Andrew

---

Andrew Burgess (5):
  gdb/testsuite: improve corefile-no-threads.py script
  gdb/testsuite: restructure gdb.base/corefile-buildid.exp
  gdb: remove 'num' argument from gdbarch_read_core_file_mappings
    callback
  gdb: remove pre-loop callback from gdbarch_read_core_file_mappings
  gdb/linux: handle missing NT_FILE note when opening core files

 gdb/arch-utils.c                              |   1 -
 gdb/arch-utils.h                              |   1 -
 gdb/corelow.c                                 |  68 ++--
 gdb/doc/python.texi                           |  10 +-
 gdb/gdbarch-gen.c                             |   4 +-
 gdb/gdbarch-gen.h                             |   4 +-
 gdb/gdbarch.h                                 |   8 +-
 gdb/gdbarch_components.py                     |   1 -
 gdb/gdbcore.h                                 |  28 +-
 gdb/linux-tdep.c                              | 342 +++++++++++-------
 gdb/testsuite/gdb.base/corefile-buildid.exp   | 290 +++++++++++----
 .../gdb.base/corefile-no-threads.exp          |  10 +-
 gdb/testsuite/gdb.base/corefile-no-threads.py |  47 ++-
 gdb/testsuite/gdb.python/py-corefile.py       |   4 +
 14 files changed, 555 insertions(+), 263 deletions(-)


base-commit: e4fe38115fea0a9f357527959893f18ca8d51a03
-- 
2.25.4


^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2026-05-01 19:10 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-03-14 14:32 [PATCH 0/5] Improved support for core files with missing NT_FILE note Andrew Burgess
2026-03-14 14:32 ` [PATCH 1/5] gdb/testsuite: improve corefile-no-threads.py script Andrew Burgess
2026-03-14 14:32 ` [PATCH 2/5] gdb/testsuite: restructure gdb.base/corefile-buildid.exp Andrew Burgess
2026-03-14 14:32 ` [PATCH 3/5] gdb: remove 'num' argument from gdbarch_read_core_file_mappings callback Andrew Burgess
2026-03-14 14:32 ` [PATCH 4/5] gdb: remove pre-loop callback from gdbarch_read_core_file_mappings Andrew Burgess
2026-03-14 14:32 ` [PATCH 5/5] gdb/linux: handle missing NT_FILE note when opening core files Andrew Burgess
2026-04-23 22:08   ` Keith Seitz
2026-05-01 19:09     ` Andrew Burgess
2026-04-23 22:06 ` [PATCH 0/5] Improved support for core files with missing NT_FILE note Keith Seitz

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox