PERFORCE change 64659 for review

Marcel Moolenaar marcel at xcllnt.net
Mon Nov 8 18:17:29 PST 2004


On Nov 8, 2004, at 5:50 PM, Peter Wemm wrote:

> http://perforce.freebsd.org/chv.cgi?CH=64659
>
> Change 64659 by peter at peter_daintree on 2004/11/09 01:49:57
>
> 	converge towards i386.  I don't understand this stuff.

==== //depot/projects/hammer/sys/amd64/amd64/gdb_machdep.c#4 (text+ko) 
====

gdb_cpu_getreg() returns the storage location of the
value for the requested register and FOR THE CURRENT THREAD.
The storage location can be NULL, meaning that the register
is not accessable (when not saved for example). This fact is
passed on to kgdb(1) so that "info registers" shows values for
registers that were saved and "*not available*" or something
along those lines for registers that weren't saved (rather
than a bogus value).

In any case, the storage location is the PCB by default, but can
be the trapframe when the thread that the user is looking at in
kgdb(1) and represented by kdb_thread happens to be the thread
that entered the debugger. One should not have to worry about it
in (hopefully) most cases, because a PCB is constructed from the
trapframe, but this doesn't always pan out so nicely.

-- 
  Marcel Moolenaar         USPA: A-39004          marcel at xcllnt.net



More information about the p4-projects mailing list