Memory Management Overhead

Source code: oils/benchmarks/gc.sh

GC Stats

task elapsed ms max gc millis total gc millis allocated MB max rss MB num allocated num gc points num gc done gc threshold num growths max survived shell label
parse.configure-cpython 33 4 10 12.0 18.2 471,263 1,282 6 413,142 5 206,571 osh-native
parse.configure-cpython 37 5 12 12.0 18.9 471,263 1,282 6 413,150 5 206,575 osh-nosouffle
parse.configure-coreutils 168 34 90 45.9 51.7 1,638,002 4,764 12 1,056,640 6 787,841 osh-native
parse.configure-coreutils 153 28 70 45.9 52.3 1,638,001 4,764 12 1,056,648 6 787,845 osh-nosouffle
parse.abuild 9 1 2 2.6 8.7 102,791 180 3 86,628 1 43,314 osh-native
parse.abuild 10 1 2 2.6 9.0 102,791 180 3 86,636 1 43,318 osh-nosouffle
ex.compute-fib 20 0 1 2.8 8.1 572,115 22,608 12 50,000 0 2,982 osh-native
ex.compute-fib 24 0 1 2.8 8.8 572,115 22,608 12 50,000 0 2,985 osh-nosouffle
ex.bashcomp-parse-help 221 0 3 11.6 9.0 990,261 15,258 21 50,000 0 3,965 osh-native
ex.bashcomp-parse-help 228 0 4 11.6 9.6 990,260 15,258 21 50,000 0 3,969 osh-nosouffle
ex.abuild-print-help 21 1 2 3.0 9.3 117,219 277 3 83,990 1 41,995 osh-native
ex.abuild-print-help 22 1 2 3.0 10.0 117,218 277 3 83,998 1 41,999 osh-nosouffle

Resource Usage

parse.configure-cpython

elapsed ms user ms sys ms max rss MB shell label shell runtime opts
7 7 0 1.7 dash -
13 13 0 3.3 bash -
89 50 46 3.5 zsh -
15 11 5 29.2 bumpleak/osh mut
17 13 4 28.8 _bin/cxx-opt+bumproot/osh mut
19 15 4 30.3 _bin/cxx-opt+bumpsmall/osh mut+alloc
26 12 14 25.4 osh-native mut+alloc
28 16 12 26.0 osh-native mut+alloc+free
33 26 7 18.2 osh-native mut+alloc+free+gc
38 28 10 18.2 osh-native mut+alloc+free+gc+exit
29 17 12 25.8 osh-nosouffle mut+alloc
32 19 13 26.2 osh-nosouffle mut+alloc+free
37 30 8 18.9 osh-nosouffle mut+alloc+free+gc
54 48 6 18.6 osh-nosouffle mut+alloc+free+gc+exit
40 26 14 33.4 _bin/cxx-opt+nopool/osh mut+alloc
45 33 12 22.6 _bin/cxx-opt+nopool/osh mut+alloc+free+gc

parse.configure-coreutils

Parsing the autoconf-generated configure script from GNU coreutils.

Note that unlike other shells, osh -n retains all nodes on purpose. (See the parser benchmark).

elapsed ms user ms sys ms max rss MB shell label shell runtime opts
23 22 1 1.7 dash -
42 39 3 3.4 bash -
327 194 157 3.7 zsh -
48 40 8 84.5 bumpleak/osh mut
49 40 9 85.4 _bin/cxx-opt+bumproot/osh mut
60 46 14 86.5 _bin/cxx-opt+bumpsmall/osh mut+alloc
83 56 27 73.7 osh-native mut+alloc
92 64 28 75.5 osh-native mut+alloc+free
168 140 28 51.7 osh-native mut+alloc+free+gc
153 126 27 52.5 osh-native mut+alloc+free+gc+exit
91 55 36 74.2 osh-nosouffle mut+alloc
100 63 37 75.9 osh-nosouffle mut+alloc+free
153 125 28 52.3 osh-nosouffle mut+alloc+free+gc
161 140 21 52.8 osh-nosouffle mut+alloc+free+gc+exit
125 81 44 98.0 _bin/cxx-opt+nopool/osh mut+alloc
215 179 35 72.6 _bin/cxx-opt+nopool/osh mut+alloc+free+gc

parse.abuild

Parsing abuild from Alpine Linux.

