Subject: Re: Kernel Debugging / kgdb support
To: None <Havard.Eidnes@runit.sintef.no, thorpej@nas.nasa.gov>
From: Ross Harvey <ross@ghs.com>
List: port-alpha
Date: 01/13/2000 17:23:25
> From: Jason Thorpe <thorpej@nas.nasa.gov>
>
> On Wed, 29 Dec 1999 19:05:44 +0100 
>  Havard.Eidnes@runit.sintef.no wrote:
>
>  > > It is possible to debug kernel crash dumps w/ gdb, though it can't
>  > > backtrace over trap frames properly (gdb doesn't understand them).
>  > 
>  > Is there hope of this being fixed eventually, or are the trap frames
>  > processor-variant-specific (which would make this more difficult, I
>  > assume)?
>
> It's possible to fix; look at alpha/alpha/db_trace.c.  Someone just has
> to do it.

I dimly recall a recent mention of a ddb(4) traceback-over-trap problem.

I would be interested in reports of problems with ddb(4) in -current or in
any snap or build from 11/99 and later.

This is because, AFAIK, the ddb(4) traceback has been *perfect* in traversing
trap and interrupt frames. It's hard to provoke machine checks, so those
didn't get tested, but they are supposed to work as well.

If you have a repeatable test case and another build machine, you might
try fixing it yourself.  The traceback code is fairly small and clean.

Now, gdb is another story. It has no concept of trap frames,  and locore.s
has some hand stabs that, at one point, worked a bit, sometimes. It really
needs to be fixed in gdb. Unfortunately, the technique used by ddb(4)
doesn't translate well to gdb, but if anyone wants to work on it I will
spell out what's required.

	ross