From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Alan Mackenzie Newsgroups: gmane.emacs.devel Subject: Re: master 289000e: Merge branch 'feature/native-comp' into trunk Date: Mon, 26 Apr 2021 17:11:57 +0000 Message-ID: References: <20210425182508.6CC7C2094D@vcs0.savannah.gnu.org> <831rayktot.fsf@gnu.org> <83v989jmuc.fsf@gnu.org> <83czuhjh0r.fsf@gnu.org> <87eeexm56d.fsf@telefonica.net> Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="30288"; mail-complaints-to="usenet@ciao.gmane.io" Cc: emacs-devel@gnu.org To: =?iso-8859-1?Q?=D3scar?= Fuentes Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Mon Apr 26 19:14:03 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 1lb4o5-0007d4-Av for ged-emacs-devel@m.gmane-mx.org; Mon, 26 Apr 2021 19:14:01 +0200 Original-Received: from localhost ([::1]:32848 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lb4o4-0001jW-93 for ged-emacs-devel@m.gmane-mx.org; Mon, 26 Apr 2021 13:14:00 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:51892) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lb4mG-0000JV-NI for emacs-devel@gnu.org; Mon, 26 Apr 2021 13:12:09 -0400 Original-Received: from colin.muc.de ([193.149.48.1]:41572 helo=mail.muc.de) by eggs.gnu.org with smtp (Exim 4.90_1) (envelope-from ) id 1lb4m8-0000Ei-2L for emacs-devel@gnu.org; Mon, 26 Apr 2021 13:12:08 -0400 Original-Received: (qmail 68842 invoked by uid 3782); 26 Apr 2021 17:11:57 -0000 Original-Received: from acm.muc.de (p4fe15c82.dip0.t-ipconnect.de [79.225.92.130]) (using STARTTLS) by colin.muc.de (tmda-ofmipd) with ESMTP; Mon, 26 Apr 2021 19:11:57 +0200 Original-Received: (qmail 8473 invoked by uid 1000); 26 Apr 2021 17:11:57 -0000 Content-Disposition: inline In-Reply-To: <87eeexm56d.fsf@telefonica.net> X-Submission-Agent: TMDA/1.3.x (Ph3nix) X-Primary-Address: acm@muc.de Received-SPF: pass client-ip=193.149.48.1; envelope-from=acm@muc.de; helo=mail.muc.de X-Spam_score_int: -18 X-Spam_score: -1.9 X-Spam_bar: - X-Spam_report: (-1.9 / 5.0 requ) BAYES_00=-1.9, 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:268493 Archived-At: Hello, Óscar. On Mon, Apr 26, 2021 at 17:33:30 +0200, Óscar Fuentes wrote: > Alan Mackenzie writes: > > I must be doing something differently from these people, but I can't > > identify what. Native compilation just doesn't seem to be working for > > me, yet. How much of a speed up should it give me? Surely more than 5% > > - 10%? > native-comp speeds up Elisp, and even then there are lots of cases where > the change is hardly noticeable. > Let's say your code spends 90% on the C core and 10% on Elisp. If > native-comp brings a 2x speed up, you'll only observe about 5% > improvement. It seems something like that is indeed happening. > C code is opaque to native-comp and puts a hard limit on how much it can > optimize Elisp. Thus I hope that in the future more and more code will > be moved from C to Elisp. Does that make sense? To move time critical code from fast C to slow Lisp, and then optimise it back, partly? > And other areas can benefit too: one thing which IMO has lots of > potential is to native-compile regexps. Again, how would that work? Regexps are already handled in C. How could native compilation of Lisp add anything? -- Alan Mackenzie (Nuremberg, Germany).