[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
master 5ad8db88df8: ; * admin/notes/tree-sitter/performance (Experiments
From: |
Yuan Fu |
Subject: |
master 5ad8db88df8: ; * admin/notes/tree-sitter/performance (Experiments): Update. |
Date: |
Thu, 28 Sep 2023 02:43:07 -0400 (EDT) |
branch: master
commit 5ad8db88df8e80e2e00dfb16fa592c793735ff61
Author: Yuan Fu <casouri@gmail.com>
Commit: Yuan Fu <casouri@gmail.com>
; * admin/notes/tree-sitter/performance (Experiments): Update.
---
admin/notes/tree-sitter/performance | 10 ++++++++++
1 file changed, 10 insertions(+)
diff --git a/admin/notes/tree-sitter/performance
b/admin/notes/tree-sitter/performance
index 315a550be34..23f84743ced 100644
--- a/admin/notes/tree-sitter/performance
+++ b/admin/notes/tree-sitter/performance
@@ -13,3 +13,13 @@ range, so you have to update the ranges every time before
parsing. Fortunately, changing ranges doesn’t invalidate incremental
parsing, so there isn’t any performance lost in update ranges
frequently.
+
+* Experiments
+
+Using regexp by default in treesit-simple-indent-rules seems wasteful,
+so I tried replacing all string-match-p to equal in
+treesit-simple-indent-presets, and indent xdisp.c for a comparison.
+Turns out using regexp by default is faster: regexp-based indent took
+45s and equal-based indent took 75s.
+
+I could be missing something, further experiments are welcome.
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- master 5ad8db88df8: ; * admin/notes/tree-sitter/performance (Experiments): Update.,
Yuan Fu <=