[lldb-dev] FreeBSD thread abort from pthread_cond_timedwait call within signal handler

Ed Maste emaste at freebsd.org
Wed Jun 19 06:17:03 PDT 2013


On 18 June 2013 21:02,  <jingham at apple.com> wrote:
> Note, the Driver's Interrupt IO handler tries to be a little better, calling Process::AsyncInterrupt which just sends an eBroadcastBitInterrupt event to the process.  Note, however, that this actually requires a bunch more work than should be done in a signal handler (lock the event mutex, and new up an Event, putting it in a std::vector, etc.)  But we might get away with that on FreeBSD more easily.  I checked in that change, see if that gets you any further.

Thanks Jim, with that change I no longer abort upon hitting ^C, and if
I launch a 'sleep 60' hitting ^C brings me back to an lldb prompt.

If I back out some later fixes in my tree to reproduce the original
case and hit ^C lldb doesn't respond.  I think this is just a side
effect of a bug in the FreeBSD ProcessMonitor though, where the
inferior has terminated already but lldb hasn't been notified.




More information about the lldb-dev mailing list