Mirror of the gdb mailing list
 help / color / mirror / Atom feed
From: Mark Mitchell <mark@codesourcery.com>
To: law@cygnus.com
Cc: gdb@sourceware.cygnus.com, gcc@gcc.gnu.org
Subject: Re: More than one stabn for the same PC
Date: Mon, 29 Nov 1999 22:37:00 -0000	[thread overview]
Message-ID: <19991129223717L.mitchell@codesourcery.com> (raw)
In-Reply-To: <27496.943925188@upchuck>

>>>>> "Jeffrey" == Jeffrey A Law <law@cygnus.com> writes:

    Jeffrey> Though I am curious, how does this happen?

We tend to do this with inlining.  (We're doing it more with
inlining-on-trees, but we used to do it anyhow.)  Consider:

  int i;
  inline int f () {  
    i = 3;
  }
  void g() {
    f();
  }

In `g' we first emit a line note for the line with the curly brace for
`g', then emit a line note for the line with `i = 3' in it.  I think
that's roughly the right thing, but the debugger gets confused.

--
Mark Mitchell                   mark@codesourcery.com
CodeSourcery, LLC               http://www.codesourcery.com
From law@cygnus.com Mon Nov 29 23:10:00 1999
From: Jeffrey A Law <law@cygnus.com>
To: Mark Mitchell <mark@codesourcery.com>
Cc: gdb@sourceware.cygnus.com, gcc@gcc.gnu.org
Subject: Re: More than one stabn for the same PC 
Date: Mon, 29 Nov 1999 23:10:00 -0000
Message-id: <28295.943945638@upchuck>
References: <19991129223717L.mitchell@codesourcery.com>
X-SW-Source: 1999-q4/msg00362.html
Content-length: 899

  In message < 19991129223717L.mitchell@codesourcery.com >you write:
  > >>>>> "Jeffrey" == Jeffrey A Law <law@cygnus.com> writes:
  > 
  >     Jeffrey> Though I am curious, how does this happen?
  > 
  > We tend to do this with inlining.  (We're doing it more with
  > inlining-on-trees, but we used to do it anyhow.)  Consider:
  > 
  >   int i;
  >   inline int f () {  
  >     i = 3;
  >   }
  >   void g() {
  >     f();
  >   }
  > 
  > In `g' we first emit a line note for the line with the curly brace for
  > `g', then emit a line note for the line with `i = 3' in it.  I think
  > that's roughly the right thing, but the debugger gets confused.
Looking at that I'd claim only one of the line notes should exist (probably
the one of the "i = 3" statement.

But it may be the case that our opinions about what constitutes sane debugging
information for inline function calls differs.
jeff


  parent reply	other threads:[~1999-11-29 22:37 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1999-11-29 16:59 Mark Mitchell
     [not found] ` <27496.943925188@upchuck>
1999-11-29 22:37   ` Mark Mitchell [this message]
     [not found]     ` <28295.943945638@upchuck>
1999-11-29 23:25       ` Mark Mitchell
1999-11-29 23:54         ` Timothy J. Wood

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=19991129223717L.mitchell@codesourcery.com \
    --to=mark@codesourcery.com \
    --cc=gcc@gcc.gnu.org \
    --cc=gdb@sourceware.cygnus.com \
    --cc=law@cygnus.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