Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Pedro Alves <palves@redhat.com>
To: Tom Tromey <tromey@redhat.com>
Cc: gdb-patches@sourceware.org
Subject: Re: [RFC v2] fix regressions with target-async
Date: Mon, 03 Mar 2014 16:38:00 -0000	[thread overview]
Message-ID: <5314AFEA.8020705@redhat.com> (raw)
In-Reply-To: <87mwh7cks4.fsf@fleche.redhat.com>

On 03/03/2014 04:24 PM, Tom Tromey wrote:
> Pedro> But this looks bogus to me -- it's only reachable if you already
> Pedro> have the target pushed because you're debugging a threaded core,
> Pedro> and then do "attach"...
> 
> FWIW, gdb doesn't recognize multi-threaded core files on the AIX machine
> to which I have access.  It seems that perhaps it is intended to work,
> but neither my branch nor the gdb 7.6 installed on that machine do in
> fact work.

I was wrong on how this was supposedly reachable.  No need for cores.
Does multi-threading support work when debugging live programs?

Looks like the target pushes itself from the new_objfile observer:

static void
new_objfile (struct objfile *objfile)
{
  if (objfile)
    pd_enable ();
  else
    pd_disable ();
}

Say, as a result of "file ...".

So it seems like that would end up pushing the target even
before we had execution.  Then later, an "attach" actually
activates thread debugging (with pd_activate).

linux-thread-db.c has:

  /* Don't attempt to use thread_db on executables not running
     yet.  */
  if (!target_has_registers)
    return 0;

and attempts activation from the inferior_created observer.

It seems to me aix-thread.c should be adjusted to do the same.

-- 
Pedro Alves


  reply	other threads:[~2014-03-03 16:38 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-02-28 17:48 Tom Tromey
2014-02-28 18:18 ` Pedro Alves
2014-02-28 18:26   ` Tom Tromey
2014-02-28 18:51     ` Pedro Alves
2014-02-28 18:54       ` Joel Brobecker
2014-02-28 19:19     ` Tom Tromey
2014-03-03 16:24   ` Tom Tromey
2014-03-03 16:38     ` Pedro Alves [this message]
2014-03-04 14:25       ` Tom Tromey
2014-03-04 15:10         ` Tom Tromey
2014-03-04 15:29           ` Joel Brobecker
2014-03-04 15:33             ` Tom Tromey
2014-03-04 21:25         ` Pedro Alves
2014-03-05  0:13           ` Tom Tromey
2014-03-05  0:14           ` Pedro Alves
2014-03-05 18:56             ` Tom Tromey
2014-03-05 20:38               ` Pedro Alves
2014-03-05 21:33                 ` Tom Tromey
2014-03-06 15:46                   ` Tom Tromey

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=5314AFEA.8020705@redhat.com \
    --to=palves@redhat.com \
    --cc=gdb-patches@sourceware.org \
    --cc=tromey@redhat.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