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#42147: 28.0.50; pure vs side-effect-free, missing optimizations? Date: Sun, 05 Jul 2020 17:47:42 +0300 Message-ID: <83a70et3w1.fsf@gnu.org> References: <3A9CC2A3-8307-47B2-8D80-795C0AF020E1@acm.org> <775819003.2516724.1593687594435@mail.yahoo.com> <5F2B4684-34D1-4474-8909-9F435369FE54@acm.org> <705260433.2731607.1593698199171@mail.yahoo.com> <6CF8EE58-9A49-40E7-AA86-48AB39BF94BA@acm.org> <28B19D86-343C-4126-B95F-1F38735F73F2@acm.org> <1288c6a5-545b-f68c-ff6b-7683db3e54c1@cs.ucla.edu> <0AF276D8-FB28-4745-AAE4-DC30E0441F89@acm.org> <793d67e0-68a0-fc53-89a9-0902747d6389@cs.ucla.edu> <83zh8ftfwr.fsf@gnu.org> <672f15b0-04f9-e884-4815-85ca1d1af9bb@cs.ucla.edu> <6d8ba3b1-86b8-3dc8-3d80-17222d436b80@cs.ucla.edu> <83lfjyu1mo.fsf@gnu.org> <4e6f253b-0771-e90d-a24e-4ce1bd5d3a2a@cs.ucla.edu> Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="15452"; mail-complaints-to="usenet@ciao.gmane.io" Cc: pipcet@gmail.com, mattiase@acm.org, monnier@iro.umontreal.ca, andrea_corallo@yahoo.it, 42147@debbugs.gnu.org To: Paul Eggert Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sun Jul 05 16:48:10 2020 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 1js5w9-0003vD-WA for geb-bug-gnu-emacs@m.gmane-mx.org; Sun, 05 Jul 2020 16:48:09 +0200 Original-Received: from localhost ([::1]:40408 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1js5w8-0005RI-Gz for geb-bug-gnu-emacs@m.gmane-mx.org; Sun, 05 Jul 2020 10:48:08 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:34732) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1js5w2-0005RB-F1 for bug-gnu-emacs@gnu.org; Sun, 05 Jul 2020 10:48:02 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:49540) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1js5w2-0000GU-6H for bug-gnu-emacs@gnu.org; Sun, 05 Jul 2020 10:48:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1js5w2-0004pW-3f for bug-gnu-emacs@gnu.org; Sun, 05 Jul 2020 10:48:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 05 Jul 2020 14:48:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 42147 X-GNU-PR-Package: emacs Original-Received: via spool by 42147-submit@debbugs.gnu.org id=B42147.159396047218549 (code B ref 42147); Sun, 05 Jul 2020 14:48:02 +0000 Original-Received: (at 42147) by debbugs.gnu.org; 5 Jul 2020 14:47:52 +0000 Original-Received: from localhost ([127.0.0.1]:32853 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1js5vo-0004p3-4O for submit@debbugs.gnu.org; Sun, 05 Jul 2020 10:47:52 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:48528) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1js5vk-0004op-Ob for 42147@debbugs.gnu.org; Sun, 05 Jul 2020 10:47:46 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]:33516) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1js5ve-0000Cy-C0; Sun, 05 Jul 2020 10:47:38 -0400 Original-Received: from [176.228.60.248] (port=2550 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1js5vd-0005Cf-JA; Sun, 05 Jul 2020 10:47:38 -0400 In-Reply-To: <4e6f253b-0771-e90d-a24e-4ce1bd5d3a2a@cs.ucla.edu> (message from Paul Eggert on Sun, 5 Jul 2020 01:28:46 -0700) 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" Xref: news.gmane.io gmane.emacs.bugs:182740 Archived-At: > Cc: monnier@iro.umontreal.ca, mattiase@acm.org, andrea_corallo@yahoo.it, > 42147@debbugs.gnu.org > From: Paul Eggert > Date: Sun, 5 Jul 2020 01:28:46 -0700 > > On 7/4/20 7:38 PM, Eli Zaretskii wrote: > > > . which other projects use this non-standard instruction set? > > Wait a minute, SSE2 is not "non-standard". It was introduced in 2000 as part of > the evolving Intel/AMD x86 instruction set, and is supported by pretty much > every x86-compatible chip that first shipped after 2003-or-so and that is a > plausible candidate for Emacs. (Stefan's old laptop uses a circa-2001 chip.) That's not what I meant: I meant "non-standard" in the sense that the compiler doesn't generate these instructions by default when dealing with FP calculations. > To get back to your question, many software projects already require SSE2 on > x86. This includes Chromium since build 35 (2014), Firefox since Firefox 53 > (2017), and WebKit2GTK since version 2.24.0 (2019). Since Emacs links to > WebKit2GTK by default, recent Emacs by default already requires SSE2 on x86. > Similarly, many Gnome applications require SSE2 on x86, as they also link to > WebKit2GTK. > > Among proprietary systems, Mac OS X on x86 (2006-2011) always required SSE2, and > MS-Windows development platforms have been requiring SSE2 by default since 2012, > which means pretty much every application built for 32-bit MS-Windows requires > SSE2 nowadays. Also, all supported MS-Windows operating systems have required > SSE2 since 2018, which is when Microsoft pushed out an update for MS-Windows 7 > that required SSE2. Thanks, I knew all that. Emacs is not an OS, it's an application, and the issue here is about using these instructions for FP calculations, not for anything else. That was what I was asking about: applications doing FP math. > > . why didn't GCC folks made SSE2 the default output? > > I suspect they think x86 is on its way out and not worth worrying about. Then why won't we do the same, and simply ignore the issue? We have enough real development and maintenance work on our hands. Making non-trivial change in the code we produce for Emacs, for the benefit of (at best) insignificant speed improvement on a dying platform, while risking breakage for at least some systems, is not a good use of our scarce resources, IMO.