diff options
author | Riley Bruins <ribru17@hotmail.com> | 2025-01-11 15:44:07 -0800 |
---|---|---|
committer | Christian Clason <ch.clason+github@icloud.com> | 2025-01-12 16:44:24 +0100 |
commit | 3fdc4302415972eb5d98ba832372236be3d22572 (patch) | |
tree | 9993ceaf881d0c6fb77f7a39c1cca3e6fc6a3826 /runtime/doc | |
parent | 40bf23adaf98dc357a59f9524a16e06f990faeaa (diff) | |
download | rneovim-3fdc4302415972eb5d98ba832372236be3d22572.tar.gz rneovim-3fdc4302415972eb5d98ba832372236be3d22572.tar.bz2 rneovim-3fdc4302415972eb5d98ba832372236be3d22572.zip |
perf(treesitter): cache queries strongly
**Problem:** Query parsing uses a weak cache which is invalidated
frequently
**Solution:** Make the cache strong, and invalidate it manually when
necessary (that is, when `rtp` is changed or `query.set()` is called)
Co-authored-by: Christian Clason <c.clason@uni-graz.at>
Diffstat (limited to 'runtime/doc')
-rw-r--r-- | runtime/doc/news.txt | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/runtime/doc/news.txt b/runtime/doc/news.txt index 810f40180a..4f4bfe9ecc 100644 --- a/runtime/doc/news.txt +++ b/runtime/doc/news.txt @@ -294,6 +294,9 @@ PERFORMANCE inflight requests). This greatly improves performance with slow LSP servers. • 10x speedup for |vim.treesitter.foldexpr()| (when no parser exists for the buffer). +• Strong |treesitter-query| caching makes repeat |vim.treesitter.query.get()| + and |vim.treesitter.query.parse()| calls significantly faster for large + queries. PLUGINS |