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.bugs Subject: bug#72692: Emacs 31.05 (40eecd594ac) get SIGSEGV on Linux (Linux 6.6.45 Kde Wayland) Date: Thu, 29 Aug 2024 13:06:07 +0300 Message-ID: <86seunfxtc.fsf@gnu.org> References: <8b1c8e1f-e0b9-4049-888c-3f723e0008a9@gmail.com> <87y14sd07m.fsf@protonmail.com> <86zfp8wlrv.fsf@gnu.org> <87cym4cvyo.fsf@protonmail.com> <86wmkcwj9c.fsf@gnu.org> <867cc6nv7u.fsf@gnu.org> <87v7zq5jap.fsf@protonmail.com> <86v7zqmdo5.fsf@gnu.org> <86bk1gxz1z.fsf@mail.linkov.net> <87a5h030ba.fsf@protonmail.com> <8634mqorkm.fsf@mail.linkov.net> <8634moj27z.fsf@gnu.org> <86seuovcsr.fsf@mail.linkov.net> <86le0gh6uf.fsf@gnu.org> <86a5gwv6k3.fsf@mail.linkov.net> <86frqoh3vg.fsf@gnu.org> <86ikvk4giz.fsf@mail.linkov.net> Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="13102"; mail-complaints-to="usenet@ciao.gmane.io" Cc: pipcet@protonmail.com, execvy@gmail.com, 72692@debbugs.gnu.org To: Juri Linkov , Po Lu Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Thu Aug 29 12:07:55 2024 Return-path: Envelope-to: geb-bug-gnu-emacs@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 1sjc4H-0003By-Pe for geb-bug-gnu-emacs@m.gmane-mx.org; Thu, 29 Aug 2024 12:07:54 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1sjc3b-00030F-MC; Thu, 29 Aug 2024 06:07:12 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1sjc3Y-0002z5-GM for bug-gnu-emacs@gnu.org; Thu, 29 Aug 2024 06:07:09 -0400 Original-Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1sjc3W-0001Aj-S0 for bug-gnu-emacs@gnu.org; Thu, 29 Aug 2024 06:07:08 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=debbugs.gnu.org; s=debbugs-gnu-org; h=References:In-Reply-To:From:Date:To:Subject; bh=T8YDz+h97zYyrKeUvcRsU/oMVo+5QmJbmH7Vi90hJ5w=; b=WtvB+xWs4Bkw3Us6xBGAwzQpzFWefP210RCzQUZ4C3QpA+ywhG5Zkt6eEeePdjVhB95PliUrc6QaHmbWyPOHE2rdQQbRm7o0UhBWiEBtyO2TMt7O8kBnH//UM2cwR4WUEZsdGmp6LZhu5FfpPYzsr6A52L+JzRAmdup18p72R2ccgIAJ7yY3x3PIlFBboLWpzrFQJW2bs/rrc2i28q9RKJqQWjcb5LHfFXAwZJiA1DSOyviPQZCkwWjUDcU5C2Yed/BkG/uHwtfgiQylwu7XTeKUiTH3FOv4lwvU9X8pYiKPb9jROZcOJXtbYdM7bREyopWVP2p7uQGhbIeQcdbv6g==; Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1sjc4P-0001ib-NI for bug-gnu-emacs@gnu.org; Thu, 29 Aug 2024 06:08:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Thu, 29 Aug 2024 10:08:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 72692 X-GNU-PR-Package: emacs Original-Received: via spool by 72692-submit@debbugs.gnu.org id=B72692.17249260376544 (code B ref 72692); Thu, 29 Aug 2024 10:08:01 +0000 Original-Received: (at 72692) by debbugs.gnu.org; 29 Aug 2024 10:07:17 +0000 Original-Received: from localhost ([127.0.0.1]:50497 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1sjc3g-0001hS-RM for submit@debbugs.gnu.org; Thu, 29 Aug 2024 06:07:17 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:54450) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1sjc3c-0001h7-6J for 72692@debbugs.gnu.org; Thu, 29 Aug 2024 06:07:15 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1sjc2c-000183-JP; Thu, 29 Aug 2024 06:06:10 -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=T8YDz+h97zYyrKeUvcRsU/oMVo+5QmJbmH7Vi90hJ5w=; b=Fda8hFeZ4+pv dEbes9/rzueUL6nLHfmkLdavvce15QyG16qLdUFBYI6eY8hnD3TjthhQxTrsjdQ01SuR/vYt/O/XI NFIFzyuNnzqZ97oDswDSfE5n2ciMWhVr/KyELzD3ylvk0JhVMZV+OwIxYFn3sBSqN3csJentO6W1n mz3vDciVfyShz62e+S3OqzG3xE/1zTFuWwcdyQc280H1V/Y0PZsBCCeMXjAzWH8xNLXguX2syT0x6 a5Ktm81rackHJj5BE8JfuIuH6bjjE/RVXbOcO4OYYGMc+R1Jas7m+pAlaEzVqe5RYPnYSlpm6Bny4 e5P8L2UhtiiTwPXcfBTd0g==; In-Reply-To: <86ikvk4giz.fsf@mail.linkov.net> (message from Juri Linkov on Wed, 28 Aug 2024 22:02:44 +0300) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:290917 Archived-At: > From: Juri Linkov > Cc: pipcet@protonmail.com, execvy@gmail.com, 72692@debbugs.gnu.org > Date: Wed, 28 Aug 2024 22:02:44 +0300 > > The breakpoint inside 'if (non_basic_faces_cached)' > is triggered on every character inserted by Pip's recipe. > So the condition in your patch works in this test, > whereas it's never triggered in normal use. Thanks, I've now installed the change in xfaces.c. The fact that we hit that breakpoint for every character bothered me, so I looked into it. It turns out we do that because the test calls set-frame-parameter inside the loop to set the frame's alpha-background parameter. But the value of alpha-background is the same in all the calls: 1.0. So this call is basically a no-op, but gui_set_alpha_background, which is the handler of alpha-background parameter, doesn't check that the value is the same, and not only sets the same value, but also recomputes all the basic faces (on the assumption that alpha-background changed). It also sets the frame's garbaged flag. This is silly, since we are shooting ourselves in the foot by slowing down the following redisplay cycle: it will need to re-realize all the faces and also perform a thorough redisplay of all of the frame's windows. Then I looked at the other handlers of frame parameters, and it turns out almost none of them check that the new value is different, although they all receive the old value as their last argument! Po Lu, is there any reason why frame-parameter handlers for GUI frames should ignore the fact that the new value of a parameter is exactly equal to the old value? Is there some subtle issue here, and if so, does it affect all the parameters or only some? If there's no real reason for this, I think we should teach the handlers to do nothing if the new value is identical to the old one.