public inbox for gdb-patches@sourceware.org
 help / color / mirror / Atom feed
From: Kevin Buettner <kevinb@redhat.com>
To: Nils-Christian Kempke <nils-christian.kempke@intel.com>
Cc: gdb-patches@sourceware.org, jinisusan.george@amd.com,
	Bernhard Heckel <bernhard.heckel@intel.com>,
	Tim Wiederhake <tim.wiederhake@intel.com>
Subject: Re: [PATCH v2 1/1] dwarf, fortran: add support for DW_TAG_entry_point
Date: Thu, 14 Apr 2022 15:05:28 -0700	[thread overview]
Message-ID: <20220414150528.256d3c07@f35-zws-1> (raw)
In-Reply-To: <20220414094108.2758482-2-nils-christian.kempke@intel.com>

On Thu, 14 Apr 2022 11:41:08 +0200
Nils-Christian Kempke <nils-christian.kempke@intel.com> wrote:

> Fortran provides additional entry points for subroutines and functions.
> These entry points may use only a subset (or a different set) of the
> parameters of the original subroutine.  The entry points may be described
> via the DWARF tag DW_TAG_entry_point.
> 
> This commit adds support for parsing the DW_TAG_entry_point DWARF tag.
> Currently, between ifx/ifort/gfortran, only ifort is actually emitting
> this tag.  Both, ifx and gfortran use the DW_TAG_subprogram tag as
> workaround/alternative.  Thus, this patch really only adds more ifort
> support.  Even so, some of the attached tests still fail for ifort, due
> to some wrong line info generated for the entry points in ifort.
> 
> After this patch it is possible to set a breakpoint in gdb with the
> ifort compiled example at the entry points 'foo' and 'foobar', which was not
> possible before.
> 
> As gcc and ifx do not emit the tag I also added a test to gdb.dwarf2
> which uses some underlying c compiled code and adds some Fortran style DWARF
> to it emitting the DW_TAG_entry_point.  Before this patch it was not
> possible to actually define breakpoint at the entry point tags.
> 
> For gfortran there actually exists a bug on bugzilla, asking for the use
> of DW_TAG_entry_point over DW_TAG_subprogram:
> 
> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=37134
> 
> This patch was originally posted here
> 
> https://sourceware.org/legacy-ml/gdb-patches/2017-07/msg00317.html
> 
> but its review/pinging got lost after a while.  I reworked it to fit the
> current GDB.
> 
> Co-authored-by: Bernhard Heckel <bernhard.heckel@intel.com>
> Co-authored-by: Tim Wiederhake  <tim.wiederhake@intel.com>
> 
> Signed-off-by: Nils-Christian Kempke <nils-christian.kempke@intel.com>

Okay.

(Thanks for adding the new test!)

Kevin


  reply	other threads:[~2022-04-14 22:05 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-04-14  9:41 [PATCH v2 0/1] Fortran entry and DW_TAG_entry_point Nils-Christian Kempke
2022-04-14  9:41 ` [PATCH v2 1/1] dwarf, fortran: add support for DW_TAG_entry_point Nils-Christian Kempke
2022-04-14 22:05   ` Kevin Buettner [this message]
2022-04-15 15:27   ` Tom Tromey
2022-05-12 10:38     ` Kempke, Nils-Christian
2022-05-26 17:34       ` Tom Tromey
2022-07-06 15:30         ` Kempke, Nils-Christian
2022-04-19 11:53 ` [PATCH v2 0/1] Fortran entry and DW_TAG_entry_point George, Jini Susan

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=20220414150528.256d3c07@f35-zws-1 \
    --to=kevinb@redhat.com \
    --cc=bernhard.heckel@intel.com \
    --cc=gdb-patches@sourceware.org \
    --cc=jinisusan.george@amd.com \
    --cc=nils-christian.kempke@intel.com \
    --cc=tim.wiederhake@intel.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;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).