From mboxrd@z Thu Jan 1 00:00:00 1970
Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail
From: Philipp Stephani
Newsgroups: gmane.emacs.devel
Subject: Re: master 64f2c96 2/2: Make a process test faster.
Date: Sat, 9 Jan 2021 19:12:13 +0100
Message-ID:
References: <20210102125533.3832.43853@vcs0.savannah.gnu.org>
<20210102125536.C3FED2094D@vcs0.savannah.gnu.org>
Mime-Version: 1.0
Content-Type: text/plain; charset="UTF-8"
Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214";
logging-data="7661"; mail-complaints-to="usenet@ciao.gmane.io"
Cc: Philipp Stephani , Emacs developers
To: Glenn Morris
Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Sat Jan 09 19:13:26 2021
Return-path:
Envelope-to: ged-emacs-devel@m.gmane-mx.org
Original-Received: from lists.gnu.org ([209.51.188.17])
by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
(Exim 4.92)
(envelope-from )
id 1kyIjt-0001iz-8r
for ged-emacs-devel@m.gmane-mx.org; Sat, 09 Jan 2021 19:13:25 +0100
Original-Received: from localhost ([::1]:33146 helo=lists1p.gnu.org)
by lists.gnu.org with esmtp (Exim 4.90_1)
(envelope-from )
id 1kyIjs-0004SQ-B2
for ged-emacs-devel@m.gmane-mx.org; Sat, 09 Jan 2021 13:13:24 -0500
Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:49780)
by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
(Exim 4.90_1) (envelope-from )
id 1kyIiz-0003zn-1P
for emacs-devel@gnu.org; Sat, 09 Jan 2021 13:12:29 -0500
Original-Received: from mail-ot1-x32f.google.com ([2607:f8b0:4864:20::32f]:33614)
by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128)
(Exim 4.90_1) (envelope-from )
id 1kyIiw-0002e4-BI; Sat, 09 Jan 2021 13:12:28 -0500
Original-Received: by mail-ot1-x32f.google.com with SMTP id b24so13083039otj.0;
Sat, 09 Jan 2021 10:12:25 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
h=mime-version:references:in-reply-to:from:date:message-id:subject:to
:cc; bh=McIAg/65xmnJ8Td0WpEhAU8I464qUCdteDmzIKiFg9I=;
b=oe8TwOVL+nWeR1oOCQ+ALth+xI2qPSBDzbyYho3oOFQzVCJR3fVN2ktfow0OcQ+0QO
s7LMWu8xJnKU4isI8p8KerCI5LixAU6OUyR6rVgpVogSf0OgEgh7aMFqV4HM/wuOdSur
+Xtj5ImVqyahrgjAa80y4VV7EqgdJZr4J4uquLY1lPuqiScAIDVy4Gb1AxIKXTFaIbTK
G9Yhu79DmkbTrzHps8MKcLstQFtgFC1WfXFTGzSOrIt9CRSJ2Hyf6i5zwMDFQ37CpGGA
FeyOQqfhHpokiOVM4KUtYtRJJtobll9sm9haiRnIUE/bDXCoKOyijCZZoZ5A61rA2N/O
SpaQ==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
d=1e100.net; s=20161025;
h=x-gm-message-state:mime-version:references:in-reply-to:from:date
:message-id:subject:to:cc;
bh=McIAg/65xmnJ8Td0WpEhAU8I464qUCdteDmzIKiFg9I=;
b=lq1yLNwSaVd1fR+Bc7BVM1U+nmUbVK6TidVFXFOl1fuCb1FtegpXZvQXwBx0DUVHzq
1zYrl5DHEhCZS2ouJ89uw8Bxk903IP/NCUvpNrp/bTC/otYGFBNnE1+OYmFUCEgGi3N9
ZXxLpOdqUqJE9j1LFgOwkQGdyg7XCFoOt4bcgu7rESw1cpnS//giyrXXMw4fWl8wb2cM
rLwzBo+eiMIC6raSdmN/3c0uS8Y7t7RsilMzE6L1Enbd/1vTpzorMeq8kdmQOB+Nvp+q
g1RFvOF3R/YhgZflG3xfU7eptiwndZDhpMD93/AbimVFMv6c/4ETXtqJVI2Hn75judPq
DezQ==
X-Gm-Message-State: AOAM530DRnPVC/S45SpOZ2sQt1Fk2ytXDySAT9ZyUVXMnd/jwCN3Xl/X
CfjhyjNJhud4GzY8HZkQ8W7I46X8qEhUBVtvmvTBfCSJEcQ=
X-Google-Smtp-Source: ABdhPJz89T50xLK52tIjjlCbPYh5paFx92ZzY2wEQyJt1wnv8y+gU49FVgz5MmcRH7ZpTBW7J6+s+fFx3mohIq1wP44=
X-Received: by 2002:a9d:694a:: with SMTP id p10mr6582753oto.149.1610215944255;
Sat, 09 Jan 2021 10:12:24 -0800 (PST)
In-Reply-To:
Received-SPF: pass client-ip=2607:f8b0:4864:20::32f;
envelope-from=p.stephani2@gmail.com; helo=mail-ot1-x32f.google.com
X-Spam_score_int: -17
X-Spam_score: -1.8
X-Spam_bar: -
X-Spam_report: (-1.8 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1,
DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1,
FREEMAIL_ENVFROM_END_DIGIT=0.25, FREEMAIL_FROM=0.001,
RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001,
SPF_PASS=-0.001 autolearn=ham autolearn_force=no
X-Spam_action: no action
X-BeenThere: emacs-devel@gnu.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: "Emacs development discussions."
List-Unsubscribe: ,
List-Archive:
List-Post:
List-Help:
List-Subscribe: ,
Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org
Original-Sender: "Emacs-devel"
Xref: news.gmane.io gmane.emacs.devel:262810
Archived-At:
Am Fr., 8. Jan. 2021 um 02:38 Uhr schrieb Glenn Morris :
>
>
> It is now unstable, ie mostly passes but sometimes fails.
>
> Ref eg
> https://hydra.nixos.org/build/134561612
> https://hydra.nixos.org/build/134556213
Interesting. I can't see why it would deadlock. There are only 4 possible cases:
1. vfork and exec both succeed. Then the code will immediately close
stdin for cat, causing it to terminate, and accept-process-output
should return immediately after one or two iterations.
2. vfork and exec both fail due to running out of file descriptors.
Then the process object doesn't exist in the first place, and we don't
try to read from it.
3. Some unexpected error (out of memory, executable suddenly vanishes,
...). That should result in a test failure, but no deadlock.
4. vfork succeeds, child setup before exec fails. That's the
interesting case, which I think is happening here: the child tries to
reopen the TTY file, but that fails because of too many open files. In
this case, since make-process waits for exec/exit, the process object
exists, but isn't alive any more. However, in that case
accept-process-output should also return immediately.