From: Jan Kratochvil <jan.kratochvil@redhat.com>
To: Michael Snyder <Michael.Snyder@palmsource.com>,
gdb-patches@sourceware.org
Subject: Re: [patch] Cut memory address width
Date: Wed, 27 Sep 2006 18:37:00 -0000 [thread overview]
Message-ID: <20060927183716.GA13279@host0.dyn.jankratochvil.net> (raw)
In-Reply-To: <20060927182211.GB5635@nevyn.them.org>
On Wed, 27 Sep 2006 20:22:11 +0200, Daniel Jacobowitz wrote:
> On Wed, Sep 27, 2006 at 11:20:22AM -0700, Michael Snyder wrote:
> > On Wed, 2006-09-27 at 18:15 +0200, Jan Kratochvil wrote:
> > > Hi,
> > >
> > > `x/x $ebx' on gdb/amd64 debugging inferior/i386 causes Cannot access memory at
> > > address 0xffffce70 (or so) as $ebx is considered `int' and sign-extended to
> > > 64-bit while the resulting address 0xffffffffffffce70 fails to be accessed.
...
> What's interesting is why this behavior is different on x86_64 and
> i386. Where are we doing the sign extension - that's probably where it
> should be fixed, if anywhere.
In such case `paddress' should print full 64-bit addresses.
Currently it is weird as it refuses to access memory while it will show you
that you were accessing 0xffffce70 - the already cut form - it lies.
If you type on i386 gdb that you want to `x/x 0xffffffffffffce70' it works - as
it will cut the address automatically as even the native C compiler would do.
With these two existing behaviors I was feeling it is more expected to cut the
address even for the access. Still I like more the strict forbidding access
and so I would rather like to remove the existing address-cut in `paddress' and
also wherever it exists for the native i386.
Still the current state is inconsistent, no matter which way to go is the right
one.
Regards,
Jan
next prev parent reply other threads:[~2006-09-27 18:37 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-09-27 16:15 Jan Kratochvil
2006-09-27 18:20 ` Michael Snyder
2006-09-27 18:22 ` Daniel Jacobowitz
2006-09-27 18:37 ` Jan Kratochvil [this message]
2006-09-27 18:55 ` Daniel Jacobowitz
2006-09-27 20:19 ` Jim Blandy
2006-09-27 19:01 ` Mark Kettenis
2006-09-28 17:27 ` Jan Kratochvil
2006-10-05 22:26 ` Daniel Jacobowitz
2006-09-27 19:23 ` Jim Blandy
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=20060927183716.GA13279@host0.dyn.jankratochvil.net \
--to=jan.kratochvil@redhat.com \
--cc=Michael.Snyder@palmsource.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