alistair23-linux/kernel/debug
Jason Wessel 84a0bd5b28 gdbstub: Optimize kgdb's "thread:" response for the gdb serial protocol
The gdb debugger understands how to parse short versions of the thread
reference string as long as the bytes are paired in sets of two
characters.  The kgdb implementation was always sending 8 leading
zeros which could be omitted, and further optimized in the case of
non-negative thread numbers.  The negative numbers are used to
reference a specific cpu in the case of kgdb.

An example of the previous i386 stop packet looks like:
    T05thread:00000000000003bb;

New stop packet response:
    T05thread:03bb;

The previous ThreadInfo response looks like:
    m00000000fffffffe,0000000000000001,0000000000000002,0000000000000003,0000000000000004,0000000000000005,0000000000000006,0000000000000007,000000000000000c,0000000000000088,000000000000008a,000000000000008b,000000000000008c,000000000000008d,000000000000008e,00000000000000d4,00000000000000d5,00000000000000dd

New ThreadInfo response:
    mfffffffe,01,02,03,04,05,06,07,0c,88,8a,8b,8c,8d,8e,d4,d5,dd

A few bytes saved means better response time when using kgdb over a
serial line.

Signed-off-by: Jason Wessel <jason.wessel@windriver.com>
2010-08-05 09:22:19 -05:00
..
kdb sysrq,kdb: Use __handle_sysrq() for kdb's sysrq function 2010-07-21 19:27:07 -05:00
debug_core.c debug_core,kdb: fix kgdb_connected bit set in the wrong place 2010-07-21 19:27:07 -05:00
debug_core.h kgdb: gdb "monitor" -> kdb passthrough 2010-05-20 21:04:24 -05:00
gdbstub.c gdbstub: Optimize kgdb's "thread:" response for the gdb serial protocol 2010-08-05 09:22:19 -05:00
Makefile kdb: core for kgdb back end (1 of 2) 2010-05-20 21:04:20 -05:00