From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: =?utf-8?Q?=C3=93scar_Fuentes?= Newsgroups: gmane.emacs.devel Subject: Re: Time to merge scratch/correct-warning-pos into master, perhaps? Date: Mon, 21 Feb 2022 01:22:08 +0100 Message-ID: <87o831jcgf.fsf@telefonica.net> References: <83v8xt20db.fsf@gnu.org> <83ee4gyzrh.fsf@gnu.org> <83v8xryh4d.fsf@gnu.org> <831qzyzt5t.fsf@gnu.org> <874k4u92gp.fsf@randomsample> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="27965"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux) To: emacs-devel@gnu.org Cancel-Lock: sha1:URuIo6d559dgRy0J9DNIFnY9LUk= Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Mon Feb 21 01:23:02 2022 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 1nLwTl-000745-OJ for ged-emacs-devel@m.gmane-mx.org; Mon, 21 Feb 2022 01:23:01 +0100 Original-Received: from localhost ([::1]:59236 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1nLwTk-000289-Q0 for ged-emacs-devel@m.gmane-mx.org; Sun, 20 Feb 2022 19:23:00 -0500 Original-Received: from eggs.gnu.org ([209.51.188.92]:57648) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nLwT9-0001Ci-4u for emacs-devel@gnu.org; Sun, 20 Feb 2022 19:22:23 -0500 Original-Received: from ciao.gmane.io ([116.202.254.214]:32906) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nLwT7-0008R6-2z for emacs-devel@gnu.org; Sun, 20 Feb 2022 19:22:22 -0500 Original-Received: from list by ciao.gmane.io with local (Exim 4.92) (envelope-from ) id 1nLwT2-00069L-7c for emacs-devel@gnu.org; Mon, 21 Feb 2022 01:22:16 +0100 X-Injected-Via-Gmane: http://gmane.org/ Received-SPF: pass client-ip=116.202.254.214; envelope-from=ged-emacs-devel@m.gmane-mx.org; helo=ciao.gmane.io X-Spam_score_int: -16 X-Spam_score: -1.7 X-Spam_bar: - X-Spam_report: (-1.7 / 5.0 requ) BAYES_00=-1.9, HEADER_FROM_DIFFERENT_DOMAINS=0.249, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=no 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" Xref: news.gmane.io gmane.emacs.devel:286540 Archived-At: Stefan Monnier writes: >> I think I'm just trying to get some sort of handle on how much the code >> has slowed down because of EQ. Obviously, making EQ into a function >> (rather than an inline function) will have distorted things, but it >> seems the easiest way of measuring something at the moment. > > I understand, but it's still going to be hard to figure out what the > result means. Let's say you find that the new non-inlined EQ is 20% > slower than the old non-inlined EQ, what does it tell us about the > inlined versions? > > It's quite possible that more than 50% of the time spent in the > non-inlined EQ is spent in the "function call overhead" (the jumps > themselves, the forced placement into specific registers, the need to > reify a condition code into a boolean stored in a register, the > impossibility to move code around the call to EQ because the compiler > doesn't know it's a pure function, ...)? For those and more reasons it is useless to directly measure changes to small utility functions in complex applications, even to non-inline ones. The results can be highly misleading. If you want to know the impact of such a change, the correct method is to measure representative instances of real-world cases.