Skip to content

Latest commit

 

History

History
103 lines (85 loc) · 4.71 KB

Benchmark.md

File metadata and controls

103 lines (85 loc) · 4.71 KB

color.sh benchmarks

Commands are run as: <shell> -c color.sh <cmd>:

Setup

Type Component
System macOS 14.1
Arch arm64
Model MacBook Pro 17,1
CPU Apple M1
Terminal Alacritty

color.sh bg

Command Mean [ms] Min [ms] Max [ms] Relative
mksh 1.7 ± 0.0 1.7 1.9 1.00
dash 1.9 ± 0.1 1.8 2.1 1.11 ± 0.06
ksh93 2.8 ± 0.1 2.7 3.0 1.63 ± 0.06
bash 3.0 ± 0.3 2.7 3.5 1.74 ± 0.17
oksh 3.0 ± 0.0 2.9 3.1 1.77 ± 0.05
yash 3.4 ± 0.0 3.3 3.5 1.95 ± 0.06
zsh 10.7 ± 0.1 10.6 10.9 6.23 ± 0.18
posh 24.1 ± 0.2 23.7 24.8 14.03 ± 0.42
osh 36.8 ± 0.3 36.5 38.0 21.44 ± 0.63

color.sh fg

Command Mean [ms] Min [ms] Max [ms] Relative
mksh 1.7 ± 0.0 1.7 1.8 1.00
dash 1.9 ± 0.1 1.8 2.1 1.08 ± 0.04
bash 2.7 ± 0.0 2.7 2.7 1.55 ± 0.04
ksh93 2.8 ± 0.0 2.8 2.9 1.61 ± 0.04
oksh 3.1 ± 0.0 3.0 3.2 1.76 ± 0.04
yash 3.4 ± 0.0 3.3 3.5 1.94 ± 0.05
zsh 10.9 ± 0.2 10.6 11.7 6.23 ± 0.19
posh 26.7 ± 0.6 26.1 28.8 15.35 ± 0.48
osh 36.9 ± 0.2 36.8 37.4 21.18 ± 0.44

color.sh table

Command Mean [ms] Min [ms] Max [ms] Relative
dash 2.2 ± 0.0 2.2 2.3 1.00
ksh93 2.9 ± 0.1 2.9 3.1 1.31 ± 0.03
bash 3.0 ± 0.0 3.0 3.1 1.34 ± 0.02
mksh 4.6 ± 0.1 4.5 4.7 2.07 ± 0.03
yash 4.8 ± 0.1 4.7 4.9 2.13 ± 0.03
oksh 5.9 ± 0.1 5.8 6.2 2.62 ± 0.05
zsh 11.0 ± 0.1 10.9 11.1 4.89 ± 0.06
osh 65.6 ± 1.0 65.0 68.8 29.26 ± 0.54
posh 216.5 ± 1.2 215.1 219.3 96.59 ± 1.16

scolor.sh benchmarks

Commands are run as: <shell> -c scolor.sh <cmd>

scolor.sh bg

Command Mean [ms] Min [ms] Max [ms] Relative
dash 1.5 ± 0.0 1.5 1.5 1.00
bash 2.6 ± 0.1 2.6 2.7 1.79 ± 0.04
ksh93 2.8 ± 0.0 2.7 2.8 1.89 ± 0.03
yash 3.2 ± 0.1 3.0 3.3 2.13 ± 0.08
zsh 11.3 ± 0.3 11.0 11.6 7.66 ± 0.21
mksh 22.8 ± 0.2 22.6 23.1 15.38 ± 0.19
posh 22.8 ± 0.2 22.6 23.1 15.40 ± 0.19
oksh 23.1 ± 0.5 22.8 23.9 15.61 ± 0.38
osh 29.9 ± 0.1 29.8 30.1 20.23 ± 0.15

scolor.sh fg

Command Mean [ms] Min [ms] Max [ms] Relative
dash 1.5 ± 0.0 1.5 1.5 1.00
bash 2.7 ± 0.0 2.7 2.8 1.84 ± 0.04
ksh93 2.8 ± 0.0 2.8 2.8 1.89 ± 0.04
yash 2.9 ± 0.0 2.9 3.0 1.99 ± 0.03
zsh 11.2 ± 0.5 10.8 11.9 7.63 ± 0.35
mksh 23.4 ± 0.3 23.0 23.7 15.91 ± 0.30
posh 23.6 ± 0.4 23.2 24.2 16.05 ± 0.38
oksh 24.4 ± 1.1 23.5 26.1 16.54 ± 0.82
osh 31.0 ± 0.0 30.9 31.0 21.03 ± 0.30

scolor.sh table

Command Mean [ms] Min [ms] Max [ms] Relative
dash 1.8 ± 0.0 1.8 1.9 1.00
ksh93 3.1 ± 0.0 3.1 3.2 1.69 ± 0.04
yash 4.0 ± 0.0 3.9 4.0 2.15 ± 0.05
bash 4.0 ± 1.2 3.4 5.8 2.16 ± 0.67
zsh 11.2 ± 0.2 11.0 11.4 6.10 ± 0.16
osh 47.4 ± 0.1 47.3 47.5 25.80 ± 0.55
oksh 215.3 ± 4.1 212.0 221.2 117.09 ± 3.34
posh 216.3 ± 3.6 214.0 221.7 117.65 ± 3.18
mksh 219.2 ± 7.0 213.4 228.8 119.23 ± 4.56