Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Daniel Jacobowitz <drow@false.org>
To: Vladimir Prus <vladimir@codesourcery.com>
Cc: gdb-patches@sources.redhat.com
Subject: Re: [RFA] Implement -thread-info.
Date: Fri, 14 Mar 2008 18:04:00 -0000	[thread overview]
Message-ID: <20080314180425.GA31663@caradoc.them.org> (raw)
In-Reply-To: <200803142003.48178.vladimir@codesourcery.com>

On Fri, Mar 14, 2008 at 08:03:47PM +0300, Vladimir Prus wrote:
> > Oh, one other thing.  I went back to look at Denis's patches.  He made
> > -thread-info without an argument describe the current thread only.
> > Doesn't that seem useful, especially before we get notifications
> > completely hammered out?  I do not see any other MI command that
> > reports the current thread.
> > 
> > So that would mean we needed -thread-list-all-threads back again.
> 
> Hmm, I'd rather not. Currently, the current thread is reported by 
> *stopped, and is not supposed to randomly change -- because the
> target is fully stopped while frontend talks with gdb. Therefore,
> using -thread-info as a roundabout way to get the current thread
> does not really give you anything.
> 
> For non-stop mode, I have long and evil plans that I'll post soon,
> but they don't require this either.

I find it strange that -thread-info gives information about multiple
threads, myself.  But this isn't worth arguing about; we'll do it
your way.

> +@{id="1",target-id="Thread 0xb7e156b0 (LWP 21254)",
> +   frame=@{addr="0x0804891f",func="foo",args=[@{name="i",value="10"@}],
> +           file="/tmp/a.c",fullname="/tmp/a.c",line="158"@}@}],

If we're adding the level then please update the example.

>        /* That switch put us at the top of the stack (leaf frame).  */
>        switch_to_thread (tp->ptid);
> -      print_stack_frame (get_selected_frame (NULL), 0, LOCATION);
> +      print_stack_frame (get_selected_frame (NULL), 1, LOCATION);

mi_like_p?  This will print out the #0 in the CLI too.

Otherwise OK.

-- 
Daniel Jacobowitz
CodeSourcery


      reply	other threads:[~2008-03-14 18:04 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-02-17 15:33 Vladimir Prus
2008-02-18  6:26 ` Nick Roberts
2008-02-18  7:38   ` Vladimir Prus
2008-02-18 21:45     ` Nick Roberts
2008-02-20 11:28       ` Vladimir Prus
2008-02-20 19:07         ` Eli Zaretskii
2008-02-20 19:38         ` Nick Roberts
2008-02-20 20:03           ` Vladimir Prus
2008-02-26  0:58         ` Nick Roberts
2008-02-26  1:21           ` Daniel Jacobowitz
2008-03-23  4:56             ` Nick Roberts
2008-03-23  7:38               ` Vladimir Prus
2008-03-23 16:22               ` Daniel Jacobowitz
2008-03-08 15:50           ` Vladimir Prus
2008-03-08 15:55         ` Vladimir Prus
2008-03-08 20:04           ` Nick Roberts
2008-03-10  7:59             ` Vladimir Prus
2008-03-10  9:13               ` Nick Roberts
2008-03-14 10:17           ` Vladimir Prus
2008-03-17 18:40             ` Michael Snyder
2008-03-14 15:08           ` Daniel Jacobowitz
2008-03-14 15:11             ` Daniel Jacobowitz
2008-03-14 17:04               ` Vladimir Prus
2008-03-14 18:04                 ` Daniel Jacobowitz [this message]

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=20080314180425.GA31663@caradoc.them.org \
    --to=drow@false.org \
    --cc=gdb-patches@sources.redhat.com \
    --cc=vladimir@codesourcery.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