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.bugs Subject: bug#59738: c-ts-mode is slow with large buffers. Date: Sun, 11 Dec 2022 18:38:52 +0200 Message-ID: References: <87E351E0-2EE2-434A-9609-86506D2F263D@gmail.com> <83edtb3z6t.fsf@gnu.org> <3A956C88-F81D-4DED-B020-178291D405D9@gmail.com> <83fsdp1vke.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="7108"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.4.2 Cc: Eli Zaretskii , 59738@debbugs.gnu.org To: Alan Mackenzie , Yuan Fu Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sun Dec 11 17:39:19 2022 Return-path: Envelope-to: geb-bug-gnu-emacs@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 1p4PME-0001hv-4S for geb-bug-gnu-emacs@m.gmane-mx.org; Sun, 11 Dec 2022 17:39:18 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1p4PM0-0001eA-Mu; Sun, 11 Dec 2022 11:39:04 -0500 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 1p4PLy-0001de-TS for bug-gnu-emacs@gnu.org; Sun, 11 Dec 2022 11:39:02 -0500 Original-Received: from debbugs.gnu.org ([209.51.188.43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1p4PLy-0003na-LD for bug-gnu-emacs@gnu.org; Sun, 11 Dec 2022 11:39:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1p4PLy-0006Nx-HT for bug-gnu-emacs@gnu.org; Sun, 11 Dec 2022 11:39:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Dmitry Gutov Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 11 Dec 2022 16:39:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 59738 X-GNU-PR-Package: emacs Original-Received: via spool by 59738-submit@debbugs.gnu.org id=B59738.167077674124536 (code B ref 59738); Sun, 11 Dec 2022 16:39:02 +0000 Original-Received: (at 59738) by debbugs.gnu.org; 11 Dec 2022 16:39:01 +0000 Original-Received: from localhost ([127.0.0.1]:46976 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p4PLx-0006Nc-D3 for submit@debbugs.gnu.org; Sun, 11 Dec 2022 11:39:01 -0500 Original-Received: from mail-wr1-f43.google.com ([209.85.221.43]:34474) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p4PLw-0006NW-Jj for 59738@debbugs.gnu.org; Sun, 11 Dec 2022 11:39:00 -0500 Original-Received: by mail-wr1-f43.google.com with SMTP id o5so9727404wrm.1 for <59738@debbugs.gnu.org>; Sun, 11 Dec 2022 08:39:00 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:user-agent:mime-version:date:message-id :sender:from:to:cc:subject:date:message-id:reply-to; bh=LbMEmTGZ3pH4H9nedb6IIk865Fah7LXdMrOaCSwOTB4=; b=Y/KhcZQ8IjHLCBeR8TDYoJxroK2FEkrAE1qdfRRaFOzR/BHhd5/CwAKgX69kAZ/0ty nrywCTfNUy3bIb0y9+fVVvNj3pFh6IqWePa6oLMdLuGi4GLd8A43Gql38eLIc5h8npfi 388ntAFCUmmB4x3x8zmbYZfn1YP6tCaq2SQh+LtvEIAGsPfcGTFbcJzGhj/xx3U2ZKjU Rt2OquJNUPCrCVbyVPH4y9+5jDaGOXwpzFiner97c6wG/94leZ77ooyJajWGh9BYsm2D bVYrjxbE8SLLu0Om6ASDBfYRjPObgJ77F5+q7ax1j96kMsE1n7dbwH8jd3HmzGswpQsV nPQQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:user-agent:mime-version:date:message-id :sender:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=LbMEmTGZ3pH4H9nedb6IIk865Fah7LXdMrOaCSwOTB4=; b=nq1jTGc1e1ZyySjP7nimnBNvgr59CJgTIpy1D7p8HgbxNJxj6wasMzAoRoo9lEX+SY /KIXcc3yAfJtJLYIbdHxlMBnzU9T2FqVdRUvdQ+c8k0/O/sdJ44fMeLL7K/5x328ZeM5 pOJH/w04DcTEDqfxtGfe4fBCORaAE84LJ6Dobq6i4Rexq/lxCf/LyQ/2vy8vBCtPBQZn NEd3wk6ldEhlrUG1UMHMK7QS0C5SxvJlK7Du/eI2ftQyQ+kj6FpKpjrNlLs4iw0RkmjC gK+5DZE1yWr8sHMwobjbkEqStCnLLYBP9zp2ZO/8XJhnayQbP9hPAcD6IK6DU9sDWp9Y Vikg== X-Gm-Message-State: ANoB5pmk8JiSr0YRbByH0HtlQcUq0/BS0Wuqj6zFaHPNN7MSnwDZ4OZx OfEbTsEFvre6/yr6rfuRdsA= X-Google-Smtp-Source: AA0mqf5/KYjkDT0pBhbU7NAyNaW4yiDGxoE8Qa4MAaFSwvsE4bvcVXEQR8laYFzRy+XhKjMCUzCG9w== X-Received: by 2002:a5d:494c:0:b0:242:7a19:b53e with SMTP id r12-20020a5d494c000000b002427a19b53emr7572367wrs.27.1670776734773; Sun, 11 Dec 2022 08:38:54 -0800 (PST) Original-Received: from [192.168.0.2] ([46.251.119.176]) by smtp.googlemail.com with ESMTPSA id d3-20020adfe883000000b002238ea5750csm7819578wrm.72.2022.12.11.08.38.53 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Sun, 11 Dec 2022 08:38:54 -0800 (PST) Content-Language: en-US In-Reply-To: X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:250625 Archived-At: On 11/12/2022 15:22, Alan Mackenzie wrote: >> Though I’ll note that tree-sitter would provide other benefits. I don’t >> know how much time does c-mode spend on analyzing the buffer content >> when user edits it, .... > It's quite a lot. Occasionally, it's enough to make the response appear > a little sluggish. This analysis, time-wise, is less critical than the > time taken for font locking, though. If we test a different scenario (font-locking just one screen-ful, perhaps repeatedly, while the user is typing), which of the steps can take more time in a large buffer?