delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2019/06/24/16:16:56

X-Recipient: archive-cygwin AT delorie DOT com
DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id
:list-unsubscribe:list-subscribe:list-archive:list-post
:list-help:sender:from:to:subject:date:message-id:references
:in-reply-to:content-type:content-id:content-transfer-encoding
:mime-version; q=dns; s=default; b=YvzvlMrkqBGa0vN43dMNawublAwcE
OyHyoCI9o6xzG7iof3tiYZiIaF5mU5IpB87g6XNzlDXJ3LMwDof1ePddf6Nc1DQQ
0GXltujozS/0TmIlBH/L8/GBL+a82k0irf1IPA7/uBkK01Hf8QNrx/gnh1Aoji6/
xSU8sAkVysWIMc=
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id
:list-unsubscribe:list-subscribe:list-archive:list-post
:list-help:sender:from:to:subject:date:message-id:references
:in-reply-to:content-type:content-id:content-transfer-encoding
:mime-version; s=default; bh=jIURen8lOHeNYCLjq5rcosWI1m0=; b=f54
dnRSHoPm/QCT++jcBaqe0YDqHyI7rdAOAeNVxjORpakx/79VPbDMlmaLxTA0pd7D
Ph6coe0/XQALJA1Cnbz8/qNgjqeVxS3fdHDs+YXIMGuebujBWMRl/vbOJpg/r4rM
98eicJXy3dx97bfLbc2JNqjiZ3WOQUeN3EvFMqls=
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com
Authentication-Results: sourceware.org; auth=none
X-Spam-SWARE-Status: No, score=-8.1 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_NONE,SPF_HELO_PASS,SPF_PASS autolearn=ham version=3.3.1 spammy=4th, deadlock, acquire, HX-Languages-Length:1003
X-HELO: NAM03-BY2-obe.outbound.protection.outlook.com
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cornell.edu; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=BfXanZgelX2AWOJMhBuirws+ZBtW/H5AUPJAJB8tAK4=; b=VNh5N7YWjkbTUQeHIF43pU8P+k2SJjFjPj8jt1OaPYKZ5va2a3hY/oP3AXHKoqJLph9M5mzOtt5M2p03BQNZpappbyY93431VNFHtbml6u+9VNdJXE3QztBgV0w+Kce8V205ez30z6GSg8fbRBnI9XXJwHMf8QFIsW8s3/f7sG4=
From: Ken Brown <kbrown AT cornell DOT edu>
To: "cygwin AT cygwin DOT com" <cygwin AT cygwin DOT com>
Subject: Re: timerfd deadlock
Date: Mon, 24 Jun 2019 20:15:48 +0000
Message-ID: <c4d32d35-a668-bca9-f783-bc5ee09ba4ff@cornell.edu>
References: <17657e77-6d7c-7367-3e6f-54e2586ed40c AT cornell DOT edu> <20190611085221 DOT GC3520 AT calimero DOT vinschen DOT de>
In-Reply-To: <20190611085221.GC3520@calimero.vinschen.de>
user-agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:60.0) Gecko/20100101 Thunderbird/60.7.2
authentication-results: spf=none (sender IP is ) smtp.mailfrom=kbrown AT cornell DOT edu;
x-ms-oob-tlc-oobclassifiers: OLM:7691;
received-spf: None (protection.outlook.com: cornell.edu does not designate permitted sender hosts)
x-ms-exchange-senderadcheck: 1
MIME-Version: 1.0
X-MS-Exchange-CrossTenant-mailboxtype: HOSTED
X-MS-Exchange-CrossTenant-userprincipalname: ksb2 AT cornell DOT edu
X-IsSubscribed: yes
X-MIME-Autoconverted: from base64 to 8bit by delorie.com id x5OKGcv5010691

On 6/11/2019 4:52 AM, Corinna Vinschen wrote:
> On Jun  7 12:10, Ken Brown wrote:
>> While testing some new pipe code, I'm occasionally seeing a timerfd deadlock:
>> The main thread is stuck in timerfd_tracker::dtor at timerfd.cc:354, waiting for
>> the timerfd thread to close; and the timerfd thread is stuck at timerfd.cc:140,
>> waiting to acquire a mutex that's held by timerfd_tracker::dtor.
> 
> Hmm, I had hoped my current code does not have a deadlock situation
> anymore, but I was wrong, apparently.
> 
> Is there any chance to create an STC?

I haven't been able to create an STC.  The deadlock seems to depend on a rare 
timing fluke, and I've only seen it when running a parallel make on a clean 
emacs tree, with my new pipe code installed.

On the other hand, I think I have a simple fix, which I'll send to 
cygwin-patches.  With this patch, I ran the parallel make 15 times without 
getting the deadlock.  After reverting the patch, I got the deadlock on the 4th run.

Ken

--
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


- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019