Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: "Ulrich Weigand" <uweigand@de.ibm.com>
To: drow@false.org (Daniel Jacobowitz)
Cc: gdb-patches@sourceware.org
Subject: Re: target_find_description question
Date: Thu, 04 Sep 2008 19:17:00 -0000	[thread overview]
Message-ID: <200809041916.m84JGXcr025369@d12av02.megacenter.de.ibm.com> (raw)
In-Reply-To: <20080904121139.GA27200@caradoc.them.org> from "Daniel Jacobowitz" at Sep 04, 2008 08:11:39 AM

Daniel Jacobowitz wrote:

> I suppose the easiest thing to do would be to call
> target_find_description right before handle_inferior_event, and rely
> on target_desc_fetched to prevent duplicate work.

Unfortunately, it turns out this doesn't work.  Or rather, it works
too well: target_find_description is called after the first stop,
and determines target properties -- while the inferior process is
still executing the shell we're using to start up the real inferior!

So it'll detect e.g. a 32-bit inferior because the shell is 32-bit,
even though the real inferior is a 64-bit application ...

I guess we do need to defer target_find_description until after the
real inferior is started.  However, we then have the problem of how
to handle those register/memory accessed in the mean time.

Maybe we can change handle_inferior_event to not do any PC processing
if stop_soon is set?

Bye,
Ulrich

-- 
  Dr. Ulrich Weigand
  GNU Toolchain for Linux on System z and Cell BE
  Ulrich.Weigand@de.ibm.com


  reply	other threads:[~2008-09-04 19:17 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-09-02 23:49 Ulrich Weigand
2008-09-04 12:12 ` Daniel Jacobowitz
2008-09-04 19:17   ` Ulrich Weigand [this message]
2008-09-04 21:52     ` Daniel Jacobowitz
2008-09-04 22:12       ` Pedro Alves
2008-09-04 22:27         ` Pedro Alves
2008-09-05  0:00           ` [patch, rfc] " Ulrich Weigand
2008-09-05  2:40             ` Daniel Jacobowitz
2008-09-05 13:11             ` Pedro Alves
2008-09-06  1:55             ` Joel Brobecker
2008-09-11 16:13             ` Ulrich Weigand

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=200809041916.m84JGXcr025369@d12av02.megacenter.de.ibm.com \
    --to=uweigand@de.ibm.com \
    --cc=drow@false.org \
    --cc=gdb-patches@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