This is the mail archive of the mailing list for the GDB project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: address space support

Doug Evans wrote:

> At Transmeta we had a hack to implement address spaces.   I.e., 
> CORE_ADDR isn't enough to fully describe all the bits of "memory" one 
> might want to examine.  One could do things like "x/x 
> <addr-space-name>:<address>".   Using that we also hacked in support for 
> x86 segments, so one could do "x/x fs:1234".
> We didn't want to maintain a ton of local mods so we took a minimalist 
> route.  Other ways that have been discussed in the past are things like 
> turning CORE_ADDR into a struct:
> typedef struct { int address_space ; OLD_CORE_ADDR address; } NEW_CORE_ADDR;
> or some such (appropriately typed, named, etc.).
> But that's a ton of work, and not necessarily a maintainable way to go 
> (the common case is addresses are just ints).  Hacking CORE_ADDR by 
> putting the address space in the upper bits doesn't necessarily work either.

My current out-of-tree patch to support combined PPU/SPU debugging 
on the Cell/B.E. does use the latter method (encode address space into
the upper bits of CORE_ADDR).  I'd certainly prefer to see a more
generic method supported by core GDB as well ...


  Dr. Ulrich Weigand
  GNU Toolchain for Linux on System z and Cell BE

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]