* x86_64 register cache layout
@ 2003-12-12 0:16 Anthony Booker
2003-12-12 0:34 ` Daniel Jacobowitz
0 siblings, 1 reply; 2+ messages in thread
From: Anthony Booker @ 2003-12-12 0:16 UTC (permalink / raw)
To: gdb
Hello gdb,
I am trying to implement a simple remote protocol server for an AMD
Opteron based system. I am happily getting exchanges back and forth,
I'm ignoring a whole bunch of comands but eventually gdb settles down
and says it's attached to the remote process. I can modify memory on
the target and see the effects on the process.
What I'd like to do is have the 'g' command actually provide register
contents, preferably all the registers and preferably the real data. :)
To do this I'll need to find the right packing order for the reply
frame. From my reading so far I believe this is, with a couple of minor
exceptions, the hex string representation of the register cache.
So I follow the bouncing ball and get down to supply_register which
calls register data which uses reg_defs to define the order and length
of entries in the cache.
Now reg_defs seems to be set set_register_cache but I can't find where
that is called. I did attach to a gdbserver and found that the caller
seems to give regs_x86_64 as the initialiser. But I can find neither
hide nor hair of that variable in the gdb source I have and the
gdbserver is sans symbols. So I'm stuffed.
Can anyone help me join the final dot and locate the table?
Thanks for your time.
Anthony Booker
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: x86_64 register cache layout
2003-12-12 0:16 x86_64 register cache layout Anthony Booker
@ 2003-12-12 0:34 ` Daniel Jacobowitz
0 siblings, 0 replies; 2+ messages in thread
From: Daniel Jacobowitz @ 2003-12-12 0:34 UTC (permalink / raw)
To: Anthony Booker; +Cc: gdb
On Thu, Dec 11, 2003 at 04:16:19PM -0800, Anthony Booker wrote:
> Hello gdb,
>
> I am trying to implement a simple remote protocol server for an AMD
> Opteron based system. I am happily getting exchanges back and forth,
> I'm ignoring a whole bunch of comands but eventually gdb settles down
> and says it's attached to the remote process. I can modify memory on
> the target and see the effects on the process.
>
> What I'd like to do is have the 'g' command actually provide register
> contents, preferably all the registers and preferably the real data. :)
>
> To do this I'll need to find the right packing order for the reply
> frame. From my reading so far I believe this is, with a couple of minor
> exceptions, the hex string representation of the register cache.
>
> So I follow the bouncing ball and get down to supply_register which
> calls register data which uses reg_defs to define the order and length
> of entries in the cache.
>
> Now reg_defs seems to be set set_register_cache but I can't find where
> that is called. I did attach to a gdbserver and found that the caller
> seems to give regs_x86_64 as the initialiser. But I can find neither
> hide nor hair of that variable in the gdb source I have and the
> gdbserver is sans symbols. So I'm stuffed.
>
> Can anyone help me join the final dot and locate the table?
Take a look at regformats/reg-x86-64.dat.
--
Daniel Jacobowitz
MontaVista Software Debian GNU/Linux Developer
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2003-12-12 0:34 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-12-12 0:16 x86_64 register cache layout Anthony Booker
2003-12-12 0:34 ` Daniel Jacobowitz
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox