D10V_MAKE_IADDR / D10V_MAKE_DADDR / GDB_TARGET_IS_D10V
Jim Blandy
jimb@zwingli.cygnus.com
Mon Jul 24 11:03:00 GMT 2000
> One thing that you may want to keep in mind is that it may not just
> be text vs. data. I once wrote a C compiler for a machine that 4
> different pointer formats (pointers to 16-bit words, pointers to
> bytes, and 2 different bit pointers). The original machine in the
> family did not have byte addressing at all, and so when they hacked
> in byte addressability, the byte pointer was the word pointer
> shifted left one bit (losing the top bit, which was an indirection
> bit, and not used for the address itself).
But in all these cases, you must be able to determine the pointer
format from the C type. Otherwise, the * operator doesn't know what
to do when applied to some external pointer variable --- the type is
all the info it has.
So, the conversion macros get the pointer type as an argument --- not
some hacky my-problem-is-the-only-problem data/text flag.
More information about the Gdb-patches
mailing list