From: "H.J. Lu" <hjl.tools@gmail.com>
To: "H.J. Lu" <hjl.tools@gmail.com>, GDB <gdb-patches@sourceware.org>
Subject: Re: PATCH: Add x86 xml files
Date: Sun, 07 Feb 2010 21:55:00 -0000 [thread overview]
Message-ID: <6dc9ffc81002071355h7f89ad5bxd54d9c75dc35a64a@mail.gmail.com> (raw)
In-Reply-To: <20100207214956.GA3528@caradoc.them.org>
On Sun, Feb 7, 2010 at 1:50 PM, Daniel Jacobowitz <dan@codesourcery.com> wrote:
> On Thu, Feb 04, 2010 at 04:00:52PM -0800, H.J. Lu wrote:
>> +<!DOCTYPE feature SYSTEM "gdb-target.dtd">
>> +<feature name="org.gnu.gdb.i386.core">
>
> In addition to Mark's comments:
>
> * The new features will need to be documented in the manual. I'd
> recommend doing that along with the XML files.
I will do that.
> * I can't remember exactly why there are some previously existing
> features with the same name and two possible contents. It seems like
> a better idea to call one of these org.gnu.gdb.x86_64.* (or x86-64 or
> amd64 or whatever).
That is done on purpose so that i386-tdep.c can have
---
/* Get the x86 target description from INFO. We support both
32bit and 64bit if BFD64 is defined. */
tdesc = info.target_desc;
if (! tdesc_has_registers (tdesc))
{
if (info.bfd_arch_info->bits_per_word == 32)
tdesc = tdesc_i386;
else
#ifdef BFD64
tdesc = tdesc_x86_64;
#else
return NULL;
#endif
}
gdb_assert (tdesc_has_registers (tdesc));
/* Get core registers. */
feature_core = tdesc_find_feature (tdesc, "org.gnu.gdb.i386.core");
if (feature_core == NULL)
return NULL;
---
to support both 32bit and 64bit, avoiding unnecessary complication and
code duplication. That is how it is done for PPC/RS6000.
> Otherwise, it seems fine to me.
>
Thanks.
--
H.J.
next prev parent reply other threads:[~2010-02-07 21:55 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-02-05 0:01 H.J. Lu
2010-02-05 0:01 ` H.J. Lu
2010-02-07 21:29 ` Mark Kettenis
2010-02-07 21:50 ` H.J. Lu
2010-02-07 22:43 ` Mark Kettenis
2010-02-07 21:50 ` Daniel Jacobowitz
2010-02-07 21:55 ` H.J. Lu [this message]
2010-02-07 22:23 ` Daniel Jacobowitz
2010-02-07 22:36 ` Mark Kettenis
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=6dc9ffc81002071355h7f89ad5bxd54d9c75dc35a64a@mail.gmail.com \
--to=hjl.tools@gmail.com \
--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