From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED.blaine.gmane.org!not-for-mail From: Sebastian Sturm Newsgroups: gmane.emacs.devel Subject: Re: State of the overlay branch (again)? Date: Wed, 25 Sep 2019 22:02:18 +0200 Message-ID: <343fb797-6ef8-8e10-1153-394537a93b52@arkona-technologies.de> References: Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Injection-Info: blaine.gmane.org; posting-host="blaine.gmane.org:195.159.176.226"; logging-data="102751"; mail-complaints-to="usenet@blaine.gmane.org" User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.8.0 To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Wed Sep 25 22:03:13 2019 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([209.51.188.17]) by blaine.gmane.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89) (envelope-from ) id 1iDDVI-000QZr-Uh for ged-emacs-devel@m.gmane.org; Wed, 25 Sep 2019 22:03:13 +0200 Original-Received: from localhost ([::1]:56938 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1iDDVH-0007GX-AX for ged-emacs-devel@m.gmane.org; Wed, 25 Sep 2019 16:03:11 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:44675) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1iDDUV-0006lX-HN for emacs-devel@gnu.org; Wed, 25 Sep 2019 16:02:24 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1iDDUU-0007R7-7s for emacs-devel@gnu.org; Wed, 25 Sep 2019 16:02:23 -0400 Original-Received: from smtp-out001.kontent.com ([81.88.40.215]:37210) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1iDDUU-0007P8-17 for emacs-devel@gnu.org; Wed, 25 Sep 2019 16:02:22 -0400 Original-Received: from [192.168.178.34] (dslb-088-068-052-096.088.068.pools.vodafone-ip.de [88.68.52.96]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) (Authenticated sender: arkona-technologies_de_22@smtp-out001.kontent.com) by smtp-out001.kontent.com (Postfix) with ESMTPSA id A2E004001A81 for ; Wed, 25 Sep 2019 22:02:19 +0200 (CEST) In-Reply-To: Content-Language: en-US X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 81.88.40.215 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.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.org gmane.emacs.devel:240291 Archived-At: sure. Opening one of my somewhat larger C++ source files (~2300 lines, which produces close to 4000 semantic highlighting overlays), I repeatedly created new lines using Spacemacs's default 'o' keybinding (I guess vanilla Emacs wouldn't behave differently in this respect though I didn't try). Doing that at different positions within the buffer (while keeping those positions roughly identical from run to run, though both my personal perception and the resulting timing data suggest that position doesn't matter), elp-instrument-function told me that a recent build of emacs 27 (git commit #52172d23401) takes close to half a second to open a single newline (which matches what I'm seeing on screen during editing): Function Name Call Count Elapsed Time Average Time emacs-27: evil-open-below 7 2.877079901 0.4110114144 Removing all overlays using (remove-overlays) while leaving semantic-highlighting enabled (i.e., any new highlights sent by clangd would still be processed and converted into overlays during editing) resulted in the following profile: emacs-27 [overlays cleared]: evil-open-below 7 0.0555971120 0.0079424445 By comparison, this is what I get using the noverlay branch (same file, same number of overlays, 3774): emacs-noverlay: evil-open-below 7 0.058601084 0.0083715834 and, for comparison, with all overlays removed: emacs-noverlay: [overlays cleared]: evil-open-below 9 0.03571364 0.0039681822 On 9/25/19 2:32 PM, Stefan Monnier wrote: >> (https://lists.gnu.org/archive/html/emacs-devel/2018-03/msg00565.html) >> because overlays are heavily used by some implementations of semantic >> highlighting (see emacs-ccls, lsp-mode). > [...] >> If so, is there anything I could do to help speed up the >> merge process? > > I think benchmarks comparing the noverlay branch with master > (especially on those problematic cases) could do wonders to motivate > someone to finish the development&merge (assuming the benchmarks show > that it improves performance significantly, of course). > > > Stefan >