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: Tree-sitter navigation time grows as sqrt(line-number) Date: Thu, 17 Aug 2023 15:34:25 +0300 Message-ID: References: <3E82D409-6903-4679-9031-939CA35791FF@gmail.com> <32507689-3b2c-ccbf-dd14-e7bf0bed1ac7@gutov.dev> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="33469"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.13.0 Cc: emacs-devel@gnu.org To: JD Smith Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Thu Aug 17 14:35:37 2023 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 1qWcDw-0008NA-FS for ged-emacs-devel@m.gmane-mx.org; Thu, 17 Aug 2023 14:35:37 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qWcCz-0001gf-AT; Thu, 17 Aug 2023 08:34:37 -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 1qWcCw-0001gH-ES for emacs-devel@gnu.org; Thu, 17 Aug 2023 08:34:34 -0400 Original-Received: from out3-smtp.messagingengine.com ([66.111.4.27]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qWcCt-00042F-TV for emacs-devel@gnu.org; Thu, 17 Aug 2023 08:34:34 -0400 Original-Received: from compute6.internal (compute6.nyi.internal [10.202.2.47]) by mailout.nyi.internal (Postfix) with ESMTP id 347D25C010B; Thu, 17 Aug 2023 08:34:29 -0400 (EDT) Original-Received: from mailfrontend1 ([10.202.2.162]) by compute6.internal (MEProxy); Thu, 17 Aug 2023 08:34:29 -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:sender:subject:subject:to:to; s=fm2; t= 1692275669; x=1692362069; bh=petZhJDMQ1Hv3bWuafNrz7+l4Qh0LI88U5i aLK41oqs=; b=TBuymWBW2lSzs10Fi3S6kZAO5QmA2VW/nEVkGhqeLYdLbbb+x2W M027fee29HSqj1ZrINAZYGd1QuqzpvcnXfB3AJjONLpt+Ws4iHrqKOodeH7c3j7d Vh3GzsUF7ISQWpagTepseEeR+lIZvir5Wn/ELnsnFjbFEqq9QStrWptF1jqE/eOS k9+qbzrOi9aVpQhUJhbaV6LI9CZuSuyieduwwxNWQ6tB++67tIzz49j12YEjfDjN tGEH7+E87XBDM0dU2+xmOmzjQfvil/xtf1RL7Gh3OTO6SmjJId4wpfDUm8mpT0Ra 0910TfiUYtFx/TcrDXfOaus0VUuWmsbRnIA== 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:sender:subject:subject:to:to:x-me-proxy :x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s=fm1; t= 1692275669; x=1692362069; bh=petZhJDMQ1Hv3bWuafNrz7+l4Qh0LI88U5i aLK41oqs=; b=lR+AV+Nd9TaCTgn53C1hQNmRTefdMpYiohQXFjzBpgw0oOHuVlv zJHGAmgPb76S4lQybWKYzMHU1CPY+GyL2Nkh87tpIHfAAVe+ghG+ox2PfYGHd4l9 /qLGE81oQtBGzTnpoDF2K1FSrFmwM5dm1Zi0v3ORq4ihwToq9WENucwAPFcTvvjT LWPo6xRkDr77cvBLdB6MR1lkDq2lHjZL8CRA5ti7w+jdD5pxnrP1I4Xf1dXEZyrf CB82nUkFnJVg38U6FPmjdbBJSkpwbeNeASPxbg/uKxbGx1Kj0w1Ic7RFM9AHE7Vx zpnoUxiNqzNzwAxfxSsgDJzSLHg2jo4ktxQ== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedviedrudduuddgheefucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurhepkfffgggfuffvvehfhfgjtgfgsehtjeertddtfeejnecuhfhrohhmpeffmhhi thhrhicuifhuthhovhcuoegumhhithhrhiesghhuthhovhdruggvvheqnecuggftrfgrth htvghrnhepiefgteevheevveffheeltdeukeeiieekueefgedugfefgefhudelgfefveel vdevnecuvehluhhsthgvrhfuihiivgeptdenucfrrghrrghmpehmrghilhhfrhhomhepug hmihhtrhihsehguhhtohhvrdguvghv X-ME-Proxy: Feedback-ID: i0e71465a:Fastmail Original-Received: by mail.messagingengine.com (Postfix) with ESMTPA; Thu, 17 Aug 2023 08:34:27 -0400 (EDT) Content-Language: en-US In-Reply-To: Received-SPF: pass client-ip=66.111.4.27; envelope-from=dmitry@gutov.dev; helo=out3-smtp.messagingengine.com X-Spam_score_int: -67 X-Spam_score: -6.8 X-Spam_bar: ------ X-Spam_report: (-6.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, NICE_REPLY_A=-4.01, RCVD_IN_DNSWL_LOW=-0.7, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 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:308859 Archived-At: On 17/08/2023 15:21, JD Smith wrote: > I provided the test code and target file in the hopes that others could confirm the scaling behavior and then experiment with algorithm tweaks, if anything obvious presented itself. I experimented a little bit with benchmarking (treesit-node-parent) calls, and the patch came from that.