From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 32691 invoked by alias); 20 Jan 2013 05:23:22 -0000 Received: (qmail 32680 invoked by uid 22791); 20 Jan 2013 05:23:20 -0000 X-SWARE-Spam-Status: No, hits=-0.7 required=5.0 tests=AWL,BAYES_00,DKIM_ADSP_CUSTOM_MED,FREEMAIL_FROM,KHOP_THREADED,NML_ADSP_CUSTOM_MED,RCVD_IN_DNSWL_NONE,RCVD_NUMERIC_HELO,RP_MATCHES_RCVD,SPF_HELO_PASS,TW_CG X-Spam-Check-By: sourceware.org Received: from plane.gmane.org (HELO plane.gmane.org) (80.91.229.3) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Sun, 20 Jan 2013 05:23:14 +0000 Received: from list by plane.gmane.org with local (Exim 4.69) (envelope-from ) id 1TwnNQ-0001x6-5b for cygwin@cygwin.com; Sun, 20 Jan 2013 06:23:28 +0100 Received: from 118.45.149.239 ([118.45.149.239]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sun, 20 Jan 2013 06:23:28 +0100 Received: from jojelino by 118.45.149.239 with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sun, 20 Jan 2013 06:23:28 +0100 To: cygwin@cygwin.com From: jojelino Subject: Re: deadlock with busy waiting on sigfe Date: Sun, 20 Jan 2013 05:23:00 -0000 Message-ID: References: <20130116014646.GB13175@ednor.casa.cgf.cx> <20130116021414.GA14341@ednor.casa.cgf.cx> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit User-Agent: Mozilla/5.0 (Windows NT 5.2; rv:21.0) Gecko/20100101 Thunderbird/21.0a1 In-Reply-To: <20130116021414.GA14341@ednor.casa.cgf.cx> X-IsSubscribed: yes Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner@cygwin.com Mail-Followup-To: cygwin@cygwin.com X-SW-Source: 2013-01/txt/msg00282.txt.bz2 On 2013-01-16 AM 11:14, Christopher Faylor wrote: > On Tue, Jan 15, 2013 at 08:46:46PM -0500, Christopher Faylor wrote: > Sorry, the backtraces were actually useful because they show that you > are apparently running cygwin-snapshot-20130107. Apparently you haven't > been watching the discussion about this issue in the Cygwin list. The > problem of a Cygwin process hanging after a single CTRL-C should be > fixed in later snapshots although there is another reported CTRL-C > issue. > > cgf > now i found hang where the argument of program was sed s/^\(.*\)-\([^-]*-[^-]*\)$/\2/ with newer cygwin snapshot. (gdb) thread apply all bt Thread 4 (Thread 12972.0x382c): #0 0x7c95a22a in ntdll!DbgBreakPoint () from /cygdrive/c/WINDOWS/system32/ntdll.dll #1 0x7c97fc68 in ntdll!DbgUiRemoteBreakin () from /cygdrive/c/WINDOWS/system32/ntdll.dll #2 0x00000005 in ?? () #3 0x00000001 in ?? () #4 0x003effd0 in ?? () Backtrace stopped: previous frame inner to this frame (corrupt stack?) Thread 2 (Thread 12972.0x32c8): #0 0x7c96845c in ntdll!KiFastSystemCallRet () from /cygdrive/c/WINDOWS/system32/ntdll.dll #1 0x7c9678c9 in ntdll!ZwSetInformationThread () from /cygdrive/c/WINDOWS/system32/ntdll.dll #2 0x7c8324f9 in SetThreadPriority () from /cygdrive/c/WINDOWS/system32/kernel32.dll #3 0x6108760b in yield () at /netrel/src/cygwin-snapshot-20130118-1/winsup/cygwin/miscfuncs.cc:244 #4 0x610d6ee4 in _cygtls::lock() () from /usr/bin/cygwin1.dll #5 0x6103035e in sigpacket::setup_handler (this=0x6cac34, handler=0x6102fe30 , siga=..., tls=0x22ce64) ---Type to continue, or q to quit--- at /netrel/src/cygwin-snapshot-20130118-1/winsup/cygwin/exceptions.cc:796 #6 0x61031a48 in sigpacket::process (this=0x6cac34) at /netrel/src/cygwin-snapshot-20130118-1/winsup/cygwin/exceptions.cc:1274 #7 0x610dd2dc in wait_sig () at /netrel/src/cygwin-snapshot-20130118-1/winsup/cygwin/sigproc.cc:1389 #8 0x61003ea5 in cygthread::callfunc (this=0x6118b400 , issimplestub=) at /netrel/src/cygwin-snapshot-20130118-1/winsup/cygwin/cygthread.cc:51 #9 0x6100442f in cygthread::stub (arg=0x6118b400 ) at /netrel/src/cygwin-snapshot-20130118-1/winsup/cygwin/cygthread.cc:93 #10 0x6100538d in _cygtls::call2 (this=, func=0x610043e0 <_ZN9cygthread4stubEPv@4>, arg=0x6118b400 , buf=0x6100551b <_cygtls::call(unsigned long (*)(void*, void*), void*)+91>) at /netrel/src/cygwin-snapshot-20130118-1/winsup/cygwin/cygtls.cc:99 #11 0x006cffb8 in ?? () #12 0x7c82484f in KERNEL32!GetModuleHandleA () from /cygdrive/c/WINDOWS/system32/kernel32.dll #13 0x00000000 in ?? () Thread 1 (Thread 12972.0x2f38): #0 0x7c96845c in ntdll!KiFastSystemCallRet () from /cygdrive/c/WINDOWS/system32/ntdll.dll #1 0x7c9678c9 in ntdll!ZwSetInformationThread () ---Type to continue, or q to quit--- from /cygdrive/c/WINDOWS/system32/ntdll.dll #2 0x7c8324f9 in SetThreadPriority () from /cygdrive/c/WINDOWS/system32/kernel32.dll #3 0x6108764d in yield () at /netrel/src/cygwin-snapshot-20130118-1/winsup/cygwin/miscfuncs.cc:253 #4 0x610d6dcc in _sigfe () from /usr/bin/cygwin1.dll #5 0x61083a40 in mallinfo () at /netrel/src/cygwin-snapshot-20130118-1/winsup/cygwin/malloc_wrapper.cc:2 6 #6 0x6123e9a0 in saved_categories () from /usr/bin/cygwin1.dll #7 0x00000000 in ?? () (gdb) (gdb) x 7ffdd000+4 0x7ffdd004: 0x00230000 (gdb) x ((_cygtls*)(0x00230000-319c))->stackptr 0x22da30: 0x61083ac9 (gdb) i line *0x61083ac9 Line 290 of "/netrel/src/cygwin-snapshot-20130118-1/winsup/cygwin/malloc_wrapper .cc" starts at address 0x61083ac9 and ends at 0x61083ad3 . It seems that malloc_init called sigfe-annotated malloc or free during wait_sig thread tried to process exit signal. -- Regards. -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple