]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commit
gdb: fully separate coff and elf reading from dbx
authorGuinevere Larsen <guinevere@redhat.com>
Tue, 10 Sep 2024 17:42:30 +0000 (14:42 -0300)
committerGuinevere Larsen <guinevere@redhat.com>
Fri, 20 Sep 2024 20:02:16 +0000 (17:02 -0300)
commit59d41830a3dae0120e0d223f91241ad40e7ca737
tree89846ba9d94da9c70b67af6b46c1a9c1f51d4d82
parent3cd1748a7d156dcf7cdaed0a7f6dede6eebbcc11
gdb: fully separate coff and elf reading from dbx

With the previous commits, the only thing entangling elf and coff file
reading with dbx file reading is the functions
{elf|coff}stab_build_psymtabs, defined in dbxread.c. These functions
depend on dbx_symfile_read.

To solve this, I renamed read_stabs_symtab to read_stabs_symtab_1, and
created a function with the original name that does what
dbx_symfile_read used to do.

This way, dbx_symfile_read can just call read_stabs_symtab, and the elf
and coff psymtab builders can also call it directly, fully disentangling
the readers, which would allow us to selectively not compile dbxread in
the future.

Approved-By: Tom Tromey <tom@tromey.com>
gdb/coffread.c
gdb/dbxread.c
gdb/elfread.c
gdb/stabsread.c
gdb/stabsread.h