From: Daniel Jacobowitz <drow@mvista.com>
To: Andrew Cagney <ac131313@redhat.com>
Cc: Michal Ludvig <mludvig@suse.cz>,
GDB Patches <gdb-patches@sources.redhat.com>
Subject: Re: [RFA] Artifical dwarf2 debug info
Date: Wed, 18 Dec 2002 10:05:00 -0000 [thread overview]
Message-ID: <20021218153733.GA11738@nevyn.them.org> (raw)
In-Reply-To: <3E0057EB.1080104@redhat.com>
On Wed, Dec 18, 2002 at 11:11:39AM +0000, Andrew Cagney wrote:
> >On Tue, Dec 17, 2002 at 09:23:15AM -0500, Andrew Cagney wrote:
> >
> >>>Ehm ... what's the result regarding to my patch, guys?
> >
> >>
> >>I think pending changes for the most part render the cornerstone of this
> >>patch obsolete. This is because the dwarf2cfi code wont't be called
> >>when the frame doesn't have dwarf2 info -> the case that this code is
> >>trying to handle.
> >>
> >>The idea of being able to create debug info at run time, though, is very
> >>much worth persuing.
> >
> >
> >Eh, I don't agree at all. We'll be calling a function to figure out if
> >the affected PC value has CFI information. Where's that function going
> >to live? In the CFI reader presumably, and it would be the appropriate
> >time to construct fake debug info.
> >
> >I think that Michal's patch would look substantively the same after
> >these pending changes.
>
> Not bits like this (michael, is this actually separate and how does it
> compare to the code identifying a frameless function?)
>
> > CORE_ADDR
> > x86_64_skip_prologue (CORE_ADDR pc)
> > {
> >@@ -863,19 +883,8 @@ x86_64_skip_prologue (CORE_ADDR pc)
> > struct symbol *v_function;
> > CORE_ADDR endaddr;
> >
> >- /* We will handle only functions beginning with:
> >- 55 pushq %rbp
> >- 48 89 e5 movq %rsp,%rbp
> >- */
> >- unsigned char prolog_expect[PROLOG_BUFSIZE] = { 0x55, 0x48, 0x89, 0xe5
> >},
> >- prolog_buf[PROLOG_BUFSIZE];
> >-
> >- read_memory (pc, (char *) prolog_buf, PROLOG_BUFSIZE);
> >-
> >- /* First check, whether pc points to pushq %rbp, movq %rsp,%rbp. */
> >- for (i = 0; i < PROLOG_BUFSIZE; i++)
> >- if (prolog_expect[i] != prolog_buf[i])
> >- return pc; /* ... no, it doesn't. Nothing to skip. */
> >+ if (! x86_64_function_has_prologue (pc))
> >+ return pc;
>
> And I don't think this would be used either. Instead the decision to
> create the FDE would have been made earlier.
That's just code factoring - he broke x86_64_function_has_prologue out
of x86_64_skip_prologue. Or am I missing your point?
You're right, some bits would change. How pending are the other frame
changes - are they really worth him waiting for?
(In respone to "what's the fire" - I know how annoying it is to have to
shelve something and pick it up when you've completely lost the train
of thought that produced it...)
> >@@ -839,6 +785,9 @@ frame_state_for (struct context *context
> > context->lsda = 0;
> >
> > fde = get_fde_for_addr (context->ra - 1);
> >+
> >+ if (fde == NULL)
> >+ fde = guess_generic_fde (context->ra - 1);
> >
> > if (fde == NULL)
> > return;
>
> However, the code masaging would likely be the same, yes.
>
> Andrew
>
> (hmm, bet that context->ra - 1 should be frame_address_in_block (fi))
Probably, but do we have the right frame at that point? Answer is
apparently no. It means the same thing though.
--
Daniel Jacobowitz
MontaVista Software Debian GNU/Linux Developer
next prev parent reply other threads:[~2002-12-18 15:37 UTC|newest]
Thread overview: 33+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-12-14 17:31 Michal Ludvig
2002-12-14 22:53 ` Eli Zaretskii
2002-12-15 11:03 ` Daniel Jacobowitz
2002-12-16 7:28 ` Michal Ludvig
2002-12-16 7:49 ` Daniel Jacobowitz
2002-12-16 9:27 ` Michal Ludvig
2002-12-16 9:54 ` Daniel Jacobowitz
2002-12-16 10:38 ` Eli Zaretskii
2002-12-20 8:43 ` Michal Ludvig
2002-12-20 10:51 ` Eli Zaretskii
2002-12-16 9:25 ` Andrew Cagney
2002-12-16 9:40 ` Daniel Jacobowitz
2002-12-16 10:04 ` Andrew Cagney
2002-12-16 10:17 ` Daniel Jacobowitz
2002-12-16 10:56 ` Andrew Cagney
2002-12-16 11:13 ` Daniel Jacobowitz
2002-12-16 11:34 ` Andrew Cagney
2002-12-16 11:57 ` Daniel Jacobowitz
2002-12-16 12:10 ` Andrew Cagney
2002-12-16 12:42 ` Daniel Jacobowitz
2002-12-17 6:23 ` Michal Ludvig
2002-12-17 6:28 ` Andrew Cagney
2002-12-17 8:42 ` Daniel Jacobowitz
2002-12-18 4:39 ` Andrew Cagney
2002-12-18 10:05 ` Daniel Jacobowitz [this message]
2003-01-02 20:54 ` Andrew Cagney
2003-01-02 21:19 ` Daniel Jacobowitz
2003-01-02 23:05 ` Andrew Cagney
2003-01-02 23:27 ` Daniel Jacobowitz
2003-01-03 0:28 ` Andrew Cagney
2002-12-16 9:46 ` Michal Ludvig
2002-12-16 9:57 ` Andrew Cagney
2002-12-16 10:01 ` Michal Ludvig
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=20021218153733.GA11738@nevyn.them.org \
--to=drow@mvista.com \
--cc=ac131313@redhat.com \
--cc=gdb-patches@sources.redhat.com \
--cc=mludvig@suse.cz \
/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