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: Should native compilation be enabled by default? Date: Tue, 05 Mar 2024 14:24:06 +0200 Message-ID: <86zfvclvdl.fsf@gnu.org> References: <86sf19p0hw.fsf@gnu.org> Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="11260"; mail-complaints-to="usenet@ciao.gmane.io" Cc: emacs-devel@gnu.org To: rms@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Tue Mar 05 13:25:44 2024 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 1rhTrb-0002cO-16 for ged-emacs-devel@m.gmane-mx.org; Tue, 05 Mar 2024 13:25:43 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rhTqo-0005QV-4Z; Tue, 05 Mar 2024 07:24:54 -0500 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 1rhTqk-0005Pm-KW for emacs-devel@gnu.org; Tue, 05 Mar 2024 07:24:50 -0500 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 1rhTqk-0005By-97 for emacs-devel@gnu.org; Tue, 05 Mar 2024 07:24:50 -0500 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=DpDV2ThOzB4nTBxpb88cwtUK8hoNx2A1ZFsNyu4SahI=; b=ofdIrWqtFE/s JB2eP7mQIR7eyBO/z6zrdpAydSifdqqmmg0y3aIfJ5bfw6ar2H3IN3GTEzcsvo59vf6La7tlpzQbV Hc12vs7j46PWQ0JICX6D+vmEyk/gcmAZyC1CvZP0G4EJZaA48mzZB089wCcyGI34kPg8FjGyuRsax rl5adaS8Hj6t5RZfYIJ1toUwZZFgZeM4a4AEfVvn3WeYibq8eYnSSXsS+btSnW1Uog8Q9XPGkuGt5 AHOzT05bWOsszFKw0yWGS3IhhpOhZjFWsFwGc6GFPSAKcmg9V/eEWi9JAnM1ZvZ6abC20+VcZbdYi 6mHbTSbSw+4oaXOD6Yv6zg==; In-Reply-To: (message from Richard Stallman on Mon, 04 Mar 2024 22:42:32 -0500) 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-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.devel:316822 Archived-At: > From: Richard Stallman > Cc: emacs-devel@gnu.org > Date: Mon, 04 Mar 2024 22:42:32 -0500 > > > > Enabling native compilation has disadvantages as well as advantages. > > > What are the disadvantages? > > If Emacs compilation by default causes native compilation, it will be > slower. This is true, but the slowdown is IME insignificant on a reasonably modern system. And if Emacs is installed from a distro (which AFAIU is what most users do nowadays), the slowdown doesn't exist at all, because the *.eln files come prebuilt with the binaries. > It will also be more fragile. Byte-compilation is a self-contained > Emacs feature, and aside from occasional bugs that affect specific > code, it never breaks. On general principles we can see that native > compilation is likely to go wrong because something has disappeared, > or because of bugs in other programs that you wouldnt otherwise ever > use. That was a valid consideration when native compilation was first added to Emacs 28. Which is why we kept it off by default for 2 major releases. Now we have enough experience to tell that the problems, such as they were, are all but solved, and native compilation is nowadays no more fragile than byte compilation, what with all the improvements and optimizations introduced lately into the byte compiler. > Native compilation is useful mainly for power users who want > to run Lisp programs that normally are too slow. I disagree, based on my experience. I see a significant speedup when using Rmail for just reading email, something that I cannot characterize as "power use" of Emacs. Even restarting a large Emacs session by restoring from a desktop file is noticeably faster. I don't think having a lot of buffers in a long-running session qualifies me as a "power user" just because of this factor. And there are other significant speed advantages. > The people who participate in emacs-devel tend to be power users. > What they think is not a good guide to what is useful for most users. > To find that out, we should poll the users. Which is why we didn't decide on the default before collecting a lot of experience and processing the bug reports we had about the related issues. Having solved them, I think we can be quite sure users aren't unhappy with native compilation, quite the contrary.