Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Daniel Jacobowitz <drow@mvista.com>
To: Andrew Cagney <ac131313@ges.redhat.com>
Cc: gdb-patches@sources.redhat.com
Subject: Re: [rfc] Query Red Boot's i386 CPU id
Date: Thu, 29 Aug 2002 17:30:00 -0000	[thread overview]
Message-ID: <20020829234544.GB29966@nevyn.them.org> (raw)
In-Reply-To: <3D6D4142.2070007@ges.redhat.com>

On Wed, Aug 28, 2002 at 05:31:46PM -0400, Andrew Cagney wrote:
> Comments on how this was implemented, and what, if anything, could be 
> integrated into GDB, welcome.


> +/* NOTE: cagney/2001-11-17:
> +
> +   This module uses the [remote protocol] target_query ("qCPUID")
> +   method to extract the i386 CPU information.  It then takes that
> +   information and uses it to do a lookup on a local file
> +   ``cpuid-i386''.
> +
> +   Thanks to a botched initial thread query mechanism, using anything
> +   starting with ``qC'' is dangerous.  Since qCPUID does this, it
> +   won't interact well with targets that recognize the exiting ``qC''
> +   query.  Sigh.
> +
> +   One possible alternative to this qCPUID mechanis would be to plant
> +   a CPUID instruction in the target memory, execute it, and then
> +   examine the result.  This probably isn't pratical since it depends
> +   in being able to execute code in the target.
> +
> +   This file adds the command ``info cpu''.  Beware of the existing
> +   commands ``{set,show} {processor,architecture}''.
> +
> +   This file uses a target_post_open_hook() mechanism to hook into the
> +   target open (and report the CPUID on an initial connect).  Per the
> +   comment in the file "target.h", what really should be happening is
> +   a core_gdb_open() function should be calling the hook.  */

That comment is pretty thorough about my concerns :)  Gdbserver doesn't
support qC yet (just realized a moment ago that it probably should). 
But qCPUID really doesn't work with that.  I bet there's deployed
RedBoot stubs that have this problem?

-- 
Daniel Jacobowitz
MontaVista Software                         Debian GNU/Linux Developer


  parent reply	other threads:[~2002-08-29 23:44 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-08-28 15:20 Andrew Cagney
2002-08-29  0:08 ` Eli Zaretskii
2002-08-29 16:01   ` Mark Kettenis
2002-08-29 16:44     ` Daniel Jacobowitz
2002-08-30 12:10     ` Eli Zaretskii
2002-08-30  6:52   ` Michal Ludvig
2002-08-29 17:30 ` Daniel Jacobowitz [this message]
2002-08-30 13:08   ` Andrew Cagney

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=20020829234544.GB29966@nevyn.them.org \
    --to=drow@mvista.com \
    --cc=ac131313@ges.redhat.com \
    --cc=gdb-patches@sources.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