Most editors are built for the average file, and when you open something big, you feel it.
Koi's is designed around the assumption that the file might be large.
Input lag is not acceptable at any file size (work in progress).
That constraint shapes a lot of decisions under the hood that you never see, but you feel the absence of them immediately when a 100k+ line file slows your cursor down.
I pushed this a bit further with progressively larger files.
- 5 million lines: P95 28.9 ms
- 10 million lines: P95 30.4 ms
- 15 million lines: P95 33.0 ms (lexer detached)
- 20 million lines: P95 42.2 ms (lexer detached)
At around 15 million lines, syntax highlighting was a bottleneck, so these larger tests were run with the lexer detached.
Even at 20 million lines, typing remains interactive at around 42 ms P95.
For comparison, other high-performance editors I tested either didn't open or took a very long time to open and became unusable once opened (force quit).
Surprisingly useful for finding bottlenecks!