This is the mail archive of the
mailing list for the Cygwin project.
Re: printf + pthreads+gdb+mintty = hang?
- From: Ryan Johnson <ryan dot johnson at cs dot utoronto dot ca>
- To: cygwin at cygwin dot com
- Date: Wed, 08 May 2013 16:47:46 -0400
- Subject: Re: printf + pthreads+gdb+mintty = hang?
- References: <5189627F dot 3050801 at cs dot utoronto dot ca> <20130508183617 dot GA8072 at ednor dot casa dot cgf dot cx>
On 08/05/2013 2:36 PM, Christopher Faylor wrote:
Hmm. The STC still hangs about 25% of the time (down from ~100%), so
things are improved but not fixed.
On Tue, May 07, 2013 at 04:22:23PM -0400, Ryan Johnson wrote:
Running the attached STC inside gdb hangs (zero CPU util, have to kill
gdb from Task Manager, killing a.exe doesn't cut it).
Compile line used: g++ -Wall -g -mthreads -DBUG bug.cpp
I currently have the following package versions:
The problem seems to be related to threads calling fprintf inside gdb,
it runs fine from the command line, or with printf instead; both fprintf
and printf sometimes trigger "warning: SuspendThread failed. (winerr 6)"
(not sure if that matters).
Known issue? Easy workaround? New bug?
Known, long-standing issue. I put a workaround in the latest snapshot.
Also, when I hit an assertion failure in my code, gdb successfully
breaks in at my breakpoint on abort()---which used to hang---but then
hangs as soon as I say "up 2" to see the actual source of the assertion
failure. Unfortunately, I haven't been able to distill that one down to
a reasonable STC: just arranging for a threaded toy app to call abort
from multiple threads simultaneously doesn't seem to tickle the bug.
Problem reports: http://cygwin.com/problems.html
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple