public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Davide Libenzi <davidel@xmailserver.org>
To: Tony Hoyle <tmh@nothing-on.tv>
Cc: linux-kernel@vger.kernel.org
Subject: RE: just-in-time debugging?
Date: Sat, 28 Apr 2001 14:06:14 -0700 (PDT)	[thread overview]
Message-ID: <XFMail.20010428140614.davidel@xmailserver.org> (raw)
In-Reply-To: <20010428210013.625F6F6E1@mail.cvsnt.org>


On 28-Apr-2001 Tony Hoyle wrote:
> On 28 Apr 2001 13:44:48 -0700, Davide Libenzi wrote:
>> Sorry but why don't You run Your application with gdb ?
>> Once Your program crashes You'll get the prompt and You'll be able to
>> stack-trace and watching whatever You need.
>> The solution I use to be able to get inside the program even when the gdb is
>> not running is the one that You can find in the attached file.
>> Basically it install the handler that will create a script file that You can
>> use to automatically enter with gdb inside Your program while it's running.
> 
> 
> 
> Because the program is invoked as part of a much larger system & I don't
> 
> know which process is going to crash when.  
> 
> Having gdb come up automatically would greatly decrease development
> time.  I'm trying to track down multiple bugs (caused by me, but they
> still need tracking down) which show up during stress testing.  The bug
> will manifest itself in maybe the 1000th iteration...   If I could hack
> gdb into coming up automatically when things went wrong it'd get rid of
> the need to have thousands of printf's in the app (which is my primary
> debugging tool at the moment).
> 
> At work I do this all the time... Windows pops up a dialog which
> basically says 'the program has crashed, debug?' and drops you straight
> into VC with everything intact.  It has assertion macros which wrap int3
> instructions.  You then continue your app under normal debug conditions.

Just check the code I sent, it works fine for Your needs.



- Davide


  reply	other threads:[~2001-04-28 21:05 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-04-28 20:17 just-in-time debugging? Tony Hoyle
2001-04-28 20:44 ` Davide Libenzi
2001-04-28 21:00   ` Tony Hoyle
2001-04-28 21:06     ` Davide Libenzi [this message]
2001-05-01  7:25 ` Sean Hunter
  -- strict thread matches above, loose matches on Subject: below --
2001-04-28 20:42 Dan Kegel

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=XFMail.20010428140614.davidel@xmailserver.org \
    --to=davidel@xmailserver.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=tmh@nothing-on.tv \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox