delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2020/04/08/14:50:33

X-Recipient: archive-cygwin AT delorie DOT com
DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 636F5388A018
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cygwin.com;
s=default; t=1586371779;
bh=uWvaX1NKgv27jsypg8e13SYDik8jQaLqXMa23gWVGYc=;
h=Subject:To:References:Date:In-Reply-To:List-Id:List-Unsubscribe:
List-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To:Cc:
From;
b=Nc3yC9Nl8ToU7J/TeflOc4jgNTv7Fu1keZjl1HE2RXZUJPSigpkD/N11VWPL63aHe
vKrH+/RKy74qSP/sM9TuAAafrT4owe05/pVqrijYY6PjL4WpHPAt5FWIOU55wsMgxA
8WkYD4ZF/kK8JM6o994Gz1wTXvJpe0RtYU1t03iQ=
X-Original-To: cygwin AT cygwin DOT com
Delivered-To: cygwin AT cygwin DOT com
DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org 53E9E388700F
ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none;
b=LRrSKT/HlnTba4bYV04ZBEhbCNkS/Jtfx+fWUoz0Ou35nJ78/hfPGv7WMWur14XbqXiT1AKkHSgOk6dJovF5MI1vThFkwFJnBK643EcNp9fSJ9AHILGjXLtNCzdHqnQTAIzga1uSnZYk0N9Azrf4UPGKkCFR75a79xRMfCnkbeZanlPqXJZwDLsajMe5TeQSJURvYYI4HY9eQ94DsCQc8l9MzrZellCweGgn+BN2ymhTLetceJbEHiaAERuxxe21mkKQ7rGC4lBv7KZdmQ9dGIP9khNUdSbLP4W2l8fhn+2cuwM2DKeMfaKQc4WJZY68KPxzOf8rajtgntu8YyZoow==
ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com;
s=arcselector9901;
h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck;
bh=Rb43Ha3QJhCYugdxbLi+W8ZIGTRhhTt2PK/rH8CvkXM=;
b=gpUvGxeLfLsS3z0lQ6RphApZwSAcxW0lhufr6ekRq9eCGz6u7rv34pkvuogQATbtQZSfU0CExNseoBKEgn/ZTWU7bmaCXRNs3KTWkAZFrHVGHsoWN0TOx0CffEzWp2RxV3WgmdQbmvZLfR/Xxbwg5OaZywzGf+W8ubkgArWgZKHReCUMTgXMVLFUg3mKkGarbLokLEpEjdp6/HThlsAp+8/E4J3EWXrTyn+1WPx7bn07PW6uRbdMztLMu+bNrZKrIgoAeAAwPbAKP8z+1tJQ5GfIxCVjXNnGAfuwLAhsDtXHQriZhJ4PO0WKJyoOpRm7ZV+KQLVufBwq/mrGYgL8Ww==
ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass
smtp.mailfrom=cornell.edu; dmarc=pass action=none header.from=cornell.edu;
dkim=pass header.d=cornell.edu; arc=none
Subject: Re: Sv: Sv: open descriptor to named pipes sometimes fail
To: sten DOT kristian DOT ivarsson AT gmail DOT com
References: <000701d60cee$ab67e1b0$0237a510$@gmail.com>
<8c868142-2a9b-3644-0760-444125d2143f AT cornell DOT edu>
<001301d60d0b$c9064140$5b12c3c0$@gmail.com>
<345452a5-3c38-4aa6-85ed-78939412c047 AT cornell DOT edu>
<003c01d60d83$07aa3380$16fe9a80$@gmail.com>
<15d63164-7ca5-77e4-c409-5bda9ab4afbd AT cornell DOT edu>
Message-ID: <6b594c91-cf5d-dcbf-20d0-3436afa95cea@cornell.edu>
Date: Wed, 8 Apr 2020 14:49:31 -0400
User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:68.0) Gecko/20100101
Thunderbird/68.6.0
In-Reply-To: <15d63164-7ca5-77e4-c409-5bda9ab4afbd@cornell.edu>
X-ClientProxiedBy: MN2PR16CA0013.namprd16.prod.outlook.com
(2603:10b6:208:134::26) To DM6PR04MB6075.namprd04.prod.outlook.com
(2603:10b6:5:127::31)
MIME-Version: 1.0
X-MS-Exchange-MessageSentRepresentingType: 1
X-Originating-IP: [2604:6000:b407:7f00:2cbc:bb90:84dc:d66a]
X-MS-PublicTrafficType: Email
X-MS-Office365-Filtering-Correlation-Id: b8d72a11-baa6-41d8-4e32-08d7dbed93b4
X-MS-TrafficTypeDiagnostic: DM6PR04MB6202:
X-Microsoft-Antispam-PRVS: <DM6PR04MB62028BB40FD0204AFC5C537BD8C00 AT DM6PR04MB6202 DOT namprd04 DOT prod DOT outlook DOT com>
X-MS-Oob-TLC-OOBClassifiers: OLM:8273;
X-Forefront-PRVS: 0367A50BB1
X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:;
IPV:NLI; SFV:NSPM; H:DM6PR04MB6075.namprd04.prod.outlook.com; PTR:; CAT:NONE;
SFTY:;
SFS:(10019020)(4636009)(39850400004)(136003)(396003)(376002)(346002)(366004)(8676002)(52116002)(186003)(5660300002)(2616005)(86362001)(2906002)(316002)(36756003)(478600001)(81156014)(53546011)(66476007)(8936002)(66556008)(786003)(31686004)(16526019)(66946007)(75432002)(6486002)(4326008)(31696002)(81166007)(6916009);
DIR:OUT; SFP:1102;
Received-SPF: None (protection.outlook.com: cornell.edu does not designate
permitted sender hosts)
X-MS-Exchange-SenderADCheck: 1
X-Microsoft-Antispam: BCL:0;
X-Microsoft-Antispam-Message-Info: jNdL3s/nZCWHMGdj+B/auUoMU39PijlX7V3s8V0eb+5bwlixbS3xvaXLHXy8QYrLQH8Nz2Wya6l34NBcEoLWOCmZKrg7DcMXkazp/qiJHoyc/VA6URnB3QyHdDDVB4jh8n2ZiF57ZG4Y1i+6JoVSOLcw7kedKWyAcQXFoLKk9YPQp/ddY884/YSOistB1HaA6oCNDX/r4DXdzWIaCKCZ/vMOqAYZBlwMF6wCF30OPIUCX/MYIvRpHSk83B/aMPfod+FYC1NF0kG0Y/s/AsWp2QJ4oLX3GBePHEV1Dlx+8fsg9SYiYK3gNUIRZuLp7HhbmWgXo87sDVg3cibd217Bn5P/3vVeWmJ9WbHlcGvnqUiQodykBasVd3F63SgP+dQ8DTT0U+Jyt8Js84AUCMHfvhJbaxhJKkRK49QvCpErPPytXlEFkfgYO5h9HZtJYh7m
X-MS-Exchange-AntiSpam-MessageData: KPUvuz1LNxgmQ0CszJPpuQusV0BBDXQOAv29ojSRwyHb6hWxVwkwJn3nG9+4Y7+J2TNx3d+gCHIvCRhtMuI2GeOjalC9hFWFXSvVn31WjxtSZ5rI4uzFQr049lYF8UbS8Voh/YYnwckCR5m7BUUmFeo3tl0BawmjI9WhDmfw8vQNP3p5ZFca13iPoHkEZJpX/enlH0sNIysbps8a9SLwJg==
X-OriginatorOrg: cornell.edu
X-MS-Exchange-CrossTenant-Network-Message-Id: b8d72a11-baa6-41d8-4e32-08d7dbed93b4
X-MS-Exchange-CrossTenant-OriginalArrivalTime: 08 Apr 2020 18:49:32.9912 (UTC)
X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted
X-MS-Exchange-CrossTenant-Id: 5d7e4366-1b9b-45cf-8e79-b14b27df46e1
X-MS-Exchange-CrossTenant-MailboxType: HOSTED
X-MS-Exchange-CrossTenant-UserPrincipalName: vYL3S7I0czHwvcT9FE1Utz4QQD4CxrARSZ2RkMKYnuud3OPlW/6VhS5FInIflWyNrXCvXsTo0ZwiiricejbgSQ==
X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM6PR04MB6202
X-Spam-Status: No, score=-6.1 required=5.0 tests=BAYES_00, BODY_8BITS,
DKIM_INVALID, DKIM_SIGNED, GIT_PATCH_2, GIT_PATCH_3, KAM_DMARC_STATUS,
MSGID_FROM_MTA_HEADER, SPF_HELO_PASS, SPF_PASS,
TXREP autolearn=ham autolearn_force=no version=3.4.2
X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on
server2.sourceware.org
X-BeenThere: cygwin AT cygwin DOT com
X-Mailman-Version: 2.1.29
List-Id: General Cygwin discussions and problem reports <cygwin.cygwin.com>
List-Unsubscribe: <http://cygwin.com/mailman/options/cygwin>,
<mailto:cygwin-request AT cygwin DOT com?subject=unsubscribe>
List-Archive: <https://cygwin.com/pipermail/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-request AT cygwin DOT com?subject=help>
List-Subscribe: <http://cygwin.com/mailman/listinfo/cygwin>,
<mailto:cygwin-request AT cygwin DOT com?subject=subscribe>
From: Ken Brown via Cygwin <cygwin AT cygwin DOT com>
Reply-To: Ken Brown <kbrown AT cornell DOT edu>
Cc: cygwin <cygwin AT cygwin DOT com>
Errors-To: cygwin-bounces AT cygwin DOT com
Sender: "Cygwin" <cygwin-bounces AT cygwin DOT com>
X-MIME-Autoconverted: from quoted-printable to 8bit by delorie.com id 038Io8xr020761

On 4/8/2020 8:53 AM, Ken Brown via Cygwin wrote:
> On 4/8/2020 4:52 AM, sten DOT kristian DOT ivarsson AT gmail DOT com wrote:
>>> On 4/7/2020 2:38 PM, sten DOT kristian DOT ivarsson AT gmail DOT com wrote:
>>>>> On 4/7/2020 11:10 AM, Kristian Ivarsson via Cygwin wrote:
>>>>>> Opening a (second) descriptor for (blocking) write sometimes fail
>>>>>>
>>>>>> The provided test case sometimes succeed, but quite often fail with
>>>>>> ENOENT (in various indexes)
>>>>>>
>>>>>> I haven't dug deeper to find the underlaying cause yet
>>>>>>
>>>>>> Have anyone experienced this before ?
>>>>>
>>>>> I can't reproduce this on my system.  I changed 1000 to 10000 and
>>>>> then ran your test case 10 times, and it never failed.  I tested both
>>>>> cygwin-3.1.4 and the HEAD of the topic/fifo branch (which I recently
>>>>> force-pushed in case you want to try it).
>>>>>
>>>>> Can you run your test under strace and see if that provides a clue?
>>>>
>>>> I'm running things on a few year old laptop, perhaps with less muscles
>>>> ;-)
>>>>
>>>> With strace it was harder to reproduce, but I could reproduce it (and
>>>> it happen to be the first iteration this time)
>>>
>>> Does this help?
>>>
>>> --- a/winsup/cygwin/fhandler_fifo.cc
>>> +++ b/winsup/cygwin/fhandler_fifo.cc
>>> @@ -624,7 +624,8 @@ fhandler_fifo::open (int flags, mode_t)
>>>                     else
>>>                       goto success;
>>>                   }
>>> -             else if (STATUS_PIPE_NO_INSTANCE_AVAILABLE (status))
>>> +             else if (STATUS_PIPE_NO_INSTANCE_AVAILABLE (status)
>>> +                      | status == STATUS_OBJECT_NAME_NOT_FOUND)
>>>                   continue;
>>>                 else
>>>                   {
>>
>> Did you mean to use the bit-or-operator or the or-operator ?
> 
> The or-operator.  Thanks for catching that.
> 
>> I did
>> ...
>>     else if (STATUS_PIPE_NO_INSTANCE_AVAILABLE (status) || status ==
>> STATUS_OBJECT_NAME_NOT_FOUND)
>> ...
>> and with that change I cannot reproduce the error in the test-program
> 
> Great.  I'll push it to the topic/fifo branch.  For the record, that patch was 
> motivated by your strace output, which showed NtOpenFile failing with status 
> 0xC0000034, which is STATUS_OBJECT_NAME_NOT_FOUND.

This was not a well-thought-out change.  It creates a drastic slow-down.  I'll 
have to find a better solution.

Ken
--
Problem reports:      https://cygwin.com/problems.html
FAQ:                  https://cygwin.com/faq/
Documentation:        https://cygwin.com/docs.html
Unsubscribe info:     https://cygwin.com/ml/#unsubscribe-simple

- Raw text -


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