Re: kgdb support in vanilla 2.6.2

From: George Anzinger
Date: Wed Feb 11 2004 - 20:35:48 EST


Andi Kleen wrote:
On Tue, 10 Feb 2004 13:56:24 -0800
George Anzinger <george@xxxxxxxxxx> wrote:


Problem is that he did it without binutils support. I don't think that's a good
idea because it makes the code basically unmaintainable for normal souls
(it's like writing assembly code directly in hex)

Well, bin utils, at this time, makes it even worse in that it does not support the expression syntax. Also, it is not asm but dwarf2 and it is written in, IMHO, useful macros (not hex :)


The latest binutils should support .cfi_* for i386 too. I don't see much sense
in making the code more ugly just for staying backwards compatible with older versions for the debug case (without CONFIG_DEBUG_INFO it should be compatible though).
You need a fairly new gdb too anyways for it.

Well, yes, the CVS version I mentioned in my patch is needed as I found a bug in the expression analizer. I am NOT trying to say compatable with old tools. I AM trying to do something the CURRENT tools make hard to impossible.

The problem with the gas CFI support is that it does not provide a way to define CFI expressions which are needed to determine if the CFI address should be zero (i.e. the return is to user space) or the current adjusted stack address.

I suppose the open ended .cfi_ thing could be used but it requires that you compute your own sleb128 and uleb128 values. It is also not clear how you tell this thing if you want a word or a half word as the dwarf2 spec requires. More info on this would be very "nice". I really would like to do this with out the dwarf2 macros, but, please understand, one of the main reasons for the effort was to tie off the bottom of the stack and that seems to require an expression capability for the asm code in entry.S.

--
George Anzinger george@xxxxxxxxxx
High-res-timers: http://sourceforge.net/projects/high-res-timers/
Preemption patch: http://www.kernel.org/pub/linux/kernel/people/rml

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/