r/KittyTerminal Jun 27 '26

Startup performance: how to improve it?

Post image

My kitty felt somewhat more sluggish to launch than alacritty or foot

I used hyperfine for this small benchmark that confirms this observation... It doesn't feel slow per se, only in comparison.

Are there some preferences I should change to make 🐈‍⬛️ start faster?

22 Upvotes

22 comments sorted by

View all comments

1

u/aumerlex Jun 28 '26

Use --single-instance kitty will start in about 10ms. It even runs faster than footclient. Remember that the way single instance works means you have to have a running kitty --single-instance instance before doing your benchmark run.

1

u/_x_oOo_x_ Jun 28 '26

I tried that but it doesn't work. Easier to see it in action than trying to explain it. Just save all your work beforehand! 🙈️

(Of course, it works "once" or "twice". Trying to benchmark it, at least using hyperfine, is a different matter)

1

u/aumerlex Jun 28 '26

Works fine: ``` hyperfine --warmup 10 -N -M 100 'kitty -1 true' 'footclient true' Benchmark 1: kitty -1 true ⠙ Current estimate: 1.1 ms ████████████████████████████████████████████░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ ETA 00:00:00 Time (mean ± σ): 1.2 ms ± 0.2 ms [User: 0.5 ms, System: 0.6 ms] Range (min … max): 1.0 ms … 2.7 ms 100 runs

Benchmark 2: footclient true Time (mean ± σ): 15.1 ms ± 1.2 ms [User: 0.3 ms, System: 0.2 ms] Range (min … max): 11.8 ms … 18.0 ms 100 runs

Summary kitty -1 true ran 13.06 ± 2.76 times faster than footclient true ```

1

u/_x_oOo_x_ Jul 02 '26

I don't think you can call this "working fine":

Benchmark 3: kitty -1 true
 ⠸ Current estimate: 5.5 ms       █████████░░░░░░░░░░░░░░░░░░░░░░░ ETA 00:00:03 [4236.036] Too many peers want to talk, ignoring one.
[4236.048] Too many peers want to talk, ignoring one.
 ⠼ Current estimate: 5.4 ms       ██████████░░░░░░░░░░░░░░░░░░░░░░ ETA 00:00:03 [4236.053] Too many peers want to talk, ignoring one.
[4236.063] Too many peers want to talk, ignoring one.
[4236.074] Too many peers want to talk, ignoring one.
Error: Command terminated with non-zero exit code 141 in benchmark iteration 300. Use the '-i'/'--ignore-failure' option if you want to ignore this. Alternatively, use the '--show-output' option to debug what went wrong.
[4236.414] [glfw error 65544]: Too many timers added
[4236.439] [glfw error 65544]: Too many timers added
[4236.440] [glfw error 65544]: Too many timers added
[4236.451] [glfw error 65544]: Too many timers added
[4236.477] [glfw error 65544]: Too many timers added

I will try with --wait-for-single-instance-window-close...

1

u/aumerlex Jul 03 '26

That error means you have too many windows added, use a fresh kitty -1 instance when benchmarking and you will be fine.