Mirror of the gdb mailing list
 help / color / mirror / Atom feed
From: Pedro Alves <pedro@codesourcery.com>
To: "Marc Khouzam" <marc.khouzam@ericsson.com>
Cc: gdb@sourceware.org
Subject: Re: Does HEAD support non-stop with 'gdbserver --multi' on Linux?
Date: Tue, 12 May 2009 15:58:00 -0000	[thread overview]
Message-ID: <200905121658.05954.pedro@codesourcery.com> (raw)
In-Reply-To: <6D19CA8D71C89C43A057926FE0D4ADAA076CB70C@ecamlmw720.eamcs.ericsson.se>

On Tuesday 12 May 2009 16:21:48, Marc Khouzam wrote:
> I saw that with non-stop, when doing native linux debugging, there
> is a conscious decision to trigger thread events as soon as possible
> (from a comment of linux-nat.c:linux_handle_extended_wait()).

At the time I added that to linux-nat.c it seemed like a
good idea, but in hindsight, I'm not sure it was.  This has
the potential to generate *a lot* of create/exit event pairs
for no apparent good reason --- consider a program that spawns
a lot of short lived worker threads.  Against remote
targets, this would be even worse, due to extra slowness.

> However, this does not happen when using gdbserver.
> 
> Is this something that is not ready yet, or a bug, or ... ?

This is a remote protocol issue.  The remote protocol does not have
any support for new thread notifications.  GDB only learns about
new threads when they report an event (say one hits a breakpoints),
or when the thread list is explicitly requested.

OOC, how does the eclipse/java debugger behave on such
scenario?  Are short lived threads added/removed from the GUI
even if they don't report a stop event?

-- 
Pedro Alves


  reply	other threads:[~2009-05-12 15:58 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-04-30 19:49 Marc Khouzam
2009-04-30 20:20 ` Pedro Alves
2009-04-30 20:55   ` Marc Khouzam
     [not found]     ` <200904302245.11843.pedro@codesourcery.com>
2009-05-01 18:40       ` Marc Khouzam
2009-05-12 15:23         ` Marc Khouzam
2009-05-12 15:58           ` Pedro Alves [this message]
2009-05-12 16:23             ` Marc Khouzam

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=200905121658.05954.pedro@codesourcery.com \
    --to=pedro@codesourcery.com \
    --cc=gdb@sourceware.org \
    --cc=marc.khouzam@ericsson.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