From: Nils-Christian Kempke via Gdb-patches <gdb-patches@sourceware.org>
To: gdb-patches@sourceware.org
Cc: jinisusan.george@amd.com, tom@tromey.com, aburgess@redhat.com
Subject: [PATCH v4 0/3] Fortran entry and DW_TAG_entry_point
Date: Wed, 13 Jul 2022 13:12:23 +0200 [thread overview]
Message-ID: <20220713111226.2693410-1-nils-christian.kempke@intel.com> (raw)
Hi,
please find attached version 4 of this series. Changes from v3 mainly
try to incorporate Andrew's comments here:
https://sourceware.org/pipermail/gdb-patches/2022-July/190630.html
Changes since v3:
* Patch 1 and 2 were introduced in order to not clutter patch 3 too
much.
* Patch 1 was introduced because of some code duplication in v3. It
outsources some code from dwarf2_get_pc_bounds into a separate function
to make the addition of the entry point handling easier. It should not
contain any functional changes.
* Patch 2 was introduced because, as Andrew noted correctly,
dwarf2_get_pc_bounds was unconditionally writing to some pointer
without checking it being non-null, an error I had replicated in
my own patch. I found it appropriate to make a separate patch for
this change. The assert should only trigger when we are attempting
to dereference a nullptr - which should have killed GDB anyway.
* Patch 3 still contains the addition of the DW_TAG_entry_point. I
rebased it on patch 1 and 2. It relies heavily on patch 1 and its
refactoring. It contains all leftover fixes for Andrew's comments.
Most importantly it now applies GNU coding style in the example and I
changed '__asm__' to 'asm'. I also added the missing use of int_size
in dw2-entry-points.exp.
v1 can be found here:
https://sourceware.org/pipermail/gdb-patches/2022-March/186900.html
v2 can be found here:
https://sourceware.org/pipermail/gdb-patches/2022-April/187853.html
v3 can be found here:
https://sourceware.org/pipermail/gdb-patches/2022-July/190556.html
This was tested against regressions on Ubuntu 20 x86_64 with the boards
unix, unix/-m32, native-gdbserver, and native-extended-gdbserver.
Thanks,
Nils
Nils-Christian Kempke (3):
gdb, dwarf: move part of dwarf2_get_pc_bounds into separate function
gdb, dwarf: add assert to dwarf2_get_pc_bounds
dwarf, fortran: add support for DW_TAG_entry_point
gdb/dwarf2/abbrev.c | 1 +
gdb/dwarf2/cooked-index.h | 3 +-
gdb/dwarf2/index-write.c | 3 +-
gdb/dwarf2/read.c | 132 +++++++++--
gdb/testsuite/gdb.dwarf2/dw2-entry-points.c | 43 ++++
gdb/testsuite/gdb.dwarf2/dw2-entry-points.exp | 215 ++++++++++++++++++
gdb/testsuite/gdb.fortran/entry-point.exp | 84 +++++++
gdb/testsuite/gdb.fortran/entry-point.f90 | 67 ++++++
8 files changed, 524 insertions(+), 24 deletions(-)
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
next reply other threads:[~2022-07-13 11:13 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-07-13 11:12 Nils-Christian Kempke via Gdb-patches [this message]
2022-07-13 11:12 ` [PATCH v4 1/3] gdb, dwarf: move part of dwarf2_get_pc_bounds into separate function Nils-Christian Kempke via Gdb-patches
2022-07-13 11:12 ` [PATCH v4 2/3] gdb, dwarf: add assert to dwarf2_get_pc_bounds Nils-Christian Kempke via Gdb-patches
2022-07-13 11:12 ` [PATCH v4 3/3] dwarf, fortran: add support for DW_TAG_entry_point Nils-Christian Kempke via Gdb-patches
2022-07-15 19:56 ` Tom Tromey
2022-08-08 16:52 ` Kempke, Nils-Christian via Gdb-patches
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=20220713111226.2693410-1-nils-christian.kempke@intel.com \
--to=gdb-patches@sourceware.org \
--cc=aburgess@redhat.com \
--cc=jinisusan.george@amd.com \
--cc=nils-christian.kempke@intel.com \
--cc=tom@tromey.com \
/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