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: Mon, 24 May 2021 10:37:11 +0300 Message-ID: <5754E85B-9840-416B-B9C1-E6B2B1FC0114@gnu.org> References: <831r9xjrho.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="8815"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: K-9 Mail for Android Cc: Alan Third , YAMAMOTO Mitsuharu To: emacs-devel@gnu.org,Aaron Jensen Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Mon May 24 09:37:55 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 1ll59u-0002BW-Pa for ged-emacs-devel@m.gmane-mx.org; Mon, 24 May 2021 09:37:54 +0200 Original-Received: from localhost ([::1]:55786 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1ll59t-00043h-2S for ged-emacs-devel@m.gmane-mx.org; Mon, 24 May 2021 03:37:53 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:38664) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1ll59H-0003Ou-Jk for emacs-devel@gnu.org; Mon, 24 May 2021 03:37:15 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]:58702) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1ll59F-0004SM-Ut; Mon, 24 May 2021 03:37:13 -0400 Original-Received: from [2a02:14f:1fb:57ce::1f5a:dfeb] (port=39978) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1ll59F-0006E6-Hm; Mon, 24 May 2021 03:37:13 -0400 In-Reply-To: Autocrypt: addr=eliz@gnu.org; keydata= mQENBF+pf4UBCAC6vjkWLSAsQpe8YIGKLQzNOJx/IjGtCdFF8uzmO5jmME+SD8ROuJN+t5KXVw58 uzu75EFD0vHTY9e+udJ2gkpuy0NnzkFcbumdLLo2ERKCoSctZZRhzKXI5z5cHxCqW0B2ygHRrRLt oNlGID7bAgcgSViT1ptGqTXO7zGVu4Airok7dNzcPtHgns8GlR5YAFX0TvE6oGd0l2VPghNeVJKJ OjrbfhoDxl3ucFpqbqMH8z9HTLDOFpz8UaYYUdJMi3xX6vwTZxI2sM2RRVLUpZyllAkSMI4lln1O OgazM/62DJUs/rKIHKBnF6h3/qsJUjUYXaAHbrXY26mWllAd536lABEBAAG0I0VsaSBaYXJldHNr aWkgKGVsaXopIDxlbGl6QGdudS5vcmc+iQE4BBMBAgAiBQJfqX+FAhsDBgsJCAcDAgYVCAIJCgsE FgIDAQIeAQIXgAAKCRCRwSYvAeuNOYUQB/4/iIKKOG45ijNaRoTvmJJZMvj1S07WQxEm7c5SHEeE QbLOAxB9vESOV7sLueuN3oqEndtzyYt4x1WTSBmHFF7h5fcCMjBs41siOIp5Sj/xD0Bvaa0IKGCR SZ7PAo8Mq3wgajXpTpn9vxE2PmtzA8KdEE0K1+f9pVAfOpUIcCl44rIxLUW352XG0y7iz6c/O6LB 1deOKMiKFctKO7pBti1dJEm1ImewLH3H8uTbwspLOs3EB8xhsESxmTidnze68HX2jt+2EeMgCdki NU+LWbexQZPfIS7+ZmE06ll0v6+Jy7ZdTkCCRypKWTnW7pIFsq/p4kybV8O/kHSV6B4vvQBfuQEN BF 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:269734 Archived-At: On May 24, 2021 9:51:42 AM GMT+03:00, Aaron Jensen wrote: > On Sun, May 23, 2021 at 8:56 PM Aaron Jensen > wrote: > > > > Here are some interesting profile pictures=2E On the left is emacs -Q > w/ > > display-line-numbers-mode=2E On the right is a partial version of my > > config with some of the things I mentioned before removed=2E Most of > the > > difference between the two comes in the amount of time spent in > > merge_faces=2E My config ends up spending roughly 7=2E5x more time in > > merge_faces (1500ms vs 200ms)=2E What causes that to get slower? >=20 > One thing of note is that emacs -Q has 129 faces for me=2E My config has > anywhere from 600-800 faces depending on what's loaded it looks like=2E > lface_from_face_name_no_resolve does a linear time search for a face > every time it's called=2E It's called over 700k times when I do my > xdisp=2Ec scroll up test=2E merge_faces is called over 150k times, each > time with line-number-current-line or line-number and 0's for face_id > and base_face_id=2E I don't really know what this code is doing at all, > but all of this seems suspect=2E Thoughts? Why does it look suspect to you? Don't you also see the same code called = to process the other faces in the buffer? An Emacs face that is identified by name needs to be converted to the coll= ection of the face's attributes, so that Emacs could merge faces and displa= y them=2E This is what lface_from_face_name does=2E And it does that for = any face specified in the buffer by its symbol=2E So how come addition of = just one face and a few characters which have that face have such a profoun= d effect in your case?