From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Dmitry Gutov Newsgroups: gmane.emacs.devel Subject: Re: MPS: optimized build Date: Mon, 6 May 2024 18:16:24 +0300 Message-ID: <695ff4de-11fd-4d73-b044-6c7c3ff37b5f@gutov.dev> References: <86r0efb1nq.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="33943"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Mozilla Thunderbird Cc: emacs-devel@gnu.org, eller.helmut@gmail.com To: Eli Zaretskii , =?UTF-8?Q?Gerd_M=C3=B6llmann?= Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Mon May 06 17:17:24 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 1s405i-0008Zb-Fc for ged-emacs-devel@m.gmane-mx.org; Mon, 06 May 2024 17:17:23 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1s4052-0007Nc-1E; Mon, 06 May 2024 11:16:41 -0400 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 1s404y-0007NC-9w for emacs-devel@gnu.org; Mon, 06 May 2024 11:16:36 -0400 Original-Received: from wfout6-smtp.messagingengine.com ([64.147.123.149]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1s404s-0001vL-GB; Mon, 06 May 2024 11:16:35 -0400 Original-Received: from compute1.internal (compute1.nyi.internal [10.202.2.41]) by mailfout.west.internal (Postfix) with ESMTP id 21DCA1C000BF; Mon, 6 May 2024 11:16:28 -0400 (EDT) Original-Received: from mailfrontend1 ([10.202.2.162]) by compute1.internal (MEProxy); Mon, 06 May 2024 11:16:28 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gutov.dev; h=cc :cc:content-transfer-encoding:content-type:content-type:date :date:from:from:in-reply-to:in-reply-to:message-id:mime-version :references:reply-to:subject:subject:to:to; s=fm2; t=1715008587; x=1715094987; bh=uMsp0rQuy43m63elJesVWaMqmPbnZc52C+0eM6ytJIc=; b= E/xIrP/vyfl6Irc/6kWoU1oJlBKxA1MvQJauPFgvZRPgx3MfBdL3BRBW6SC67Kgm prvhTD73FJTPsgFD79CTBP+4fI/JJnC4a2SPDIxI0FsWMhzAUfB5U/LD5tejf1+j pC4aXUf2GvfmchZ6LNDgf5bmh2niNs8KADfs/mQvDxfAm7vl5QGOT1spI3XK6Jfa qr3H4PsZsc5MfU299QHPaOr19i3NQVBB/8nKi2hNxOe95j/irnNiUh4x8r+2w7dA if6OODr8Qn9w6BNSZ8OrBtcjHuFnyz+l+IVJ3PAvBA0m6EQMf5BMCndYiM+oeEK3 ru5nOtLKVl/DxWeoeqYzng== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-transfer-encoding :content-type:content-type:date:date:feedback-id:feedback-id :from:from:in-reply-to:in-reply-to:message-id:mime-version :references:reply-to:subject:subject:to:to:x-me-proxy:x-me-proxy :x-me-sender:x-me-sender:x-sasl-enc; s=fm3; t=1715008587; x= 1715094987; bh=uMsp0rQuy43m63elJesVWaMqmPbnZc52C+0eM6ytJIc=; b=V FzjPRlnuCeZHB6NLM3IdarrighdxXNc0fYyjVDEZXHAsXMzbjFR/PxuGZWHcmAnT QXHeKJ3EtV4Js1oQgGo6tw5yB5Dgx9ZQ95GkhRVv96FywnuLedwiSBGTlM9yCBdz G/cM8zVXfmf7BOPbQ3v4mhVZo2t9RbFHJT7zQcV791BVoHbw2fffCuB6HGQSbX76 zDb4F0dzZtQLPN7SAobLWr8ILloAZFnULC7vq4FaofcX5OJwdsC8xAkiPu7Tl0Us 1m9s1T23eppidrts/b9nWXE2utQa7JmVMXrYssWF7qC2VjqQujjFs9YkxkRTnu/u 0xjq5Hvmfz7gMAi4IUjhw== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvledrvddviedgkeeiucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurhepkfffgggfuffvvehfhfgjtgfgsehtkeertddtvdejnecuhfhrohhmpeffmhhi thhrhicuifhuthhovhcuoegumhhithhrhiesghhuthhovhdruggvvheqnecuggftrfgrth htvghrnhepgeelfeetkefghfdvhfdtgeevveevteetgeetveegtedthefhudekteehffeu keeknecuvehluhhsthgvrhfuihiivgeptdenucfrrghrrghmpehmrghilhhfrhhomhepug hmihhtrhihsehguhhtohhvrdguvghv X-ME-Proxy: Feedback-ID: i0e71465a:Fastmail Original-Received: by mail.messagingengine.com (Postfix) with ESMTPA; Mon, 6 May 2024 11:16:25 -0400 (EDT) Content-Language: en-US In-Reply-To: <86r0efb1nq.fsf@gnu.org> Received-SPF: pass client-ip=64.147.123.149; envelope-from=dmitry@gutov.dev; helo=wfout6-smtp.messagingengine.com X-Spam_score_int: -27 X-Spam_score: -2.8 X-Spam_bar: -- X-Spam_report: (-2.8 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_LOW=-0.7, SPF_HELO_PASS=-0.001, T_SPF_TEMPERROR=0.01 autolearn=ham autolearn_force=no X-Spam_action: no action 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:318902 Archived-At: On 06/05/2024 14:49, Eli Zaretskii wrote: >> From: Gerd Möllmann >> Cc: Emacs Devel , Eli Zaretskii , >> Helmut Eller >> Date: Mon, 06 May 2024 09:03:48 +0200 >> >> Dmitry Gutov writes: >> >>> On 05/05/2024 09:16, Gerd Möllmann wrote: >>>> In general, but I guess the wish is the father of the thought as we say >>>> here, Emacs seems to be, hm, snappier? Consult, vertico, corfu, ... >>>> completions, even typing text maybe? >>>> Would be interesting to hear from others how they perceive it... >>> >>> I've built the branch and done some measurements with >>> >>> (benchmark-run 5 (project-files (project-current))) >>> >>> and it seems like the same or a little slower with smaller projects >>> (less GC-intensive) and a stable improvement, about 5%, in in a larger >>> one (more GC-intensive). Which seems good. >>> >>> I haven't noticed a particular change in snappiness so far, but then I >>> also don't usually see this problem. >> >> Thanks! >> >> Interesting anecdote, maybe: I think I mentioned that have an Org file >> in which GCs happened so often that it was basically unusable. This Org >> file behaved much much better with MPS. Almost normal. > > Indeed, the comparisons in this case should be against code that > produces a lot of garbage, not against code that is performance-heavy. I think when evaluating the change we would consider two questions: - Does it make non-consing code slower? (Due to more complex object accounting, for example, or expensive parallel scanning). - Does it reduce the time spent in GC when there is indeed garbage to collect. I'd also ask "does it reduce pauses", but this one seems to have been already answered, MPS being a concurrent GC. Though there might have been some locking issues which could induce pauses anyway. My scenario above is actually garbage-heavy (lots of strings generated). And yet the new GC is the same or slightly slower for smaller project scans, but faster on the largest one. Might have to do something with the fact that the current GC's thresholds are in absolute values, not percentiles of any kind.