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: macOS metal rendering engine in mac port Date: Tue, 25 May 2021 20:34:19 +0300 Message-ID: <83h7iqbtus.fsf@gnu.org> References: <5754E85B-9840-416B-B9C1-E6B2B1FC0114@gnu.org> <80A25FCA-2CF4-433F-B82F-4B37ED5BC6DC@gnu.org> <831r9wdrjr.fsf@gnu.org> <83v978ccbc.fsf@gnu.org> <83sg2cc8m7.fsf@gnu.org> <83pmxgc681.fsf@gnu.org> <83mtskc4zl.fsf@gnu.org> <83lf84c4p7.fsf@gnu.org> <83k0nncznr.fsf@gnu.org> <279F3242-E556-42C9-8489-4DD8F538938E@gnu.org> <83bl8zc8ku.fsf@gnu.org> Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="14238"; mail-complaints-to="usenet@ciao.gmane.io" Cc: alan@idiocy.org, mituharu@math.s.chiba-u.ac.jp, emacs-devel@gnu.org To: Aaron Jensen Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Tue May 25 19:40:46 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 1llb2q-0003UE-GL for ged-emacs-devel@m.gmane-mx.org; Tue, 25 May 2021 19:40:44 +0200 Original-Received: from localhost ([::1]:37656 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1llb2p-0004H3-A0 for ged-emacs-devel@m.gmane-mx.org; Tue, 25 May 2021 13:40:43 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:37758) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1llawi-00065J-Fx for emacs-devel@gnu.org; Tue, 25 May 2021 13:34:24 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]:56612) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1llawh-0008OF-Cd; Tue, 25 May 2021 13:34:23 -0400 Original-Received: from 84.94.185.95.cable.012.net.il ([84.94.185.95]:3727 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 1llawf-0006pS-2t; Tue, 25 May 2021 13:34:21 -0400 In-Reply-To: (message from Aaron Jensen on Tue, 25 May 2021 08:35:42 -0700) 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:269872 Archived-At: > From: Aaron Jensen > Date: Tue, 25 May 2021 08:35:42 -0700 > Cc: emacs-devel@gnu.org, Alan Third , > YAMAMOTO Mitsuharu > > > The 17% is about twice what I'd expect, since adding 3 characters to > > each line of xdisp.c enlarges its text by only 9.3%. > > Pure guess here, but it's also making a lot of empty lines non-empty > (14% more). Perhaps that has an added cost somehow? Not AFAIU, but I had so many surprises in this investigation that I no longer believe in my intuition. So who knows, maybe you are right. > > How did you compile Emacs? which compiler and what compiler and linker > > switches? And what kind of CPU do you have there? I'm looking for > > something that could explain why parts of code that should take like > > 20% of the total redisplay time are so dominant in your case. > > clang, with -O2. Specifically these configure flags: > > CFLAGS="-g3 -O2" \ > --disable-silent-rules \ > --with-xml2 \ > --with-gnutls \ > --without-dbus \ > --with-imagemagick \ > --with-modules \ > --with-rsvg \ > --with-ns \ > --disable-ns-self-contained > > > This CPU: Intel(R) Core(TM) i9-9980HK CPU @ 2.40GHz So you have 16 execution units, but a relatively slow clock. Hmm... > > Alan, do you see similar numbers (in percents) to what Aaron reports? > > Or is that something peculiar to his system? > > What I get depends on frame size and whether or not I'm using > nativecomp or Alan's branch or master. I just a test with a smaller > frame size (on Alan's branch this time, just happens to be what I have > built) and saw 5.58 vs 6.8s: 22%. But then I ran the bench again w/ > line numbers and couldn't get it below 7.2s, so there's quite a bit of > variability in the test runs. FWIW, in my case, the default frame size (~37 lines) and a maximized frame produce the same timings here.