Memory Management Overhead

Source code: oil/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 107 0 0 19.4 29.9 562,300 1,282 6 683,214 5 341,607 osh-native
parse.configure-coreutils 493 0 0 69.6 91.8 1,947,406 4,764 8 1,843,366 7 921,683 osh-native
parse.abuild 34 0 0 4.1 11.1 116,634 180 3 145,110 2 72,555 osh-native
ex.compute-fib 142 0 0 35.0 9.1 1,437,016 31,810 29 50,000 0 1,240 osh-native
ex.bashcomp-parse-help 436 0 0 49.3 9.7 1,911,598 27,375 40 50,000 0 2,669 osh-native
ex.abuild-print-help 40 0 0 4.8 11.2 141,496 477 3 133,498 2 66,749 osh-native

Resource Usage

parse.configure-cpython

elapsed ms user ms sys ms max rss MB shell label shell runtime opts
48 34 4 3.6 bash -
6 6 0 1.7 dash -
137 78 62 4.3 zsh -
44 32 12 31.9 bumpleak/osh mut
86 74 12 36.2 osh-native mut+alloc
113 84 28 49.1 osh-native mut+alloc+free
107 87 20 29.9 osh-native mut+alloc+free+gc
171 150 20 35.8 osh-native mut+alloc+free+gc+exit

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
107 103 4 3.7 bash -
22 22 0 1.9 dash -
472 285 202 4.3 zsh -
145 111 32 97.1 bumpleak/osh mut
237 185 51 112.8 osh-native mut+alloc
358 275 84 145.2 osh-native mut+alloc+free
493 421 72 91.8 osh-native mut+alloc+free+gc
525 473 52 112.4 osh-native mut+alloc+free+gc+exit

parse.abuild

Parsing abuild from Alpine Linux.

elapsed ms user ms sys ms max rss MB shell label shell runtime opts
27 18 0 3.6 bash -
2 2 0 1.8 dash -
17 13 4 4.2 zsh -
10 10 0 11.2 bumpleak/osh mut
19 4 15 12.0 osh-native mut+alloc
29 18 11 14.0 osh-native mut+alloc+free
34 34 0 11.1 osh-native mut+alloc+free+gc
38 27 12 12.4 osh-native mut+alloc+free+gc+exit

ex.compute-fib

A synthetic benchmark for POSIX shell arithmetic.

elapsed ms user ms sys ms max rss MB shell label shell runtime opts
42 41 0 3.6 bash -
10 10 0 1.7 dash -
25 25 0 4.4 zsh -
87 75 12 58.2 bumpleak/osh mut
171 143 28 74.4 osh-native mut+alloc
212 148 64 98.3 osh-native mut+alloc+free
142 142 0 9.1 osh-native mut+alloc+free+gc
142 142 0 8.8 osh-native mut+alloc+free+gc+exit

ex.bashcomp-parse-help

A realistic bash-completion workload.

elapsed ms user ms sys ms max rss MB shell label shell runtime opts
204 204 0 3.8 bash -
329 277 51 80.9 bumpleak/osh mut
484 376 108 96.7 osh-native mut+alloc
573 477 96 129.0 osh-native mut+alloc+free
436 416 20 9.7 osh-native mut+alloc+free+gc
477 452 20 9.9 osh-native mut+alloc+free+gc+exit

ex.abuild-print-help

Running abuild -h from Alpine Linux.

elapsed ms user ms sys ms max rss MB shell label shell runtime opts
30 19 2 5.2 bash -
7 8 0 4.0 dash -
26 19 6 4.4 zsh -
23 12 11 12.7 bumpleak/osh mut
30 23 7 13.7 osh-native mut+alloc
37 23 15 16.9 osh-native mut+alloc+free
40 31 10 11.2 osh-native mut+alloc+free+gc
40 41 0 12.7 osh-native mut+alloc+free+gc+exit