Mirror of the gdb mailing list
 help / color / mirror / Atom feed
From: Eli Zaretskii <eliz@is.elta.co.il>
To: Andrew Cagney <ac131313@cygnus.com>
Cc: Kevin Buettner <kevinb@cygnus.com>,
	Naushit_Sakarvadia@quintum.com, gdb@sources.redhat.com
Subject: Re: 8 bit read
Date: Thu, 26 Jul 2001 06:45:00 -0000	[thread overview]
Message-ID: <Pine.SUN.3.91.1010726163652.1520C-100000@is> (raw)
In-Reply-To: <3B60182F.5000504@cygnus.com>

On Thu, 26 Jul 2001, Andrew Cagney wrote:

> > No, because CORE_ADDR is not wide enough to engulf both.  Making
> > CORE_ADDR wider is something I'd prefer to avoid, since it will affect
> > Binutils as well.
> 
> What Kevin is suggesting here is, from GDB's point of view, the correct 
> approach.  A CORE_ADDR is a cannonical address - any pointer expression 
> is converted to that cannonical value.  On the x86, it could carry an 
> indication that the offset part belongs to either code, I/O, .. space.

The problem is, I don't have enough bits in CORE_ADDR to include those 
indications.

> > It means to use a non-default segment selector to read and write
> > memory.
> 
> That really means do a virtual->real address translation on all 
> addresses as they head towards the target.

No, it means converting an offset relative to segment's base to a linear
address.  I don't need to map to a physical address in this case, that's 
something that is done transparently by the CPU, given the page tables 
that are set by the OS.

> The d10v target managed this.  I'd view it as a proof of concept.

If that was done by encoding all the info into CORE_ADDR, I cannot take 
this path, because CORE_ADDR is 32 bits and addresses are also 32 bits.

> If I understand what you're saying correctly, you'd need a virtual 
> (segment:offset) to physical translation somewhere down in the target code.

No, my problem is not a translation--that can be handled by the target 
code.  The problem is how to pass that information to the target code, 
given that it can only be either in the address itself or in the memory 
attributes which go with that address.


  reply	other threads:[~2001-07-26  6:45 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-07-23  9:04 Naushit Sakarvadia
2001-07-23  9:56 ` Daniel Jacobowitz
2001-07-23 11:50 ` Andrew Cagney
2001-07-24  4:49   ` Eli Zaretskii
2001-07-24  9:25     ` Kevin Buettner
2001-07-24 11:11       ` Eli Zaretskii
2001-07-24 14:11         ` Kevin Buettner
2001-07-25  1:45           ` Eli Zaretskii
2001-07-25 11:40             ` Kevin Buettner
2001-07-25 23:39               ` Eli Zaretskii
2001-07-26  6:17                 ` Andrew Cagney
2001-07-26  6:45                   ` Eli Zaretskii [this message]
2001-07-26  6:53                     ` Andrew Cagney
2001-07-26  6:59                       ` Eli Zaretskii
2001-07-26  7:09                         ` Andrew Cagney
2001-07-26  7:01                     ` Andrew Cagney
2001-07-26  9:20                     ` Kevin Buettner
2001-07-26  9:25                       ` Eli Zaretskii

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=Pine.SUN.3.91.1010726163652.1520C-100000@is \
    --to=eliz@is.elta.co.il \
    --cc=Naushit_Sakarvadia@quintum.com \
    --cc=ac131313@cygnus.com \
    --cc=gdb@sources.redhat.com \
    --cc=kevinb@cygnus.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