elapsed ms user ms sys ms max rss MB shell label shell runtime opts
2 1 1 1.7 dash -
4 3 1 3.1 bash -
7 1 5 3.4 zsh -
6 3 3 11.5 bumpleak/osh mut
7 4 3 12.5 _bin/cxx-opt+bumproot/osh mut
7 6 1 12.3 _bin/cxx-opt+bumpsmall/osh mut+alloc
8 4 4 10.5 osh-native mut+alloc
9 5 3 10.7 osh-native mut+alloc+free
9 8 1 8.7 osh-native mut+alloc+free+gc
9 7 3 8.8 osh-native mut+alloc+free+gc+exit
9 5 3 11.0 osh-nosouffle mut+alloc
9 5 4 11.1 osh-nosouffle mut+alloc+free
10 9 1 9.0 osh-nosouffle mut+alloc+free+gc
10 7 3 9.2 osh-nosouffle mut+alloc+free+gc+exit
12 8 4 11.8 _bin/cxx-opt+nopool/osh mut+alloc
13 11 1 9.5 _bin/cxx-opt+nopool/osh mut+alloc+free+gc

ex.compute-fib

A synthetic benchmark for POSIX shell arithmetic.

elapsed ms user ms sys ms max rss MB shell label shell runtime opts
10 8 2 1.4 dash -
31 30 1 3.3 bash -
22 16 6 3.4 zsh -
16 12 4 32.0 bumpleak/osh mut
18 12 6 32.2 _bin/cxx-opt+bumproot/osh mut
20 16 4 33.4 _bin/cxx-opt+bumpsmall/osh mut+alloc
28 19 9 26.9 osh-native mut+alloc
30 19 11 27.3 osh-native mut+alloc+free
20 18 2 8.1 osh-native mut+alloc+free+gc
19 16 4 8.3 osh-native mut+alloc+free+gc+exit
33 21 12 27.3 osh-nosouffle mut+alloc
35 25 10 27.7 osh-nosouffle mut+alloc+free
24 21 3 8.8 osh-nosouffle mut+alloc+free+gc
25 23 2 8.7 osh-nosouffle mut+alloc+free+gc+exit
46 27 19 36.4 _bin/cxx-opt+nopool/osh mut+alloc
29 28 1 9.8 _bin/cxx-opt+nopool/osh mut+alloc+free+gc

ex.bashcomp-parse-help

A realistic bash-completion workload.

elapsed ms user ms sys ms max rss MB shell label shell runtime opts
103 96 7 3.4 bash -
216 172 44 56.8 bumpleak/osh mut
224 165 59 57.0 _bin/cxx-opt+bumproot/osh mut
241 185 56 58.6 _bin/cxx-opt+bumpsmall/osh mut+alloc
256 186 70 48.8 osh-native mut+alloc
265 197 68 50.7 osh-native mut+alloc+free
221 166 55 9.0 osh-native mut+alloc+free+gc
225 170 55 9.0 osh-native mut+alloc+free+gc+exit
264 191 73 49.2 osh-nosouffle mut+alloc
276 197 79 51.2 osh-nosouffle mut+alloc+free
228 176 52 9.6 osh-nosouffle mut+alloc+free+gc
229 189 40 9.4 osh-nosouffle mut+alloc+free+gc+exit
278 203 75 64.4 _bin/cxx-opt+nopool/osh mut+alloc
256 204 52 10.7 _bin/cxx-opt+nopool/osh mut+alloc+free+gc

ex.abuild-print-help

Running abuild -h from Alpine Linux.

elapsed ms user ms sys ms max rss MB shell label shell runtime opts
9 5 4 3.9 dash -
16 8 8 4.8 bash -
16 11 5 4.1 zsh -
18 7 11 12.4 bumpleak/osh mut
18 7 12 12.6 _bin/cxx-opt+bumproot/osh mut
18 11 9 12.7 _bin/cxx-opt+bumpsmall/osh mut+alloc
20 7 13 11.7 osh-native mut+alloc
21 10 11 11.7 osh-native mut+alloc+free
21 13 9 9.3 osh-native mut+alloc+free+gc
21 11 11 9.6 osh-native mut+alloc+free+gc+exit
21 10 12 12.2 osh-nosouffle mut+alloc
22 12 11 12.2 osh-nosouffle mut+alloc+free
22 12 11 10.0 osh-nosouffle mut+alloc+free+gc
23 13 10 10.1 osh-nosouffle mut+alloc+free+gc+exit
23 12 11 13.1 _bin/cxx-opt+nopool/osh mut+alloc
25 18 7 10.4 _bin/cxx-opt+nopool/osh mut+alloc+free+gc