[PATCH v2 0/1] Fortran entry and DW_TAG_entry_point
Nils-Christian Kempke
nils-christian.kempke@intel.com
Thu Apr 14 09:41:07 GMT 2022
Hi,
please find attached v2 of this series. It introduced the handling
of DW_TAG_entry_point to GDB.
I want to emphasize again - between gfortran, ifort, and ifx only
ifort seems to currently emit this tag. So the attached test only
really works when using ifort. After a comment from Kevin I now added
a gdb.dwarf2 test for GDB's handling of this tag such that it can be
tested without the availablity of a compiler emitting it.
V1 can be found here, it was originally submitted as [RFC]:
https://sourceware.org/pipermail/gdb-patches/2022-March/186900.html
Changes since v1:
* I rebased to master and removed the partial symbol stuff from
this patch since this part has been reworked recently. I hope I
adapted to the changes correctly.
* I added the handling of a DW_TAG_entry_points prefix in
'determine_prefix' (after Jini pointing out a bug here).
* I removed an if that checked for fortran as the cu's language
in new_symbol and made the handling of DW_TAG_entry_point
language agnostic.
* I changed the return type of 'dwarf2_get_pc_bounds_entry_point'
to also return PC_BOUNDS_RANGES if the parent die returns these.
* I added a gdb.dwarf2 test to be able to check this test even
when one does not have ifort at hand. The new test compiles
some .c helper with some labels and uses that to put some
entry point dwarf on top. It then checks whether we can break
at the entry points.
Cheers!
Nils
Nils-Christian Kempke (1):
dwarf, fortran: add support for DW_TAG_entry_point
gdb/dwarf2/abbrev.c | 1 +
gdb/dwarf2/read.c | 72 ++++++++-
gdb/testsuite/gdb.dwarf2/dw2-entry-points.c | 39 +++++
gdb/testsuite/gdb.dwarf2/dw2-entry-points.exp | 149 ++++++++++++++++++
gdb/testsuite/gdb.fortran/entry-point.exp | 84 ++++++++++
gdb/testsuite/gdb.fortran/entry-point.f90 | 67 ++++++++
6 files changed, 411 insertions(+), 1 deletion(-)
create mode 100644 gdb/testsuite/gdb.dwarf2/dw2-entry-points.c
create mode 100644 gdb/testsuite/gdb.dwarf2/dw2-entry-points.exp
create mode 100644 gdb/testsuite/gdb.fortran/entry-point.exp
create mode 100644 gdb/testsuite/gdb.fortran/entry-point.f90
--
2.25.1
Intel Deutschland GmbH
Registered Address: Am Campeon 10, 85579 Neubiberg, Germany
Tel: +49 89 99 8853-0, www.intel.de <http://www.intel.de>
Managing Directors: Christin Eisenschmid, Sharon Heck, Tiffany Doon Silva
Chairperson of the Supervisory Board: Nicole Lau
Registered Office: Munich
Commercial Register: Amtsgericht Muenchen HRB 186928
More information about the Gdb-patches
mailing list