Port-powerpc archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
deficiency in PowerPC ptrace(2)
Folks...
While working on a new ELF coredump format for NetBSD, I noticed that
the PowerPC has some deficiencies in the info provided by ptrace(2).
Specifically, ptrace(2) doesn't export all the registers that debuggers
would like to have.
Also, the register information in core dumps is actually more complete
than the register information provided by ptrace(2). Other NetBSD
platforms provide the registers to ptrace(2) and to core dumps in the
same format (which is extremely convenient for debuggers, to say the
least).
I am planning to fix the PowerPC ptrace(2) (while still maintaining
binary compatibility, possible with some other ptrace(2) infrastructure
changes I made last week) to provide register info like so:
struct reg {
register_t r_fixreg[32];
register_t r_srr0; /* PC */
register_t r_srr1; /* MSR */
register_t r_lr;
register_t r_ctr;
register_t r_mq; /* unused on PowerPC */
int r_cr;
int r_xer;
};
...and the registers will appear in that format in ELF core dumps, as well.
(And, yes, I will update gdb to work with both formats, and auto-detect
which format corresponds to PT_GETREGS.)
--
-- Jason R. Thorpe <thorpej%wasabisystems.com@localhost>
Home |
Main Index |
Thread Index |
Old Index