lkml.org 
[lkml]   [2001]   [Apr]   [28]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Subjectjust-in-time debugging?
From
Date
Is there a way (kernel or userspace... doesn't matter) that gdb/ddd
could be invoked when a program is about
to dump core, or perhaps on a certain signal (that the app could deliver
to itself when required). The latter case
is what I need right now, as I have to debug an app that breaks
seemingly randomly & I need to halt when
certain assertions fail. Core dumps aren't much use as you can't resume
them, otherwise I'd just force a segfault
or something.

I had a look at the do_coredump stuff and it looks like it could be
altered to call gdb in the same way that
modprobe gets called by kmod... however I don't sufficiently know the
code to work out whether it'd work properly
or not.

A patch to glibc would perhaps be better, but I know that code even
less!

Something like responding to SIGTRAP would probably be ideal.

Tony

--

"Two weeks before due date, the programmers work 22 hour days cobbling an
application from... (apparently) one programmer bashing his face into the
keyboard." -- Dilbert

tmh@magenta-netlogic.com http://www.nothing-on.tv

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

\
 
 \ /
  Last update: 2005-03-22 12:52    [W:0.062 / U:1.344 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site