From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.devel Subject: Re: master af152ffab1: Don't freeze if the compositing manager crashes Date: Sat, 30 Jul 2022 11:06:26 +0300 Message-ID: <83wnbv58jh.fsf@gnu.org> References: <831qu36std.fsf@gnu.org> <8735ejm6bb.fsf@yahoo.com> Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="36121"; mail-complaints-to="usenet@ciao.gmane.io" Cc: emacs-devel@gnu.org To: Po Lu Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Sat Jul 30 10:09:08 2022 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 1oHhX2-0009HF-1q for ged-emacs-devel@m.gmane-mx.org; Sat, 30 Jul 2022 10:09:08 +0200 Original-Received: from localhost ([::1]:33428 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oHhX0-0006Ca-Or for ged-emacs-devel@m.gmane-mx.org; Sat, 30 Jul 2022 04:09:06 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:55606) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oHhUZ-0005NH-4i for emacs-devel@gnu.org; Sat, 30 Jul 2022 04:06:35 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]:60868) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oHhUY-0006kh-AT; Sat, 30 Jul 2022 04:06:34 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=6IQ4uid25ekL1KbG02D1qoYWHXp4eF+9riFoms6zvTs=; b=aRisjPIsduQv tcldG0Wy4rxS4nKujLvSBGWnHnkWOP5yKTngXC+4y9Ej6uDR49xOXv9cxxLaTKNFxbs83iehYv7TD 0bz/4obgA0U7WIMXdKQrPEof4jk7yoIQrFDpC8N56FqwZJo/eiP/+b6xcnfisgds+pmRDwfdf+38X stsVf3fb71+0griVkXOsZtKAcZLbWkHLzlLifxRjz/W2Da8jK+b3eSpzfYfKarPareheMW3UH7Pi2 d7dosNN+MduTobkTlVJvxYE2eNzubU0LanDaSCvwYTpYDnNXjM8v7z2DrCp8gd/Xkg1vVgzzagfYN teRi2hZs/LosDybgJ1WNPQ==; Original-Received: from [87.69.77.57] (port=1341 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oHhUU-0003MY-Re; Sat, 30 Jul 2022 04:06:31 -0400 In-Reply-To: <8735ejm6bb.fsf@yahoo.com> (message from Po Lu on Sat, 30 Jul 2022 15:02:32 +0800) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.29 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:292856 Archived-At: > From: Po Lu > Cc: emacs-devel@gnu.org > Date: Sat, 30 Jul 2022 15:02:32 +0800 > > Eli Zaretskii writes: > > > There are a few places in Emacs that wait for similar reasons, so my > > suggestion is to do this like they do, i.e. by calling > > wait_reading_process_output. The advantage is that we let other code > > and other threads to run while we wait. > > The problem here is Emacs doesn't just "wait" for an event, it has to > use X(Check)IfEvent to remove that single event from the event queue, in > effect processing it "out-of-order". > > So unfortunately wait_reading_process_output doesn't quite fit the bill > here. Why not?