Skip to content
Eric Nielsen edited this page Nov 26, 2021 · 12 revisions
Clone this wiki locally

Speed is important and is something Zim takes pride in. Many users of Zsh frameworks complain of the slowness in gaining an interactive session. Below is a load-time comparison of many popular frameworks.

The tests were done with almost the exact same modules/plugins. The default configurations for each framework are changed only slightly from their default. This is to match feature-parity against the baseline, Zim. Each load-time test was run 100 times to get the best possible results. The tests were run with the expect script below, that measures the time until the first prompt appearance.

#!/usr/bin/expect -f

set wd [file tail [pwd]]
set c0 [clock microseconds]
spawn -noecho zsh -li
expect {
  -re {\e](?:[0127]|1337);.*?(?:\a|\e\\)} { exp_continue } ; # match escape sequences to be ignored
  $wd { send_error "[expr [clock microseconds] - $c0]\n" } ; # match working dir at prompt
  timeout { exit 1 }
sleep 1
send "exit\r"

The script that generated these results can be found here.

Zsh frameworks benchmark