public inbox for gdb-prs@sourceware.org
help / color / mirror / Atom feed
From: "vries at gcc dot gnu.org" <sourceware-bugzilla@sourceware.org>
To: gdb-prs@sourceware.org
Subject: [Bug symtab/26243] Handle line number 0 in line table produced by clang
Date: Wed, 15 Jul 2020 22:05:01 +0000	[thread overview]
Message-ID: <bug-26243-4717-DBhnyGTRiL@http.sourceware.org/bugzilla/> (raw)
In-Reply-To: <bug-26243-4717@http.sourceware.org/bugzilla/>

https://sourceware.org/bugzilla/show_bug.cgi?id=26243

--- Comment #6 from Tom de Vries <vries at gcc dot gnu.org> ---
(In reply to Tom de Vries from comment #5)
> (In reply to Andrew Burgess from comment #4)
> > Ignoring line number 0 while parsing is probably not the right answer.  If
> > we do that then instruction associated with line 0 will instead be
> > associated with the preceding line number.
> 

Hmm, I think we probably want the "ignore line number 0" approach for gdb 10,
to fix the regression in behaviour compared to gdb 9.2.  The scenario below
doesn't work with gdb 9.2 either.

> Indeed, I found a scenario where this would make a difference: ni-stepping
> through line 53.
> 
> With trunk I get:
> ...
> (gdb) 
> 0x0000000000400d13      53            if (curr->right) {
> todo.push_back(curr->right); }
> (gdb) 
> 0x0000000000400d18      53            if (curr->right) {
> todo.push_back(curr->right); }
> (gdb) 
> 0x0000000000400d1d in inorder (root=0x6031f0 <node_array>)
> (gdb) 
> 0x0000000000400d21 in inorder (root=0x6031f0 <node_array>)
> (gdb) 
> ...
> 
> But with the patch from comment 1, we have instead:
> ...
> (gdb) 
> 0x0000000000400d13      53            if (curr->right) {
> todo.push_back(curr->right); }
> (gdb) 
> 0x0000000000400d18      53            if (curr->right) {
> todo.push_back(curr->right); }
> (gdb) 
> 0x0000000000400d1d      53            if (curr->right) {
> todo.push_back(curr->right); }
> (gdb) 
> 0x0000000000400d21      53            if (curr->right) {
> todo.push_back(curr->right); }
> (gdb)
> ...

-- 
You are receiving this mail because:
You are on the CC list for the bug.

  parent reply	other threads:[~2020-07-15 22:05 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-07-15 13:11 [Bug symtab/26243] New: " vries at gcc dot gnu.org
2020-07-15 14:31 ` [Bug symtab/26243] " vries at gcc dot gnu.org
2020-07-15 14:36 ` vries at gcc dot gnu.org
2020-07-15 15:09 ` vries at gcc dot gnu.org
2020-07-15 15:20 ` andrew.burgess at embecosm dot com
2020-07-15 15:47 ` vries at gcc dot gnu.org
2020-07-15 22:05 ` vries at gcc dot gnu.org [this message]
2020-07-16 17:59 ` vries at gcc dot gnu.org
2020-07-16 19:18 ` simark at simark dot ca
2020-07-16 20:46 ` palves at redhat dot com
2020-07-16 20:51 ` palves at redhat dot com
2020-07-16 21:18 ` palves at redhat dot com
2020-07-16 22:22 ` palves at redhat dot com
2020-07-17 15:00 ` vries at gcc dot gnu.org
2020-07-20 13:00 ` andrew.burgess at embecosm dot com
2020-07-20 13:15 ` palves at redhat dot com
2020-07-24 22:23 ` cvs-commit at gcc dot gnu.org
2020-07-24 22:33 ` vries at gcc dot gnu.org
2020-09-03  5:19 ` jaydeepchauhan1494 at gmail dot com

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=bug-26243-4717-DBhnyGTRiL@http.sourceware.org/bugzilla/ \
    --to=sourceware-bugzilla@sourceware.org \
    --cc=gdb-prs@sourceware.org \
    /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).