[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Tree-sitter navigation time grows as sqrt(line-number)
From: |
JD Smith |
Subject: |
Re: Tree-sitter navigation time grows as sqrt(line-number) |
Date: |
Thu, 17 Aug 2023 08:21:33 -0400 |
Thanks for that, but I’m afraid I haven’t yet had time. 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.
> On Aug 17, 2023, at 6:56 AM, Dmitry Gutov <dmitry@gutov.dev> wrote:
>
> On 17/08/2023 07:01, JD Smith wrote:
>> I’m unclear whether this is fundamental to the tree-sitter parse/tree
>> algorithm, or if the scaling comes from Emacs’ TS implementation. It does
>> vaguely remind me of similar scaling with an old line-numbering algorithm,
>> where lines were always being counted from the beginning of the buffer, so
>> very fast at the front, and very slow near the end.
>
> Have you tried my patch yet?
- Tree-sitter navigation time grows as sqrt(line-number), JD Smith, 2023/08/17
- Re: Tree-sitter navigation time grows as sqrt(line-number), Dmitry Gutov, 2023/08/17
- Re: Tree-sitter navigation time grows as sqrt(line-number), Eli Zaretskii, 2023/08/17
- Re: Tree-sitter navigation time grows as sqrt(line-number),
JD Smith <=
- Re: Tree-sitter navigation time grows as sqrt(line-number), Dmitry Gutov, 2023/08/17
- Re: Tree-sitter navigation time grows as sqrt(line-number), Dmitry Gutov, 2023/08/17
- Re: Tree-sitter navigation time grows as sqrt(line-number), JD Smith, 2023/08/19
- Re: Tree-sitter navigation time grows as sqrt(line-number), Yuan Fu, 2023/08/19
- Re: Tree-sitter navigation time grows as sqrt(line-number), JD Smith, 2023/08/19
- Re: Tree-sitter navigation time grows as sqrt(line-number), Dmitry Gutov, 2023/08/19
- Re: Tree-sitter navigation time grows as sqrt(line-number), Yuan Fu, 2023/08/19
- Re: Tree-sitter navigation time grows as sqrt(line-number), JD Smith, 2023/08/20
- Re: Tree-sitter navigation time grows as sqrt(line-number), Dmitry Gutov, 2023/08/20
- Re: Tree-sitter navigation time grows as sqrt(line-number), Yuan Fu, 2023/08/21