1# Benchmarks23There are multiple implementations of jsonnet implemented in different languages: Rust (this repo), [Go](https://github.com/google/go-jsonnet/), [Scala](https://github.com/databricks/sjsonnet), [C++](https://github.com/google/jsonnet), [Haskell](https://github.com/moleike/haskell-jsonnet).45For simplicity, I will call these implementations by the language of their implementation.67Unfortunately, I haven't managed to measure performance of Haskell implementation, because I wasn't able to build it, and there is no binaries published anywhere, so this implementation is omitted from the following benchmarks89<details>10<summary>Tested versions</summary>1112Go: Jsonnet commandline interpreter (Go implementation) v0.20.01314```15Jsonnet commandline interpreter (Go implementation) v0.20.01617jsonnet {<option>} <filename>1819Available options:20 -h / --help This message21 -e / --exec Treat filename as code22 -J / --jpath <dir> Specify an additional library search dir23 (right-most wins)24 -o / --output-file <file> Write to the output file rather than stdout25 -m / --multi <dir> Write multiple files to the directory, list files26 on stdout27 -c / --create-output-dirs Automatically creates all parent directories for28 files29 -y / --yaml-stream Write output as a YAML stream of JSON documents30 -S / --string Expect a string, manifest as plain text31 -s / --max-stack <n> Number of allowed stack frames32 -t / --max-trace <n> Max length of stack trace before cropping33 --version Print version3435Available options for specifying values of 'external' variables:36 Provide the value as a string:37 -V / --ext-str <var>[=<val>] If <val> is omitted, get from environment38 var <var>39 --ext-str-file <var>=<file> Read the string from the file40 Provide a value as Jsonnet code:41 --ext-code <var>[=<code>] If <code> is omitted, get from environment42 var <var>43 --ext-code-file <var>=<file> Read the code from the file4445Available options for specifying values of 'top-level arguments':46 Provide the value as a string:47 -A / --tla-str <var>[=<val>] If <val> is omitted, get from environment48 var <var>49 --tla-str-file <var>=<file> Read the string from the file50 Provide a value as Jsonnet code:51 --tla-code <var>[=<code>] If <code> is omitted, get from environment52 var <var>53 --tla-code-file <var>=<file> Read the code from the file5455Environment variables:56 JSONNET_PATH is a colon (semicolon on Windows) separated list of directories57 added in reverse order before the paths specified by --jpath (i.e. left-most58 wins). E.g. these are equivalent:59 JSONNET_PATH=a:b jsonnet -J c -J d60 JSONNET_PATH=d:c:a:b jsonnet61 jsonnet -J b -J a -J c -J d6263In all cases:64 <filename> can be - (stdin)65 Multichar options are expanded e.g. -abc becomes -a -b -c.66 The -- option suppresses option processing for subsequent arguments.67 Note that since filenames and jsonnet programs can begin with -, it is68 advised to use -- if the argument is unknown, e.g. jsonnet -- "$FILENAME".69```7071C++: Jsonnet commandline interpreter v0.20.07273```74Jsonnet commandline interpreter v0.20.07576jsonnet {<option>} <filename>7778Available options:79 -h / --help This message80 -e / --exec Treat filename as code81 -J / --jpath <dir> Specify an additional library search dir (right-most wins)82 -o / --output-file <file> Write to the output file rather than stdout83 -m / --multi <dir> Write multiple files to the directory, list files on stdout84 -y / --yaml-stream Write output as a YAML stream of JSON documents85 -S / --string Expect a string, manifest as plain text86 -s / --max-stack <n> Number of allowed stack frames87 -t / --max-trace <n> Max length of stack trace before cropping88 --gc-min-objects <n> Do not run garbage collector until this many89 --gc-growth-trigger <n> Run garbage collector after this amount of object growth90 --version Print version91Available options for specifying values of 'external' variables:92Provide the value as a string:93 -V / --ext-str <var>[=<val>] If <val> is omitted, get from environment var <var>94 --ext-str-file <var>=<file> Read the string from the file95Provide a value as Jsonnet code:96 --ext-code <var>[=<code>] If <code> is omitted, get from environment var <var>97 --ext-code-file <var>=<file> Read the code from the file98Available options for specifying values of 'top-level arguments':99Provide the value as a string:100 -A / --tla-str <var>[=<val>] If <val> is omitted, get from environment var <var>101 --tla-str-file <var>=<file> Read the string from the file102Provide a value as Jsonnet code:103 --tla-code <var>[=<code>] If <code> is omitted, get from environment var <var>104 --tla-code-file <var>=<file> Read the code from the file105Environment variables:106JSONNET_PATH is a colon (semicolon on Windows) separated list of directories added107in reverse order before the paths specified by --jpath (i.e. left-most wins)108E.g. JSONNET_PATH=a:b jsonnet -J c -J d is equivalent to:109JSONNET_PATH=d:c:a:b jsonnet110jsonnet -J b -J a -J c -J d111112In all cases:113<filename> can be - (stdin)114Multichar options are expanded e.g. -abc becomes -a -b -c.115The -- option suppresses option processing for subsequent arguments.116Note that since filenames and jsonnet programs can begin with -, it is advised to117use -- if the argument is unknown, e.g. jsonnet -- "$FILENAME".118```119120Scala:121122```123Missing argument: file <str>124Expected Signature: Sjsonnet 0.4.10125usage: sjsonnet [sjsonnet-options] script-file126 -i --interactive Run Mill in interactive mode, suitable for opening REPLs and127 taking user input128 -J --jpath <str> Specify an additional library search dir (right-most wins)129 -o --output-file <str> Write to the output file rather than stdout130 -m --multi <str> Write multiple files to the directory, list files on stdout131 -c --create-output-dirs Automatically creates all parent directories for files132 -y --yaml-stream Write output as a YAML stream of JSON documents133 -S --string Expect a string, manifest as plain text134 -V --ext-str <str> <var>[=<val>] Provide 'external' variable as string. 'If135 <val> is omitted, get from environment var <var>136 --ext-str-file <str> <var>=<file> Provide 'external' variable as string from the137 file138 -V --ext-code <str> <var>[=<code>] Provide 'external' variable as Jsonnet code.139 If <code> is omitted, get from environment var <var>140 --ext-code-file <str> <var>=<file> Provide 'external' variable as Jsonnet code141 from the file142 -A --tla-str <str> <var>[=<val>] Provide top-level arguments as string. 'If143 <val> is omitted, get from environment var <var>144 --tla-str-file <str> <var>=<file> Provide top-level arguments variable as string145 from the file146 -V --tla-code <str> <var>[=<val>] Provide top-level arguments as Jsonnet code.147 'If <val> is omitted, get from environment var <var>148 --tla-code-file <str> <var>=<file> Provide top-level arguments variable as Jsonnet149 code from the file150 -n --indent <int> How much to indent your output JSON151 -p --preserve-order Preserves order of keys in the resulting JSON152 --strict Enforce some additional syntax limitations153 --yaml-out Write output as a YAML document154 file <str> The jsonnet file you wish to evaluate155 --yaml-debug Generate source line comments in the output YAML doc to make156 it easier to figure out where values come from.157 --no-static-errors Turn static errors into warnings158 --fatal-warnings Fail if any warnings were emitted159 -e --exec Evaluate the given string as Jsonnet rather than treating it160 as a file name161 --no-duplicate-keys-in-comprehension Raise an error if an object comprehension contains duplicate162 keys163 --strict-import-syntax Raise an error if import expressions are used without proper164 parentheses, e.g. import "foo".bar rather than (import165 "foo").bar166 --strict-inherited-assertions Properly handle assertions defined in a Jsonnet dictionary167 that is extended more than once168169170```171172</details>173174Rust (alternative):175176```177Usage: rsjsonnet [OPTIONS] <filename>178179Arguments:180 <filename> 181182Options:183 -e, --exec Treat filename as code184 -J, --jpath <dir> Specify an additional library search dir (right-most wins)185 -o, --output-file <file> Write to the output file rather than stdout186 -m, --multi <dir> Write multiple files to the directory, list files on stdout187 -y, --yaml-stream Write output as a YAML stream of JSON documents188 -S, --string Expect a string, manifest as plain text189 -s, --max-stack <n> Number of allowed stack frames190 -t, --max-trace <n> Max length of stack trace before cropping191 -V, --ext-str <var=[val]> 192 --ext-str-file <var=file> 193 --ext-code <var[=code]> 194 --ext-code-file <var=file> 195 -A, --tla-str <var[=val]> 196 --tla-str-file <var=file> 197 --tla-code <var[=code]> 198 --tla-code-file <var=file> 199 -h, --help Print help200201```202203</details>204205206## Real world207208### Graalvm CI209210> Note: No results for C++, takes longer than a hour211212<details>213<summary>Source</summary>214215```jsonnet216# Common217local common = import 'common.jsonnet';218local graal_common = import 'graal-common.json';219220# Compiler221local compiler = import 'compiler/ci/ci.jsonnet';222223# GraalWasm224local wasm = import 'wasm/ci/ci.jsonnet';225226# Espresso227local espresso = import 'espresso/ci/ci.jsonnet';228229# Regex230local regex = import 'regex/ci/ci.jsonnet';231232# SDK233local sdk = import 'sdk/ci/ci.jsonnet';234235# SubstrateVM236local substratevm = import 'substratevm/ci/ci.jsonnet';237238# Sulong239local sulong = import 'sulong/ci/ci.jsonnet';240241# Tools242local tools = import 'tools/ci/ci.jsonnet';243244# Truffle245local truffle = import 'truffle/ci/ci.jsonnet';246247# JavaDoc248local javadoc = import "ci_includes/publish-javadoc.jsonnet";249250# VM251local vm = import 'vm/ci/ci_includes/vm.jsonnet';252253local verify_ci = (import 'ci-check.libsonnet').verify_ci;254255{256 # Ensure that entries in common.jsonnet can be resolved.257 _checkCommon: (import 'common.jsonnet'),258 ci_resources:: (import 'ci-resources.libsonnet'),259 overlay: graal_common.ci.overlay,260 specVersion: "3",261 builds: [common.add_excludes_guard(b) for b in (262 compiler.builds +263 wasm.builds +264 espresso.builds +265 regex.builds +266 sdk.builds +267 substratevm.builds +268 sulong.builds +269 tools.builds +270 truffle.builds +271 javadoc.builds +272 vm.builds273 )],274 assert verify_ci(self.builds),275 // verify that the run-spec demo works276 assert (import "ci/ci_common/run-spec-demo.jsonnet").check(),277}278279```280</details>281282| Command | Mean [ms] | Min [ms] | Max [ms] | Relative |283|:---|---:|---:|---:|---:|284| `Rust` | 93.6 ± 0.6 | 92.5 | 94.7 | 1.00 |285| `Rust (alternative, rsjsonnet)` | 263.3 ± 1.8 | 259.0 | 268.4 | 2.81 ± 0.03 |286| `Go` | 1204.6 ± 5.0 | 1196.0 | 1215.4 | 12.87 ± 0.10 |287| `Scala` | 720.0 ± 2.9 | 713.4 | 725.3 | 7.70 ± 0.06 |288289### Kube-prometheus manifests290291<details>292<summary>Source</summary>293294```jsonnet295local kp =296 (import 'kube-prometheus/main.libsonnet') +297 // Uncomment the following imports to enable its patches298 // (import 'kube-prometheus/addons/anti-affinity.libsonnet') +299 // (import 'kube-prometheus/addons/managed-cluster.libsonnet') +300 // (import 'kube-prometheus/addons/node-ports.libsonnet') +301 // (import 'kube-prometheus/addons/static-etcd.libsonnet') +302 // (import 'kube-prometheus/addons/custom-metrics.libsonnet') +303 // (import 'kube-prometheus/addons/external-metrics.libsonnet') +304 // (import 'kube-prometheus/addons/pyrra.libsonnet') +305 {306 values+:: {307 common+: {308 namespace: 'monitoring',309 },310 },311 };312313{ 'setup/0namespace-namespace': kp.kubePrometheus.namespace } +314{315 ['setup/prometheus-operator-' + name]: kp.prometheusOperator[name]316 for name in std.filter((function(name) name != 'serviceMonitor' && name != 'prometheusRule'), std.objectFields(kp.prometheusOperator))317} +318// { 'setup/pyrra-slo-CustomResourceDefinition': kp.pyrra.crd } +319// serviceMonitor and prometheusRule are separated so that they can be created after the CRDs are ready320{ 'prometheus-operator-serviceMonitor': kp.prometheusOperator.serviceMonitor } +321{ 'prometheus-operator-prometheusRule': kp.prometheusOperator.prometheusRule } +322{ 'kube-prometheus-prometheusRule': kp.kubePrometheus.prometheusRule } +323{ ['alertmanager-' + name]: kp.alertmanager[name] for name in std.objectFields(kp.alertmanager) } +324{ ['blackbox-exporter-' + name]: kp.blackboxExporter[name] for name in std.objectFields(kp.blackboxExporter) } +325{ ['grafana-' + name]: kp.grafana[name] for name in std.objectFields(kp.grafana) } +326// { ['pyrra-' + name]: kp.pyrra[name] for name in std.objectFields(kp.pyrra) if name != 'crd' } +327{ ['kube-state-metrics-' + name]: kp.kubeStateMetrics[name] for name in std.objectFields(kp.kubeStateMetrics) } +328{ ['kubernetes-' + name]: kp.kubernetesControlPlane[name] for name in std.objectFields(kp.kubernetesControlPlane) }329{ ['node-exporter-' + name]: kp.nodeExporter[name] for name in std.objectFields(kp.nodeExporter) } +330{ ['prometheus-' + name]: kp.prometheus[name] for name in std.objectFields(kp.prometheus) } +331{ ['prometheus-adapter-' + name]: kp.prometheusAdapter[name] for name in std.objectFields(kp.prometheusAdapter) }332333```334</details>335336| Command | Mean [ms] | Min [ms] | Max [ms] | Relative |337|:---|---:|---:|---:|---:|338| `Rust` | 129.4 ± 1.4 | 127.7 | 132.8 | 1.00 |339| `Rust (alternative, rsjsonnet)` | 197.0 ± 1.9 | 193.6 | 200.7 | 1.52 ± 0.02 |340| `Go` | 2127.7 ± 13.8 | 2105.4 | 2151.5 | 16.44 ± 0.21 |341| `Scala` | 947.9 ± 11.1 | 926.1 | 967.9 | 7.33 ± 0.12 |342| `C++` | 87633.8 ± 569.9 | 86464.2 | 89118.8 | 677.29 ± 8.72 |343344## Benchmarks from C++ jsonnet (/perf_tests)345346### Large string join347348<details>349<summary>Source</summary>350351```jsonnet352{353 text: std.join(',', std.makeArray(76846, function(_) 'x')),354}355356```357</details>358359| Command | Mean [ms] | Min [ms] | Max [ms] | Relative |360|:---|---:|---:|---:|---:|361| `Rust` | 5.6 ± 0.1 | 5.4 | 6.2 | 1.00 |362| `Rust (alternative, rsjsonnet)` | 45.3 ± 0.9 | 43.5 | 47.8 | 8.04 ± 0.25 |363| `Go` | 98.2 ± 1.6 | 95.0 | 100.8 | 17.45 ± 0.50 |364| `Scala` | 331.1 ± 5.8 | 322.3 | 343.7 | 58.79 ± 1.73 |365| `C++` | 76.5 ± 0.7 | 75.4 | 78.0 | 13.59 ± 0.34 |366367### Large string template368369> Note: No results for Go, fails with os stack size exhausion370371| Command | Mean [ms] | Min [ms] | Max [ms] | Relative |372|:---|---:|---:|---:|---:|373| `Rust` | 6.7 ± 0.1 | 6.4 | 7.1 | 1.00 |374| `Rust (alternative, rsjsonnet)` | 7.1 ± 0.2 | 6.8 | 7.6 | 1.05 ± 0.03 |375| `Scala` | 392.7 ± 2.7 | 388.2 | 399.8 | 58.29 ± 1.19 |376| `C++` | 14376.2 ± 35.8 | 14317.5 | 14448.6 | 2133.86 ± 41.53 |377378### Realistic 1379380<details>381<summary>Source</summary>382383```jsonnet384local utils = {385 Func3(aaaaaaa, bbbbbbb, cccc)::386 'XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/%s/XXXXX/%s/XXXXXXXXXXXXXXX/%s'387 % [aaaaaaa, bbbbbbb, cccc],388};389390391local long_list = [392 '001xxxxxxxxxxxxxxx-xxx',393 '002xxxxxxxxxxxxxxxxxx-xxx',394 '003xxxxxxxxxxxxxxxx-xxxxxxx',395 '004xxxxxx-xxxxxx',396 '005xxxx-xxx-xxxx',397 '006xxx-xxx-xxxxxx',398 '007xxx-xxx-xxxx-xxxx',399 '008xxx-xxx-xxxx-xxxx-xxxxxxx',400 '009xxx-xxx-xxxxx-xxxx-xxxxxxx-xxxxxx',401 '010xxx-xxx-xxxx-xxxxxxx-xxxxxx-xxxxxxx',402 '011xxx-xxx-xxxxx-xxxxxxxx-xxxxxxx',403 '012xxx-xxx-xxxx-xxxxxxxx-xxxxxxx-xxxxxx',404 '013xxx-xxx-xxxx-xxxxxxxxxx',405 '014xxx-xxx-xxxxx-xxxxxx-xx',406 '015xxx-xxx-xxxxxx-xxxxxxx',407 '016xxx-xxx-xxxx-xxxxxxxx-xxxxx',408 '017xxx-xxx-xxxx-xxxxxxxxxxxxxxx',409 '018xxx-xxx-xxxx-xxxxxxxx-xxxxxxx-xxxxxxx',410 '019xxx-xxx-xxxx-xxxxxxxx-xx',411 '020xxx-xxx-xxxx-xxxxxxxxxxxxxxxx',412 '021xxx-xxx-xxxx-xxxxxxxx-xxxxxxxxxxxx-xxx',413 '022xxx-xxxx-xxxx-xxxx-xxxxxxx',414 '023xxx-xxxx-xxxx-xxx-xxxxxxx-xxxxxx-xxxxxxx',415 '024xxx-xxx-xxxx-xxx-xxxx-xxxx-xxx-xxxxxxxxx',416 '025xxx-xxxx-xxxx-xxxxxxxxx',417 '026xxx-xxx-xxxx-xxx-xxxxxxx',418 '027xxx-xxx-xxxx-xxx-xxxxxxx',419 '028xxx-xxx-xxxx-xxxxxxxxxx',420 '029xxx-xxx-xxxx-xxxxxx',421 '030xxx-xxx-xxxx-xxx-xxxxxxx',422 '031xxx-xxx-xxxx-xxx-xxxxxxxx',423 '032xxx-xxx-xxxxx-xxxxxxxxxxxx-xxxxxxx',424 '033xxx-xxx-xxxx-xxx-xxxx-xxxx',425 '034xxx-xxx-xxxx-xxx-xxxxxxxx-xxxxxxxx',426 '035xxx-xxx-xxxx-xxxxxxx',427 '036xxx-xxx-xxxx-xxxxxxxx-xxxxxxx',428 '037xxx-xxx-xxxx-xxxxxx',429 '038xxx-xxx-xxxx-xxxxxxxxxx',430 '039xxxx-xxx-xxxx-xxxxxx-xxxxxx-xxxxxxx',431 '040xxx-xxx-xxxx-xxxxxx-xxxxxxx',432 '041xxxx-xxx-xxxx-xxxxxx-xx',433 '042xxx-xxx-xxxx-xxxxxxxxxxx',434 '043xxx-xxx-xxxx-xxxxxxxxxxx-xxxxxxx',435 '044xxx-xxx-xxxx-xxxxxxx-xxx-xxxxxx',436 '045xxx-xxx-xxxx-xxxxxx-xxx-xxxxxx-xxx',437 '046xxx-xxx-xxxx-xxxxxx-xxx-xxxxxx-xxx',438 '047xxx-xxx-xxxx-xxxxxx-xxx-xxxxxx-xxxxxxx',439 '048xxx-xxx-xxxx-xxxxxx-xxx-xxxxxx-xxxxxxxx',440 '049xxx-xxx-xxxx-xxxxxx-xxx-xxxxxx-xxxxxxxxx',441 '050xxx-xxx-xxxxx-xxxxx-xxxxxxx',442 '051xxx-xxx-xxxx-xxxxx-xxxxxxxx-xxxxxx',443 '052xxx-xxx-xxxx-xxxxx-xx',444 '053xxx-xxx-xxxx-xxxx-xxxxxxx-xxx-xxxxxxx',445 '054xxx-xxx-xxxx-xxxx-xxxxxxx-xxx-xxxxxx',446 '055xxx-xxx-xxxx-xxx',447 '056xxx-xxx-xxxx-xxxxxxx-xxxxxxx',448 '057xxx-xxx-xxxx-xxxxxxx-xxx-xxxxxxx',449 '058xxx-xxx-xxxx-xxxxxxxxx-xxxxxx-xxxxxxx',450 '059xxx-xxx-xxxx-xx-xxxxxxxxxxx-xxxxx',451 '060xxx-xxx-xxxx-xxxxxxxxxxxxxx-xxxxxxx',452 '061xxx-xxx-xxxx-xxxxxxxx-xxxxxxx',453 '062xxx-xxx-xxxx-xxxxxxxxxxxxx-xxxxxxx',454 '063xxx-xxx-xxxx-xxxxxx-xxxxxxx',455 '064xxx-xxx-xxxxx-xxxxxx-xxxxxxx',456 '065xxx-xxx-xxxx-xxxxx-xxxxx',457 '066xxx-xxx-xxxx-xxxxx-xxxx',458 '067xxx-xxx-xxxx-xxxxxxxxxxxxxxxxx',459 '068xxx-xxx-xxxx-xxxxxxxx-xxxxx-xxx',460 '069xxx-xxx-xxxx-xxxxxxxx-xx-xxx-xxxxxxxx',461 '070xxx-xxx-xxxx-xxxxxxxx-xxxxxx-xxxxxxx',462 '071xxx-xxx-xxxx-xxxxxxxxxx',463 '072xxx-xxxx-xxxx-xxxxxxxxxxxxxxxx',464 '073xxx-xxx-xxxx-xxxxxx-xxxxxx-xxxxxxx',465 '074xxx-xxx-xxxx-xxxxxxx-xxxxxxxxxxxxx',466 '075xxx-xxx-xxxx-xxxxxxx-xxxxxxxxxxxxx-xxxxxxxxx',467 '076xxx-xxx-xxxx-xxxxxxxxxxxxx-xxxxxxx',468 '077xxx-xxx-xxxx-xxxxxxxxx-xxxxxxx-x2',469 '078xxx-xxx-xxxx-xxx',470 '079xxx-xxx-xxxx-xxxxxxxxxxxx',471 '080xxx-xxx-xxxx-xxxxxxxxx-xxxxxxxx',472 '081xxx-xxx-xxxx-xxxxxxxx-xxxxxxxxx',473 '082xxx-xxx-xxxx-xxxxxxxxx',474 '083xxx-xxx-xxxx-xxxxxxx',475 '084xxx-xxx-xxxx-xxxxxxx-xxxxxx',476 '085xxxx-xxx-xxxxxxx-xxxxx-xxxx',477 '086xxx-xxx-xxxxxxxx-xxxx-xxxxxxxxxx',478 '087xxx-xxx-xxxxxxx-xxxxxx-xxxxxxx',479 '088xxx-xxx-xxxxxxx-xxxxxxxx',480 '089xxx-xxx-xxxxxxxx-xxxxxxx',481 '090xxx-xxx-xxxxxxxx-xxxxxxx-xxxxxx',482 '091xxx-xxxx-xxxxxxxxxx',483 '092xxx-xxx-xxxxxx-xx',484 '093xxx-xxx-xxxxxxx',485 '094xxx-xxx-xxxxxxx-xxxxx',486 '095xxx-xxx-xxxxxxxxxx',487 '096xxx-xxx-xxxxxxxxxxxxxxx',488 '098xxx-xxx-xxxxxxxxxxxxxxxxx',489 '098xxx-xxx-xxxxxxxx-xxxxxxx-xxxxxxx',490 '099xxx-xxx-xxxxxxxx-xx',491 '100xxx-xxx-xxxx-xxxxxxxxxxx-xxxxxxx',492 '101xxx-xxxx-xxxxxxxxxxxxxxxx',493 '102xxx-xxx-xxxxxxxxxxxxxxxxxx',494 '103xxx-xxx-xxxxxxxx-xxxxxxxxxxxx-xxx',495 '104xxx-xxx-xxxx-xxxxxxx',496 '105xxx-xxx-xxx-xxxxxxx-xxxxxx-xxxxxxx',497 '106xxx-xxx-xxx-xxxx-xxxx-xxx-xxxxxxxxx',498 '107xxx-xxx-xxxxxxxxx',499 '108xxx-xxx-xxx-xxxxxxx',500 '109xxx-xxx-xxx-xxxxxxx',501 '110xxx-xxxx-xxxxx',502 '111xxx-xxx-xxx-xxxx-xxxx',503 '112xxx-xxx-xxx-xxxxxxx',504 '113xxx-xxx-xxx-xxxxxxx',505 '114xxx-xxx-xxxxxxxxxxxx-xxxxxxx',506 '115xxx-xxx-xxx-xxxx-xxxx',507 '116xxx-xxx-xxx-xxxxxxxx-xxxxxxxx',508 '117xxx-xxx-xxxxxxx',509 '118xxx-xxx-xxxxxxxx-xxxxxxx',510 '119xxx-xxx-xxxxxx',511 '120xxxx-xxx-xxxxxxxxxx',512 '121xxx-xxx-xxxxxx-xxxxxx-xxxxxxx',513 '122xxx-xxx-xxxxxx-xxxxxxx',514 '123xxx-xxx-xxxxxx-xx',515 '124xxxx-xxx-xxx-xxxx-xxxxxxx',516 '125xxx-xxx-xxxxxxxxxxx',517 '126xxx-xxx-xxxxxxxxxxx-xxxxxxx',518 '127xxx-xxx-xxxxxx-xxx-xxxxxx',519 '128xxx-xxx-xxxxxxxxxx',520 '129xxx-xxx-xxxxxxxxxx-xxx',521 '130xxx-xxx-xxxxx-xxxxxxx',522 '131xxx-xxx-xxxxxx-xxxxxxxx-xxx',523 '132xxx-xxx-xxxxx-xxxxxxxx-xxxxxx',524 '133xxx-xxx-xxxxx-xx',525 '134xxx-xxx-xxxx-xxxxxxx-xxx-xxxxxxx',526 '135xxx-xxx-xxxx-xxxxxxx-xxx-xxxxxx',527 '136xxx-xxx-xxxxxxxxxxxxxxx',528 '137xxx-xxx-xxx',529 '138xxx-xxx-xxxxxxx-xxxxxxx',530 '139xxx-xxx-xxxxxxx-xxx-xxxxxxx',531 '140xxx-xxx-xxxxxxxxx-xxxxxx-xxxxxxx',532 '141xxx-xxx-xxxxxxxxxx-xxxx-xxxxxxx',533 '142xxx-xxx-xx-xxxxxxxxxx-xxxxx',534 '143xxx-xxx-xxxxxxxxxxxxxx-xxxxxxx',535 '144xxx-xxx-xxxxxxxxxxxxxxxxx',536 '145xxx-xxx-xxxxxxxx-xxxxxxx',537 '146xxx-xxx-xxxxxxxxxxxxx-xxxxxxx',538 '147xxx-xxx-xxxxxxx-xxxxxxx',539 '148xxx-xxx-xxxxxx-xxxxxxx',540 '149xxx-xxx-xxxxx-xxxxx',541 '150xxx-xxx-xxxxx-xxxx',542 '151xxx-xxx-xxxxxxxxxxxxxxxxx',543 '152xxx-xxx-xxxxxxxxxxxxxxxxxxx',544 '153xxx-xxx-xxxxxxxxx-xxxxx-xxx',545 '154xxx-xxx-xxxxxxxx-xxxxx-xxxx-xxxx',546 '155xxx-xxx-xxxxxxxx-xxxxxxxxxxxx-xxxx',547 '156xxx-xxx-xxxxxxxx-xx-xxx-xxxxxxxx',548 '157xxx-xxx-xxxxxxxx-xxxxxx-xxxxxxx',549 '158xxx-xxx-xxxxxxxxxx',550 '159xxx-xxx-xxxx-xxxxxx',551 '160xxx-xxx-xxxxxxxxxx',552 '161xxx-xxx-xxxxxxxxxxxxx',553 '162xxx-xxx-xxxxxxxxxxxxxxxx',554 '163xxx-xxx-xxxxx-xxxxxx-xxxxxxx',555 '164xxx-xxx-xxxxxxx-xxxxxxxxxxxxx',556 '165xxx-xxx-xxxxxxxxxxxxxx-xxxxxxx',557 '166xxx-xxx-xxxxxxxxx-xxxxxxx-x2',558 '167xxx-xxx-xxx',559 '168xxx-xxx-xxxxxxxxxxxx',560 '169xxx-xxx-xxxxxxxxx-xxxxxxxx',561 '170xxx-xxx-xxxxxxxxx-xxx-xxxxxxx',562 '171xxx-xxx-xxxxxxxxx',563 '172xxx-xxxx-xxxxxxxxx',564 '173xxx-xxx',565 '174xxx-xxxxxx-xxxxxxx',566 '175xxx-xxxxxx-xxxxxx-xxxx',567 '176xxx-xxxxxx-xxxxx',568 '177xxx-xxxxx-xxxxxxxx',569 '178xxx-xxxxxx',570 '179xxx-xxxxxxx-xxxx',571 '180xxx-xxxxxxx-xxxx-xxxx',572 '181xxx-xxxxxxx-xxxx-xxxxxxx',573 '182xxx-xxxxxxx-xxxx-xxxxxxxxxxxxxxx',574 '183xxx-xxxxxxxx-xxxx-xxxxx',575 '184xxx-xxxxxxx-xxxx-xxxxxxx',576 '185xxx-xxxxxxx-xxxx-xxxxxxxx-xxxxxxx',577 '186xxx-xxxxxxx-xxxx-xxx',578 '187xxx-xxxxxxx-xxxx-xxxxxxx-xxx-xxxxxxx',579 '188xxx-xxxxxxx-xxxx-xxxxxxxxxxxxxx-xxxxxxx',580 '189xxx-xxxxxxxx-xxxx-xxxxxxxxxxxxxxxxx',581 '190xxx-xxxxxxx-xxxx-xxxxx-xxxxxx-xxxxxxx',582 '191xxx-xxxxxxx-xxxxxxxxxx',583 '192xxx-xxxxxxx-xxxxxxx',584 '193xxx-xxxxxxx-xxxxxxxxxxxxxxx',585 '194xxx-xxxxxxx-xxxxx',586 '195xxx-xxxxxxx-xxxxxxx',587 '196xxx-xxxxxxx-xxxxxxxx-xxxxxxx',588 '197xxx-xxxxxxx-xxx',589 '198xxx-xxxxxxx-xxxxxxx-xxx-xxxxxxx',590 '199xxx-xxxxxxx-xxxxxxxxxxxxxx-xxxxxxx',591 '200xxx-xxxxxxxx-xxxxxxxxxxxxxxxxx',592 '201xxx-xxxxxxx-xxxxx-xxxxxx-xxxxxxx',593 '202xxx-xxx',594 '203xxx-xxx-xxxxxx',595 '204xxxxxxxxx-xxx',596 '205xxxxxxxxxxx-xxx',597 '206xxxxxxxxx-xxxxxxx',598 '207xxxx-xxxxxx-xxxxxxxxxxx-xxxxx1',599 '208xxxx-xxxxxxxx-xxxxxxxx-xxxxx1',600 '209xxxx-xxxxxxx-xxxxxxx-xxxxx1',601 '209xxxx-xxxxxxx-xxxxxxx-xxxxx2',602 '210xxxx-xxxx-xxxxxxx-xxxxx1',603 '211xxxx-xxxxx-xxxxxxxx1-xxxxx1',604 '212xxxx-xxxx-xxxxxxxx2-xxxxx1',605 '213xxxx-xxxx-xxxxxxx1-xxxxx1',606 '214xxxx-xxxx-xxxxxxx2-xxxxx1',607 '215xxxxxxxxx-xxxxxx',608 '216xxxxxxxxx-xxxxxxx',609 '217xxxxxxxxx-xxxx',610];611612{613 'yyyyyyyyy': {614 local Func3(z, n) = utils.Func3('yyyyyyyyy', z, n),615616 global: {617 [n]: {618 members: [619 Func3(z, '%s-gggg-%s-%s' % [n, z, suffix]),620 for z in ['ooooooo-a', 'ooooooo-b', 'ooooooo-c',621 'ooooooo-a', 'ooooooo-b', 'ooooooo-c']622 for suffix in ['a', 'b', 'c']623 ],624 }625 for n in long_list626 },627 },628}629630```631</details>632633| Command | Mean [ms] | Min [ms] | Max [ms] | Relative |634|:---|---:|---:|---:|---:|635| `Rust` | 12.6 ± 0.1 | 12.3 | 12.9 | 1.00 |636| `Rust (alternative, rsjsonnet)` | 49.7 ± 1.0 | 47.3 | 53.0 | 3.96 ± 0.09 |637| `Go` | 6858.1 ± 34.9 | 6815.9 | 6951.8 | 546.32 ± 6.87 |638| `Scala` | 382.3 ± 3.9 | 371.7 | 387.1 | 30.46 ± 0.47 |639| `C++` | 24472.7 ± 155.7 | 24230.3 | 24799.3 | 1949.51 ± 25.63 |640641### Realistic 2642643<details>644<summary>Source</summary>645646```jsonnet647local rfc3339(timestamp) = '1970-01-01T00:00:00Z';648649local name1(a, b, c) =650 'AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA%sBBBBBBB%sCCCCCCCCCCC%s'651 % [a, b, c];652653local name2(x) =654 'XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX%s' % x;655656local T1 = 'PPPPPPPPPPPPPPPPPPPPPPP';657local T2 = 'QQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQ';658659local LOCATIONS = [660 'europe-west1-b',661 'europe-west1-c',662 'europe-west1-d',663 'europe-west2-a',664 'europe-west2-b',665 'europe-west2-c',666 'europe-west3-a',667 'europe-west3-b',668 'europe-west3-c',669 'europe-west4-a',670 'europe-west4-b',671 'europe-west4-c',672 'us-central1-a',673 'us-central1-b',674 'us-central1-c',675 'us-central1-f',676 'us-east1-b',677 'us-east1-c',678 'us-east1-d',679 'us-east4-a',680 'us-east4-b',681 'us-east4-c',682 'us-west1-a',683 'us-west1-b',684 'us-west1-c',685];686687688// The return value is a function to allow it to be parameterized.689function(690 timestamp=0,691 x='xxxxxxxxxxxxxxxxxxx',692 prefix='prefix',693 num1=50,694 count=25,695 offset=0,696)697 local rfc_timestamp = rfc3339(timestamp);698699 local func1(i) =700 local location = LOCATIONS[i % std.length(LOCATIONS)];701 [702 local name = '%s-%000d-%000d' % [prefix, i, j];703 {704 field_zz1: rfc_timestamp,705 fie_z2: {706 field_z3: name1(x, location, name),707 field_zzzzzzzzzz4: name2(x),708 field_zzz5: [name],709 field_z6: T1,710 field_z7: location,711 fi_8: '???',712 fiel_z9: '99',713 },714 }715 for j in std.range(0, num1 - 1)716 ];717718 local func2(i) =719 local location = LOCATIONS[i % std.length(LOCATIONS)];720 local all = [721 name1(x, location, '%s-%000d-%000d' % [prefix, i, j])722 for j in std.range(0, num1 - 1)723 ];724 [725 {726 field_yy1: rfc_timestamp,727 field_yyyyy2: 'EEEE',728 field_yyyyy3: {729 field_y4: T2,730 field_yyyyyyy5: p,731 field_yyyyyyy6: q,732 },733 }734 for p in all735 for q in all736 if p != q737 ];738739740 {741 field_x1: '-----',742 field_xxxxxxxxxxxxxxxx2: std.join([], [743 func1(offset * count + i)744 for i in std.range(0, count - 1)745 ]),746 field_xxxxxxxxxxxxxxxxxxxxxx3: std.join([], [747 func2(offset * count + i)748 for i in std.range(0, count - 1)749 ]),750 }751752753```754</details>755756| Command | Mean [ms] | Min [ms] | Max [ms] | Relative |757|:---|---:|---:|---:|---:|758| `Rust` | 259.9 ± 4.4 | 250.9 | 266.7 | 1.00 |759| `Rust (alternative, rsjsonnet)` | 550.2 ± 16.6 | 531.9 | 600.7 | 2.12 ± 0.07 |760| `Go` | 6732.4 ± 51.4 | 6660.2 | 6858.6 | 25.90 ± 0.48 |761| `Scala` | 675.4 ± 10.9 | 667.3 | 720.0 | 2.60 ± 0.06 |762| `C++` | 26414.5 ± 259.9 | 25948.9 | 26934.4 | 101.63 ± 1.99 |763764## Benchmarks from C++ jsonnet (/benchmarks)765766### Tail call767768<details>769<summary>Source</summary>770771```jsonnet772/*773Copyright 2015 Google Inc. All rights reserved.774775Licensed under the Apache License, Version 2.0 (the "License");776you may not use this file except in compliance with the License.777You may obtain a copy of the License at778779 http://www.apache.org/licenses/LICENSE-2.0780781Unless required by applicable law or agreed to in writing, software782distributed under the License is distributed on an "AS IS" BASIS,783WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.784See the License for the specific language governing permissions and785limitations under the License.786*/787788local sum(x) =789 if x == 0 then790 0791 else792 x + sum(x - 1);793sum(300)794795```796</details>797798| Command | Mean [ms] | Min [ms] | Max [ms] | Relative |799|:---|---:|---:|---:|---:|800| `Rust` | 1.8 ± 0.1 | 1.6 | 2.6 | 1.00 |801| `Rust (alternative, rsjsonnet)` | 3.1 ± 0.1 | 2.8 | 3.4 | 1.69 ± 0.12 |802| `Go` | 5.3 ± 0.2 | 4.9 | 5.9 | 2.90 ± 0.20 |803| `Scala` | 287.4 ± 1.2 | 285.4 | 288.9 | 156.55 ± 9.92 |804| `C++` | 32.1 ± 0.3 | 31.6 | 33.0 | 17.49 ± 1.12 |805806### Inheritance recursion807808<details>809<summary>Source</summary>810811```jsonnet812/*813Copyright 2015 Google Inc. All rights reserved.814815Licensed under the Apache License, Version 2.0 (the "License");816you may not use this file except in compliance with the License.817You may obtain a copy of the License at818819 http://www.apache.org/licenses/LICENSE-2.0820821Unless required by applicable law or agreed to in writing, software822distributed under the License is distributed on an "AS IS" BASIS,823WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.824See the License for the specific language governing permissions and825limitations under the License.826*/827828local Fib = {829 n: 1,830 local outer = self,831 r: if self.n <= 1 then 1 else (Fib { n: outer.n - 1 }).r + (Fib { n: outer.n - 2 }).r,832};833834(Fib { n: 25 }).r835836```837</details>838839| Command | Mean [ms] | Min [ms] | Max [ms] | Relative |840|:---|---:|---:|---:|---:|841| `Rust` | 376.1 ± 5.2 | 364.3 | 383.7 | 1.00 |842| `Rust (alternative, rsjsonnet)` | 496.7 ± 13.0 | 470.6 | 506.8 | 1.32 ± 0.04 |843| `Go` | 873.9 ± 7.1 | 859.3 | 888.0 | 2.32 ± 0.04 |844| `Scala` | 420.8 ± 6.3 | 413.9 | 437.1 | 1.12 ± 0.02 |845| `C++` | 2647.5 ± 14.2 | 2630.9 | 2675.6 | 7.04 ± 0.10 |846847### Simple recursive call848849<details>850<summary>Source</summary>851852```jsonnet853/*854Copyright 2015 Google Inc. All rights reserved.855856Licensed under the Apache License, Version 2.0 (the "License");857you may not use this file except in compliance with the License.858You may obtain a copy of the License at859860 http://www.apache.org/licenses/LICENSE-2.0861862Unless required by applicable law or agreed to in writing, software863distributed under the License is distributed on an "AS IS" BASIS,864WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.865See the License for the specific language governing permissions and866limitations under the License.867*/868869local fibonacci(n) =870 if n <= 1 then871 1872 else873 fibonacci(n - 1) + fibonacci(n - 2);874875fibonacci(25)876877```878</details>879880| Command | Mean [ms] | Min [ms] | Max [ms] | Relative |881|:---|---:|---:|---:|---:|882| `Rust` | 81.3 ± 0.3 | 80.9 | 82.4 | 1.00 |883| `Rust (alternative, rsjsonnet)` | 202.3 ± 12.0 | 183.1 | 237.6 | 2.49 ± 0.15 |884| `Go` | 349.4 ± 1.7 | 347.2 | 354.2 | 4.30 ± 0.03 |885| `Scala` | 322.5 ± 3.0 | 318.7 | 330.7 | 3.97 ± 0.04 |886| `C++` | 193.5 ± 0.9 | 191.4 | 194.8 | 2.38 ± 0.01 |887888### Foldl string concat889890<details>891<summary>Source</summary>892893```jsonnet894std.foldl(function(e, res) e + res, std.makeArray(20000, function(i) 'aaaaa'), '')895896```897</details>898899| Command | Mean [ms] | Min [ms] | Max [ms] | Relative |900|:---|---:|---:|---:|---:|901| `Rust` | 8.9 ± 0.1 | 8.6 | 9.3 | 1.00 |902| `Rust (alternative, rsjsonnet)` | 303.1 ± 3.8 | 297.6 | 308.1 | 34.06 ± 0.68 |903| `Go` | 50.9 ± 0.8 | 48.3 | 52.2 | 5.72 ± 0.13 |904| `Scala` | 550.6 ± 5.5 | 542.8 | 563.7 | 61.86 ± 1.13 |905| `C++` | 902.6 ± 4.8 | 891.4 | 912.1 | 101.41 ± 1.65 |906907### Array sorts908909> Note: No results for Scala, sjsonnet doesn't support keyF in std.sort: https://github.com/databricks/sjsonnet/issues/204910911<details>912<summary>Source</summary>913914```jsonnet915// A benchmark for builtin sort916917local reverse = std.reverse;918local sort = std.sort;919920true921&& std.assertEqual(std.range(1, 500), sort(std.range(1, 500)))922&& std.assertEqual(std.range(1, 1000), sort(std.range(1, 1000)))923&& std.assertEqual(reverse(std.range(1, 1000)), sort(std.range(1, 1000), keyF=function(x) -x))924&& std.assertEqual(std.range(1, 1000), sort(reverse(std.range(1, 1000))))925&& std.assertEqual(std.makeArray(2000, function(i) std.floor((i + 2) / 2)), sort(std.range(1, 1000) + reverse(std.range(1, 1000))))926927```928</details>929930| Command | Mean [ms] | Min [ms] | Max [ms] | Relative |931|:---|---:|---:|---:|---:|932| `Rust` | 3.2 ± 0.2 | 2.9 | 4.1 | 1.00 |933| `Rust (alternative, rsjsonnet)` | 14.4 ± 0.6 | 13.1 | 16.2 | 4.46 ± 0.28 |934| `Go` | 12.1 ± 0.2 | 11.4 | 12.8 | 3.74 ± 0.20 |935| `C++` | 3637.1 ± 24.9 | 3557.4 | 3664.7 | 1128.64 ± 56.81 |936937### Lazy array938939<details>940<summary>Source</summary>941942```jsonnet943local f2(f) = function(x) f(f(x));944local id(x) = x;945946local slowId = std.makeArray(20, function(i) if i == 0 then id else f2(slowId[i - 1]));947948slowId[15](42)949950```951</details>952953| Command | Mean [ms] | Min [ms] | Max [ms] | Relative |954|:---|---:|---:|---:|---:|955| `Rust` | 54.1 ± 1.1 | 52.3 | 56.3 | 1.30 ± 0.03 |956| `Rust (alternative, rsjsonnet)` | 41.7 ± 0.7 | 39.6 | 43.8 | 1.00 |957| `Go` | 596.5 ± 5.2 | 585.1 | 606.9 | 14.30 ± 0.29 |958| `Scala` | 306.6 ± 1.6 | 303.5 | 310.4 | 7.35 ± 0.14 |959| `C++` | 184.5 ± 1.8 | 182.0 | 187.9 | 4.42 ± 0.09 |960961### Inheritance function recursion962963<details>964<summary>Source</summary>965966```jsonnet967local fibnext = {968 a: super.a + super.b,969 b: super.a,970};971local fib(n) =972 if n == 0 then973 { a: 1, b: 1 }974 else975 fib(n - 1) + fibnext;976977fib(25)978979```980</details>981982| Command | Mean [ms] | Min [ms] | Max [ms] | Relative |983|:---|---:|---:|---:|---:|984| `Rust` | 1.6 ± 0.1 | 1.5 | 2.5 | 1.00 |985| `Rust (alternative, rsjsonnet)` | 2.9 ± 0.1 | 2.7 | 3.7 | 1.78 ± 0.13 |986| `Go` | 2.4 ± 0.1 | 2.1 | 2.9 | 1.48 ± 0.12 |987| `Scala` | 293.2 ± 1.5 | 289.9 | 296.1 | 178.20 ± 12.35 |988| `C++` | 999.1 ± 9.2 | 974.4 | 1010.9 | 607.23 ± 42.34 |989990### String strips991992<details>993<summary>Source</summary>994995```jsonnet996// This string must be longer than max stack frames997local veryLongString = std.join('', std.repeat(['e'], 510));998999std.assertEqual(std.stripChars(veryLongString + 'ok' + veryLongString, 'e'), 'ok') &&1000std.assertEqual(std.lstripChars(veryLongString + 'ok', 'e'), 'ok') &&1001std.assertEqual(std.rstripChars('ok' + veryLongString, 'e'), 'ok') &&10021003true10041005```1006</details>10071008| Command | Mean [ms] | Min [ms] | Max [ms] | Relative |1009|:---|---:|---:|---:|---:|1010| `Rust` | 8.6 ± 0.2 | 8.4 | 9.5 | 1.00 |1011| `Rust (alternative, rsjsonnet)` | 18.4 ± 0.4 | 17.6 | 20.8 | 2.13 ± 0.06 |1012| `Go` | 11.2 ± 0.2 | 10.4 | 11.9 | 1.29 ± 0.04 |1013| `Scala` | 294.9 ± 2.0 | 292.2 | 301.9 | 34.10 ± 0.65 |1014| `C++` | 37345.3 ± 208.2 | 36567.2 | 37689.0 | 4318.10 ± 80.13 |10151016### Big object10171018<details>1019<summary>Source</summary>10201021```jsonnet1022// Generator source1023local n = 2000;10241025local objLocal(name, body) = 'local ' + name + ' = ' + body + ',';1026local objField(name, body) = name + ': ' + body + ',';10271028local allLocals =1029 std.makeArray(n, function(i) objLocal('l' + i, '1'));10301031local allFields =1032 std.makeArray(n, function(i) objField('f' + i, '2'));10331034local indent = ' ';1035local indentAndSeparate(s) = indent + s + '\n';10361037local objContents = std.map(indentAndSeparate, allLocals + allFields);10381039local objectBody = std.join('', objContents);1040'{\n' + objectBody + '}\n'10411042```1043</details>10441045| Command | Mean [ms] | Min [ms] | Max [ms] | Relative |1046|:---|---:|---:|---:|---:|1047| `Rust` | 2.2 ± 0.1 | 1.9 | 3.0 | 1.00 |1048| `Rust (alternative, rsjsonnet)` | 3.2 ± 0.1 | 2.9 | 3.5 | 1.46 ± 0.10 |1049| `Go` | 4.1 ± 0.1 | 3.7 | 4.6 | 1.85 ± 0.13 |1050| `Scala` | 292.3 ± 2.9 | 289.3 | 304.0 | 132.11 ± 8.64 |1051| `C++` | 28.3 ± 0.3 | 27.7 | 29.1 | 12.80 ± 0.84 |10521053## Benchmarks from Go jsonnet (builtins)10541055### std.base6410561057<details>1058<summary>Source</summary>10591060```jsonnet1061{1062 foo: [1063 std.base64("Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Sed turpis tincidunt id aliquet risus. Eget mauris pharetra et ultrices neque ornare aenean euismod. Diam quis enim lobortis scelerisque fermentum. Varius duis at consectetur lorem donec massa sapien. Diam sit amet nisl suscipit adipiscing bibendum est ultricies integer. Lectus urna duis convallis convallis tellus. Nibh ipsum consequat nisl vel pretium lectus quam id leo. Feugiat in ante metus dictum at tempor commodo. Velit dignissim sodales ut eu sem integer. Dictum sit amet justo donec. Scelerisque mauris pellentesque pulvinar pellentesque habitant morbi tristique senectus. Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Sed turpis tincidunt id aliquet risus. Eget mauris pharetra et ultrices neque ornare aenean euismod. Diam quis enim lobortis scelerisque fermentum. Varius duis at consectetur lorem donec massa sapien. Diam sit amet nisl suscipit adipiscing bibendum est ultricies integer. Lectus urna duis convallis convallis tellus. Nibh ipsum consequat nisl vel pretium lectus quam id leo. Feugiat in ante metus dictum at tempor commodo. Velit dignissim sodales ut eu sem integer. Dictum sit amet justo donec. Scelerisque mauris pellentesque pulvinar pellentesque habitant morbi tristique senectus. Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Sed turpis tincidunt id aliquet risus. Eget mauris pharetra et ultrices neque ornare aenean euismod. Diam quis enim lobortis scelerisque fermentum. Varius duis at consectetur lorem donec massa sapien. Diam sit amet nisl suscipit adipiscing bibendum est ultricies integer. Lectus urna duis convallis convallis tellus. Nibh ipsum consequat nisl vel pretium lectus quam id leo. Feugiat in ante metus dictum at tempor commodo. Velit dignissim sodales ut eu sem integer. Dictum sit amet justo donec. Scelerisque mauris pellentesque pulvinar pellentesque habitant morbi tristique senectus.Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Sed turpis tincidunt id aliquet risus. Eget mauris pharetra et ultrices neque ornare aenean euismod. Diam quis enim lobortis scelerisque fermentum. Varius duis at consectetur lorem donec massa sapien. Diam sit amet nisl suscipit adipiscing bibendum est ultricies integer. Lectus urna duis convallis convallis tellus. Nibh ipsum consequat nisl vel pretium lectus quam id leo. Feugiat in ante metus dictum at tempor commodo. Velit dignissim sodales ut eu sem integer. Dictum sit amet justo donec. Scelerisque mauris pellentesque pulvinar pellentesque habitant morbi tristique senectus. Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Sed turpis tincidunt id aliquet risus. Eget mauris pharetra et ultrices neque ornare aenean euismod. Diam quis enim lobortis scelerisque fermentum. Varius duis at consectetur lorem donec massa sapien. Diam sit amet nisl suscipit adipiscing bibendum est ultricies integer. Lectus urna duis convallis convallis tellus. Nibh ipsum consequat nisl vel pretium lectus quam id leo. Feugiat in ante metus dictum at tempor commodo. Velit dignissim sodales ut eu sem integer. Dictum sit amet justo donec. Scelerisque mauris pellentesque pulvinar pellentesque habitant morbi tristique senectus. Scelerisque mauris pellentesque pulvinar pellentesque habitant morbi tristique senectus. Scelerisque mauris pellentesque pulvinar pellentesque habitant morbi tristique senectus. Scelerisque mauris pellentesque pulvinar pellentesque habitant morbi tristique senectus. Scelerisque mauris pellentesque pulvinar pellentesque habitant morbi tristique senectus. Scelerisque mauris pellentesque pulvinar pellentesque habitant morbi tristique senectus.") for i in std.range(0,100)1064 ],1065}1066```1067</details>10681069| Command | Mean [ms] | Min [ms] | Max [ms] | Relative |1070|:---|---:|---:|---:|---:|1071| `Rust` | 2.7 ± 0.1 | 2.4 | 3.4 | 1.00 |1072| `Rust (alternative, rsjsonnet)` | 2195.9 ± 48.5 | 2098.1 | 2229.6 | 804.07 ± 39.58 |1073| `Go` | 17.0 ± 0.3 | 16.1 | 17.7 | 6.22 ± 0.29 |1074| `Scala` | 313.8 ± 1.2 | 311.3 | 316.1 | 114.91 ± 5.07 |1075| `C++` | 14621.6 ± 110.0 | 14473.9 | 14774.9 | 5354.05 ± 238.94 |10761077### std.base64Decode10781079<details>1080<summary>Source</summary>10811082```jsonnet1083{1084 foo: [1085 std.base64Decode("TG9yZW0gaXBzdW0gZG9sb3Igc2l0IGFtZXQsIGNvbnNlY3RldHVyIGFkaXBpc2NpbmcgZWxpdCwgc2VkIGRvIGVpdXNtb2QgdGVtcG9yIGluY2lkaWR1bnQgdXQgbGFib3JlIGV0IGRvbG9y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:|---:|---:|---:|1093| `Rust` | 2.6 ± 0.1 | 2.3 | 3.1 | 1.00 |1094| `Rust (alternative, rsjsonnet)` | 7889.2 ± 74.7 | 7711.6 | 8051.1 | 3045.22 ± 138.95 |1095| `Go` | 15.2 ± 0.3 | 14.6 | 16.5 | 5.85 ± 0.28 |1096| `Scala` | 313.0 ± 2.5 | 309.5 | 321.2 | 120.80 ± 5.47 |1097| `C++` | 9930.9 ± 26.5 | 9895.0 | 9997.9 | 3833.33 ± 171.41 |10981099### std.base64DecodeBytes11001101<details>1102<summary>Source</summary>11031104```jsonnet1105{1106 foo: [1107 std.base64DecodeBytes("TG9yZW0gaXBzdW0gZG9sb3Igc2l0IGFtZXQsIGNvbnNlY3RldHVyIGFkaXBpc2NpbmcgZWxpdCwgc2VkIGRvIGVpdXNtb2QgdGVtcG9yIGluY2lkaWR1bnQgdXQgbGFib3JlIGV0IGRvbG9yZSBtYWduYSBhbGlxdWEuIFNlZCB0dXJwaXMgdGluY2lkdW50IGlkIGFsaXF1ZXQgcmlzdXMuIEVnZXQgbWF1cmlzIHBoYXJldHJhIGV0IHVsdHJpY2VzIG5lcXVlIG9ybmFyZSBhZW5lYW4gZXVpc21vZC4gRGlhbSBxdWlzIGVuaW0gbG9ib3J0aXMgc2NlbGVyaXNxdWUgZmVybWVudHVtLiBWYXJpdXMgZHVpcyBhdCBjb25zZWN0ZXR1ciBsb3JlbSBkb25lYyBtYXNzYSBzYXBpZW4uIERpYW0gc2l0IGFtZXQgbmlzbCBzdXNjaXBpdCBhZGlwaXNjaW5nIGJpYmVuZHVtIGVzdCB1bHRyaWNpZXMgaW50ZWdlci4gTGVjdHVzIHVybmEgZHVpcyBjb252YWxsaXMgY29udmFsbGlzIHRlbGx1cy4gTmliaCBpcHN1bSBjb25zZXF1YXQgbmlzbCB2ZWwgcHJldGl1bSBsZWN0dXMgcXVhbSBpZCBsZW8uIEZldWdpYXQgaW4gYW50ZSBtZXR1cyBkaWN0dW0gYXQgdGVtcG9yIGN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hhYml0YW50IG1vcmJpIHRyaXN0aXF1ZSBzZW5lY3R1cy4gU2NlbGVyaXNxdWUgbWF1cmlzIHBlbGxlbnRlc3F1ZSBwdWx2aW5hciBwZWxsZW50ZXNxdWUgaGFiaXRhbnQgbW9yYmkgdHJpc3RpcXVlIHNlbmVjdHVzLiBTY2VsZXJpc3F1ZSBtYXVyaXMgcGVsbGVudGVzcXVlIHB1bHZpbmFyIHBlbGxlbnRlc3F1ZSBoYWJpdGFudCBtb3JiaSB0cmlzdGlxdWUgc2VuZWN0dXMuIFNjZWxlcmlzcXVlIG1hdXJpcyBwZWxsZW50ZXNxdWUgcHVsdmluYXIgcGVsbGVudGVzcXVlIGhhYml0YW50IG1vcmJpIHRyaXN0aXF1ZSBzZW5lY3R1cy4=") for i in std.range(0,100)1108 ],1109}1110```1111</details>11121113| Command | Mean [ms] | Min [ms] | Max [ms] | Relative |1114|:---|---:|---:|---:|---:|1115| `Rust` | 34.8 ± 0.5 | 33.4 | 36.0 | 1.00 |1116| `Rust (alternative, rsjsonnet)` | 8116.2 ± 37.2 | 8049.1 | 8176.2 | 233.52 ± 3.24 |1117| `Go` | 271.1 ± 2.3 | 267.1 | 275.7 | 7.80 ± 0.12 |1118| `Scala` | 357.2 ± 2.3 | 353.5 | 363.4 | 10.28 ± 0.15 |1119| `C++` | 9653.7 ± 22.5 | 9621.4 | 9694.3 | 277.75 ± 3.69 |11201121### std.base64 (byte array)11221123<details>1124<summary>Source</summary>11251126```jsonnet1127{1128 foo: [1129 std.base64([76,111,114,101,109,32,105,112,115,117,109,32,100,111,108,111,114,32,115,105,116,32,97,109,101,116,44,32,99,111,110,115,101,99,116,101,116,117,114,32,97,100,105,112,105,115,99,105,110,103,32,101,108,105,116,44,32,115,101,100,32,100,111,32,101,105,117,115,109,111,100,32,116,101,109,112,111,114,32,105,110,99,105,100,105,100,117,110,116,32,117,116,32,108,97,98,111,114,101,32,101,116,32,100,111,108,111,114,101,32,109,97,103,110,97,32,97,108,105,113,117,97,46,32,83,101,100,32,116,117,114,112,105,115,32,116,105,110,99,105,100,117,110,116,32,105,100,32,97,108,105,113,117,101,116,32,114,105,115,117,115,46,32,69,103,101,116,32,109,97,117,114,105,115,32,112,104,97,114,101,116,114,97,32,101,116,32,117,108,116,114,105,99,101,115,32,110,101,113,117,101,32,111,114,110,97,114,101,32,97,101,110,101,97,110,32,101,117,105,115,109,111,100,46,32,68,105,97,109,32,113,117,105,115,32,101,110,105,109,32,108,111,98,111,114,116,105,115,32,115,99,101,108,101,114,105,115,113,117,101,32,102,101,114,109,101,110,116,117,109,46,32,86,97,114,105,117,115,32,100,117,105,115,32,97,116,32,99,111,110,115,101,99,116,101,116,117,114,32,108,111,114,101,109,32,100,111,110,101,99,32,109,97,115,115,97,32,115,97,112,105,101,110,46,32,68,105,97,109,32,115,105,116,32,97,109,101,116,32,110,105,115,108,32,115,117,115,99,105,112,105,116,32,97,100,105,112,105,115,99,105,110,103,32,98,105,98,101,110,100,117,109,32,101,115,116,32,117,108,116,114,105,99,105,101,115,32,105,110,116,101,103,101,114,46,32,76,101,99,116,117,115,32,117,114,110,97,32,100,117,105,115,32,99,111,110,118,97,108,108,105,115,32,99,111,110,118,97,108,108,105,115,32,116,101,108,108,117,115,46,32,78,105,98,104,32,105,112,115,117,109,32,99,111,110,115,101,113,117,97,116,32,110,105,115,108,32,118,101,108,32,112,114,101,116,105,117,109,32,108,101,99,116,117,115,32,113,117,97,109,32,105,100,32,108,101,111,46,32,70,101,117,103,105,97,116,32,105,110,32,97,110,116,101,32,109,101,116,117,115,32,100,105,99,116,117,109,32,97,116,32,116,101,109,112,111,114,32,99,111,109,109,111,100,111,46,32,86,101,108,105,116,32,100,105,103,110,105,115,115,105,109,32,115,111,100,97,108,101,115,32,117,116,32,101,117,32,115,101,109,32,105,110,116,101,103,101,114,46,32,68,105,99,116,117,109,32,115,105,116,32,97,109,101,116,32,106,117,115,116,111,32,100,111,110,101,99,46,32,83,99,101,108,101,114,105,115,113,117,101,32,109,97,117,114,105,115,32,112,101,108,108,101,110,116,101,115,113,117,101,32,112,117,108,118,105,110,97,114,32,112,101,108,108,101,110,116,101,115,113,117,101,32,104,97,98,105,116,97,110,116,32,109,111,114,98,105,32,116,114,105,115,116,105,113,117,101,32,115,101,110,101,99,116,117,115,46,32,76,111,114,101,109,32,105,112,115,117,109,32,100,111,108,111,114,32,115,105,116,32,97,109,101,116,44,32,99,111,110,115,101,99,116,101,116,117,114,32,97,100,105,112,105,115,99,105,110,103,32,101,108,105,116,44,32,115,101,100,32,100,111,32,101,105,117,115,109,111,100,32,116,101,109,112,111,114,32,105,110,99,105,100,105,100,117,110,116,32,117,116,32,108,97,98,111,114,101,32,101,116,32,100,111,108,111,114,101,32,109,97,103,110,97,32,97,108,105,113,117,97,46,32,83,101,100,32,116,117,114,112,105,115,32,116,105,110,99,105,100,117,110,116,32,105,100,32,97,108,105,113,117,101,116,32,114,105,115,117,115,46,32,69,103,101,116,32,109,97,117,114,105,115,32,112,104,97,114,101,116,114,97,32,101,116,32,117,108,116,114,105,99,101,115,32,110,101,113,117,101,32,111,114,110,97,114,101,32,97,101,110,101,97,110,32,101,117,105,115,109,111,100,46,32,68,105,97,109,32,113,117,105,115,32,101,110,105,109,32,108,111,98,111,114,116,105,115,32,115,99,101,108,101,114,105,115,113,117,101,32,102,101,114,109,101,110,116,117,109,46,32,86,97,114,105,117,115,32,100,117,105,115,32,97,116,32,99,111,110,115,101,99,116,101,116,117,114,32,108,111,114,101,109,32,100,111,110,101,99,32,109,97,115,115,97,32,115,97,112,105,101,110,46,32,68,105,97,109,32,115,105,116,32,97,109,101,116,32,110,105,115,108,32,115,117,115,99,105,112,105,116,32,97,100,105,112,105,115,99,105,110,103,32,98,105,98,101,110,100,117,109,32,101,115,116,32,117,108,116,114,105,99,105,101,115,32,105,110,116,101,103,101,114,46,32,76,101,99,116,117,115,32,117,114,110,97,32,100,117,105,115,32,99,111,110,118,97,108,108,105,115,32,99,111,110,118,97,108,108,105,115,32,116,101,108,108,117,115,46,32,78,105,98,104,32,105,112,115,117,109,32,99,111,110,115,101,113,117,97,116,32,110,105,115,108,32,118,101,108,32,112,114,101,116,105,117,109,32,108,101,99,116,117,115,32,113,117,97,109,32,105,100,32,108,101,111,46,32,70,101,117,103,105,97,116,32,105,110,32,97,110,116,101,32,109,101,116,117,115,32,100,105,99,116,117,109,32,97,116,32,116,101,109,112,111,114,32,99,111,109,109,111,100,111,46,32,86,101,108,105,116,32,100,105,103,110,105,115,115,105,109,32,115,111,100,97,108,101,115,32,117,116,32,101,117,32,115,101,109,32,105,110,116,101,103,101,114,46,32,68,105,99,116,117,109,32,115,105,116,32,97,109,101,116,32,106,117,115,116,111,32,100,111,110,101,99,46,32,83,99,101,108,101,114,105,115,113,117,101,32,109,97,117,114,105,115,32,112,101,108,108,101,110,116,101,115,113,117,101,32,112,117,108,118,105,110,97,114,32,112,101,108,108,101,110,116,101,115,113,117,101,32,104,97,98,105,116,97,110,116,32,109,111,114,98,105,32,116,114,105,115,116,105,113,117,101,32,115,101,110,101,99,116,117,115,46,32,76,111,114,101,109,32,105,112,115,117,109,32,100,111,108,111,114,32,115,105,116,32,97,109,101,116,44,32,99,111,110,115,101,99,116,101,116,117,114,32,97,100,105,112,105,115,99,105,110,103,32,101,108,105,116,44,32,115,101,100,32,100,111,32,101,105,117,115,109,111,100,32,116,101,109,112,111,114,32,105,110,99,105,100,105,100,117,110,116,32,117,116,32,108,97,98,111,114,101,32,101,116,32,100,111,108,111,114,101,32,109,97,103,110,97,32,97,108,105,113,117,97,46,32,83,101,100,32,116,117,114,112,105,115,32,116,105,110,99,105,100,117,110,116,32,105,100,32,97,108,105,113,117,101,116,32,114,105,115,117,115,46,32,69,103,101,116,32,109,97,117,114,105,115,32,112,104,97,114,101,116,114,97,32,101,116,32,117,108,116,114,105,99,101,115,32,110,101,113,117,101,32,111,114,110,97,114,101,32,97,101,110,101,97,110,32,101,117,105,115,109,111,100,46,32,68,105,97,109,32,113,117,105,115,32,101,110,105,109,32,108,111,98,111,114,116,105,115,32,115,99,101,108,101,114,105,115,113,117,101,32,102,101,114,109,101,110,116,117,109,46,32,86,97,114,105,117,115,32,100,117,105,115,32,97,116,32,99,111,110,115,101,99,116,101,116,117,114,32,108,111,114,101,109,32,100,111,110,101,99,32,109,97,115,115,97,32,115,97,112,105,101,110,46,32,68,105,97,109,32,115,105,116,32,97,109,101,116,32,110,105,115,108,32,115,117,115,99,105,112,105,116,32,97,100,105,112,105,115,99,105,110,103,32,98,105,98,101,110,100,117,109,32,101,115,116,32,117,108,116,114,105,99,105,101,115,32,105,110,116,101,103,101,114,46,32,76,101,99,116,117,115,32,117,114,110,97,32,100,117,105,115,32,99,111,110,118,97,108,108,105,115,32,99,111,110,118,97,108,108,105,115,32,116,101,108,108,117,115,46,32,78,105,98,104,32,105,112,115,117,109,32,99,111,110,115,101,113,117,97,116,32,110,105,115,108,32,118,101,108,32,112,114,101,116,105,117,109,32,108,101,99,116,117,115,32,113,117,97,109,32,105,100,32,108,101,111,46,32,70,101,117,103,105,97,116,32,105,110,32,97,110,116,101,32,109,101,116,117,115,32,100,105,99,116,117,109,32,97,116,32,116,101,109,112,111,114,32,99,111,109,109,111,100,111,46,32,86,101,108,105,116,32,100,105,103,110,105,115,115,105,109,32,115,111,100,97,108,101,115,32,117,116,32,101,117,32,115,101,109,32,105,110,116,101,103,101,114,46,32,68,105,99,116,117,109,32,115,105,116,32,97,109,101,116,32,106,117,115,116,111,32,100,111,110,101,99,46,32,83,99,101,108,101,114,105,115,113,117,101,32,109,97,117,114,105,115,32,112,101,108,108,101,110,116,101,115,113,117,101,32,112,117,108,118,105,110,97,114,32,112,101,108,108,101,110,116,101,115,113,117,101,32,104,97,98,105,116,97,110,116,32,109,111,114,98,105,32,116,114,105,115,116,105,113,117,101,32,115,101,110,101,99,116,117,115,46,76,111,114,101,109,32,105,112,115,117,109,32,100,111,108,111,114,32,115,105,116,32,97,109,101,116,44,32,99,111,110,115,101,99,116,101,116,117,114,32,97,100,105,112,105,115,99,105,110,103,32,101,108,105,116,44,32,115,101,100,32,100,111,32,101,105,117,115,109,111,100,32,116,101,109,112,111,114,32,105,110,99,105,100,105,100,117,110,116,32,117,116,32,108,97,98,111,114,101,32,101,116,32,100,111,108,111,114,101,32,109,97,103,110,97,32,97,108,105,113,117,97,46,32,83,101,100,32,116,117,114,112,105,115,32,116,105,110,99,105,100,117,110,116,32,105,100,32,97,108,105,113,117,101,116,32,114,105,115,117,115,46,32,69,103,101,116,32,109,97,117,114,105,115,32,112,104,97,114,101,116,114,97,32,101,116,32,117,108,116,114,105,99,101,115,32,110,101,113,117,101,32,111,114,110,97,114,101,32,97,101,110,101,97,110,32,101,117,105,115,109,111,100,46,32,68,105,97,109,32,113,117,105,115,32,101,110,105,109,32,108,111,98,111,114,116,105,115,32,115,99,101,108,101,114,105,115,113,117,101,32,102,101,114,109,101,110,116,117,109,46,32,86,97,114,105,117,115,32,100,117,105,115,32,97,116,32,99,111,110,115,101,99,116,101,116,117,114,32,108,111,114,101,109,32,100,111,110,101,99,32,109,97,115,115,97,32,115,97,112,105,101,110,46,32,68,105,97,109,32,115,105,116,32,97,109,101,116,32,110,105,115,108,32,115,117,115,99,105,112,105,116,32,97,100,105,112,105,115,99,105,110,103,32,98,105,98,101,110,100,117,109,32,101,115,116,32,117,108,116,114,105,99,105,101,115,32,105,110,116,101,103,101,114,46,32,76,101,99,116,117,115,32,117,114,110,97,32,100,117,105,115,32,99,111,110,118,97,108,108,105,115,32,99,111,110,118,97,108,108,105,115,32,116,101,108,108,117,115,46,32,78,105,98,104,32,105,112,115,117,109,32,99,111,110,115,101,113,117,97,116,32,110,105,115,108,32,118,101,108,32,112,114,101,116,105,117,109,32,108,101,99,116,117,115,32,113,117,97,109,32,105,100,32,108,101,111,46,32,70,101,117,103,105,97,116,32,105,110,32,97,110,116,101,32,109,101,116,117,115,32,100,105,99,116,117,109,32,97,116,32,116,101,109,112,111,114,32,99,111,109,109,111,100,111,46,32,86,101,108,105,116,32,100,105,103,110,105,115,115,105,109,32,115,111,100,97,108,101,115,32,117,116,32,101,117,32,115,101,109,32,105,110,116,101,103,101,114,46,32,68,105,99,116,117,109,32,115,105,116,32,97,109,101,116,32,106,117,115,116,111,32,100,111,110,101,99,46,32,83,99,101,108,101,114,105,115,113,117,101,32,109,97,117,114,105,115,32,112,101,108,108,101,110,116,101,115,113,117,101,32,112,117,108,118,105,110,97,114,32,112,101,108,108,101,110,116,101,115,113,117,101,32,104,97,98,105,116,97,110,116,32,109,111,114,98,105,32,116,114,105,115,116,105,113,117,101,32,115,101,110,101,99,116,117,115,46,32,76,111,114,101,109,32,105,112,115,117,109,32,100,111,108,111,114,32,115,105,116,32,97,109,101,116,44,32,99,111,110,115,101,99,116,101,116,117,114,32,97,100,105,112,105,115,99,105,110,103,32,101,108,105,116,44,32,115,101,100,32,100,111,32,101,105,117,115,109,111,100,32,116,101,109,112,111,114,32,105,110,99,105,100,105,100,117,110,116,32,117,116,32,108,97,98,111,114,101,32,101,116,32,100,111,108,111,114,101,32,109,97,103,110,97,32,97,108,105,113,117,97,46,32,83,101,100,32,116,117,114,112,105,115,32,116,105,110,99,105,100,117,110,116,32,105,100,32,97,108,105,113,117,101,116,32,114,105,115,117,115,46,32,69,103,101,116,32,109,97,117,114,105,115,32,112,104,97,114,101,116,114,97,32,101,116,32,117,108,116,114,105,99,101,115,32,110,101,113,117,101,32,111,114,110,97,114,101,32,97,101,110,101,97,110,32,101,117,105,115,109,111,100,46,32,68,105,97,109,32,113,117,105,115,32,101,110,105,109,32,108,111,98,111,114,116,105,115,32,115,99,101,108,101,114,105,115,113,117,101,32,102,101,114,109,101,110,116,117,109,46,32,86,97,114,105,117,115,32,100,117,105,115,32,97,116,32,99,111,110,115,101,99,116,101,116,117,114,32,108,111,114,101,109,32,100,111,110,101,99,32,109,97,115,115,97,32,115,97,112,105,101,110,46,32,68,105,97,109,32,115,105,116,32,97,109,101,116,32,110,105,115,108,32,115,117,115,99,105,112,105,116,32,97,100,105,112,105,115,99,105,110,103,32,98,105,98,101,110,100,117,109,32,101,115,116,32,117,108,116,114,105,99,105,101,115,32,105,110,116,101,103,101,114,46,32,76,101,99,116,117,115,32,117,114,110,97,32,100,117,105,115,32,99,111,110,118,97,108,108,105,115,32,99,111,110,118,97,108,108,105,115,32,116,101,108,108,117,115,46,32,78,105,98,104,32,105,112,115,117,109,32,99,111,110,115,101,113,117,97,116,32,110,105,115,108,32,118,101,108,32,112,114,101,116,105,117,109,32,108,101,99,116,117,115,32,113,117,97,109,32,105,100,32,108,101,111,46,32,70,101,117,103,105,97,116,32,105,110,32,97,110,116,101,32,109,101,116,117,115,32,100,105,99,116,117,109,32,97,116,32,116,101,109,112,111,114,32,99,111,109,109,111,100,111,46,32,86,101,108,105,116,32,100,105,103,110,105,115,115,105,109,32,115,111,100,97,108,101,115,32,117,116,32,101,117,32,115,101,109,32,105,110,116,101,103,101,114,46,32,68,105,99,116,117,109,32,115,105,116,32,97,109,101,116,32,106,117,115,116,111,32,100,111,110,101,99,46,32,83,99,101,108,101,114,105,115,113,117,101,32,109,97,117,114,105,115,32,112,101,108,108,101,110,116,101,115,113,117,101,32,112,117,108,118,105,110,97,114,32,112,101,108,108,101,110,116,101,115,113,117,101,32,104,97,98,105,116,97,110,116,32,109,111,114,98,105,32,116,114,105,115,116,105,113,117,101,32,115,101,110,101,99,116,117,115,46,32,83,99,101,108,101,114,105,115,113,117,101,32,109,97,117,114,105,115,32,112,101,108,108,101,110,116,101,115,113,117,101,32,112,117,108,118,105,110,97,114,32,112,101,108,108,101,110,116,101,115,113,117,101,32,104,97,98,105,116,97,110,116,32,109,111,114,98,105,32,116,114,105,115,116,105,113,117,101,32,115,101,110,101,99,116,117,115,46,32,83,99,101,108,101,114,105,115,113,117,101,32,109,97,117,114,105,115,32,112,101,108,108,101,110,116,101,115,113,117,101,32,112,117,108,118,105,110,97,114,32,112,101,108,108,101,110,116,101,115,113,117,101,32,104,97,98,105,116,97,110,116,32,109,111,114,98,105,32,116,114,105,115,116,105,113,117,101,32,115,101,110,101,99,116,117,115,46,32,83,99,101,108,101,114,105,115,113,117,101,32,109,97,117,114,105,115,32,112,101,108,108,101,110,116,101,115,113,117,101,32,112,117,108,118,105,110,97,114,32,112,101,108,108,101,110,116,101,115,113,117,101,32,104,97,98,105,116,97,110,116,32,109,111,114,98,105,32,116,114,105,115,116,105,113,117,101,32,115,101,110,101,99,116,117,115,46,32,83,99,101,108,101,114,105,115,113,117,101,32,109,97,117,114,105,115,32,112,101,108,108,101,110,116,101,115,113,117,101,32,112,117,108,118,105,110,97,114,32,112,101,108,108,101,110,116,101,115,113,117,101,32,104,97,98,105,116,97,110,116,32,109,111,114,98,105,32,116,114,105,115,116,105,113,117,101,32,115,101,110,101,99,116,117,115,46,32,83,99,101,108,101,114,105,115,113,117,101,32,109,97,117,114,105,115,32,112,101,108,108,101,110,116,101,115,113,117,101,32,112,117,108,118,105,110,97,114,32,112,101,108,108,101,110,116,101,115,113,117,101,32,104,97,98,105,116,97,110,116,32,109,111,114,98,105,32,116,114,105,115,116,105,113,117,101,32,115,101,110,101,99,116,117,115]),for i in std.range(0,100)1130 ],1131}1132```1133</details>11341135| Command | Mean [ms] | Min [ms] | Max [ms] | Relative |1136|:---|---:|---:|---:|---:|1137| `Rust` | 30.3 ± 0.4 | 29.1 | 31.6 | 1.00 |1138| `Rust (alternative, rsjsonnet)` | 1460.8 ± 47.6 | 1375.2 | 1568.3 | 48.26 ± 1.72 |1139| `Go` | 156.5 ± 1.9 | 152.5 | 159.4 | 5.17 ± 0.10 |1140| `Scala` | 355.9 ± 2.9 | 351.4 | 365.6 | 11.76 ± 0.20 |1141| `C++` | 13362.4 ± 88.3 | 13028.4 | 13473.8 | 441.41 ± 7.01 |11421143### std.foldl11441145<details>1146<summary>Source</summary>11471148```jsonnet1149local input = std.makeArray(10000, function(i) 'xxxxx');11501151std.foldl(function(acc, value) acc + value, input, '')11521153```1154</details>11551156| Command | Mean [ms] | Min [ms] | Max [ms] | Relative |1157|:---|---:|---:|---:|---:|1158| `Rust` | 5.3 ± 0.2 | 5.0 | 6.2 | 1.00 |1159| `Rust (alternative, rsjsonnet)` | 81.5 ± 1.6 | 78.9 | 83.8 | 15.38 ± 0.55 |1160| `Go` | 26.6 ± 0.5 | 25.0 | 27.5 | 5.02 ± 0.18 |1161| `Scala` | 405.4 ± 3.0 | 400.9 | 413.6 | 76.52 ± 2.34 |1162| `C++` | 265.3 ± 2.7 | 260.6 | 271.5 | 50.08 ± 1.57 |11631164### std.manifestJsonEx11651166<details>1167<summary>Source</summary>11681169```jsonnet1170{1171 bar: {1172 prometheusOperator+: {1173 service+: {1174 spec+: {1175 ports: [1176 {1177 name: 'https',1178 port: 8443,1179 targetPort: 'https',1180 },1181 ],1182 },1183 },1184 serviceMonitor+: {1185 spec+: {1186 endpoints: [1187 {1188 port: 'https',1189 scheme: 'https',1190 honorLabels: true,1191 bearerTokenFile: '/var/run/secrets/kubernetes.io/serviceaccount/token',1192 tlsConfig: {1193 insecureSkipVerify: true,1194 },1195 },1196 ]1197 },1198 },1199 clusterRole+: {1200 rules+: [1201 {1202 apiGroups: ['authentication.k8s.io'],1203 resources: ['tokenreviews'],1204 verbs: ['create'],1205 },1206 {1207 apiGroups: ['authorization.k8s.io'],1208 resources: ['subjectaccessreviews'],1209 verbs: ['create'],1210 },1211 ],1212 },1213 }1214 },1215 foo: std.manifestJsonEx(self.bar, " ")1216}1217```1218</details>12191220| Command | Mean [ms] | Min [ms] | Max [ms] | Relative |1221|:---|---:|---:|---:|---:|1222| `Rust` | 1.7 ± 0.1 | 1.4 | 2.7 | 1.00 |1223| `Rust (alternative, rsjsonnet)` | 2.9 ± 0.1 | 2.7 | 3.3 | 1.73 ± 0.13 |1224| `Go` | 3.2 ± 0.1 | 2.7 | 3.8 | 1.92 ± 0.15 |1225| `Scala` | 294.7 ± 1.7 | 291.6 | 299.0 | 175.84 ± 12.30 |1226| `C++` | 101.4 ± 0.8 | 99.3 | 102.9 | 60.48 ± 4.24 |12271228### std.manifestTomlEx12291230> Note: No results for Scala, std.manifestTomlEx is not implemented: https://github.com/databricks/sjsonnet/issues/11112311232<details>1233<summary>Source</summary>12341235```jsonnet1236{1237 bar: {1238 prometheusOperator+: {1239 service+: {1240 spec+: {1241 ports: [1242 {1243 name: 'https',1244 port: 8443,1245 targetPort: 'https',1246 },1247 ],1248 },1249 },1250 serviceMonitor+: {1251 spec+: {1252 endpoints: [1253 {1254 port: 'https',1255 scheme: 'https',1256 honorLabels: true,1257 bearerTokenFile: '/var/run/secrets/kubernetes.io/serviceaccount/token',1258 tlsConfig: {1259 insecureSkipVerify: true,1260 },1261 },1262 ],1263 },1264 },1265 clusterRole+: {1266 rules+: [1267 {1268 apiGroups: ['authentication.k8s.io'],1269 resources: ['tokenreviews'],1270 verbs: ['create'],1271 },1272 {1273 apiGroups: ['authorization.k8s.io'],1274 resources: ['subjectaccessreviews'],1275 verbs: ['create'],1276 },1277 ],1278 },1279 },1280 },1281 nothing: std.manifestTomlEx(self.bar, ' '),1282}12831284```1285</details>12861287| Command | Mean [ms] | Min [ms] | Max [ms] | Relative |1288|:---|---:|---:|---:|---:|1289| `Rust` | 1.7 ± 0.1 | 1.4 | 2.7 | 1.00 |1290| `Rust (alternative, rsjsonnet)` | 7.8 ± 0.2 | 7.3 | 8.5 | 4.65 ± 0.36 |1291| `Go` | 3.2 ± 0.1 | 2.9 | 3.7 | 1.90 ± 0.16 |1292| `C++` | 1046.1 ± 4.9 | 1039.7 | 1053.9 | 622.36 ± 44.25 |12931294### std.parseInt12951296<details>1297<summary>Source</summary>12981299```jsonnet1300{1301 foo: [1302 std.parseInt("-123949595") for i in std.range(0,100)1303 ],1304}1305```1306</details>13071308| Command | Mean [ms] | Min [ms] | Max [ms] | Relative |1309|:---|---:|---:|---:|---:|1310| `Rust` | 1.7 ± 0.1 | 1.4 | 2.6 | 1.00 |1311| `Rust (alternative, rsjsonnet)` | 2.9 ± 0.1 | 2.6 | 3.4 | 1.71 ± 0.16 |1312| `Go` | 2.8 ± 0.1 | 2.4 | 3.3 | 1.64 ± 0.16 |1313| `Scala` | 292.7 ± 1.7 | 289.2 | 295.8 | 170.68 ± 14.76 |1314| `C++` | 101.0 ± 0.7 | 99.0 | 102.0 | 58.88 ± 5.10 |13151316### std.reverse13171318<details>1319<summary>Source</summary>13201321```jsonnet1322{1323 foo: [1324 std.reverse(std.range(0, 5000)) for i in std.range(0,100)1325 ],1326}1327```1328</details>13291330| Command | Mean [ms] | Min [ms] | Max [ms] | Relative |1331|:---|---:|---:|---:|---:|1332| `Rust` | 45.3 ± 0.5 | 44.0 | 46.5 | 1.00 |1333| `Rust (alternative, rsjsonnet)` | 784.1 ± 20.4 | 741.5 | 802.0 | 17.31 ± 0.49 |1334| `Go` | 327.4 ± 2.1 | 323.8 | 331.4 | 7.23 ± 0.10 |1335| `Scala` | 367.0 ± 2.4 | 361.1 | 370.2 | 8.10 ± 0.11 |1336| `C++` | 659.3 ± 5.4 | 644.6 | 666.0 | 14.55 ± 0.21 |13371338### std.substr13391340<details>1341<summary>Source</summary>13421343```jsonnet1344{1345 foo: [1346 std.substr("Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Sed turpis tincidunt id aliquet risus. Eget mauris pharetra et ultrices neque ornare aenean euismod. Diam quis enim lobortis scelerisque fermentum. Varius duis at consectetur lorem donec massa sapien. Diam sit amet nisl suscipit adipiscing bibendum est ultricies integer. Lectus urna duis convallis convallis tellus. Nibh ipsum consequat nisl vel pretium lectus quam id leo. Feugiat in ante metus dictum at tempor commodo. Velit dignissim sodales ut eu sem integer. Dictum sit amet justo donec. Scelerisque mauris pellentesque pulvinar pellentesque habitant morbi tristique senectus. Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Sed turpis tincidunt id aliquet risus. Eget mauris pharetra et ultrices neque ornare aenean euismod. Diam quis enim lobortis scelerisque fermentum. Varius duis at consectetur lorem donec massa sapien. Diam sit amet nisl suscipit adipiscing bibendum est ultricies integer. Lectus urna duis convallis convallis tellus. Nibh ipsum consequat nisl vel pretium lectus quam id leo. Feugiat in ante metus dictum at tempor commodo. Velit dignissim sodales ut eu sem integer. Dictum sit amet justo donec. Scelerisque mauris pellentesque pulvinar pellentesque habitant morbi tristique senectus. Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Sed turpis tincidunt id aliquet risus. Eget mauris pharetra et ultrices neque ornare aenean euismod. Diam quis enim lobortis scelerisque fermentum. Varius duis at consectetur lorem donec massa sapien. Diam sit amet nisl suscipit adipiscing bibendum est ultricies integer. Lectus urna duis convallis convallis tellus. Nibh ipsum consequat nisl vel pretium lectus quam id leo. Feugiat in ante metus dictum at tempor commodo. Velit dignissim sodales ut eu sem integer. Dictum sit amet justo donec. Scelerisque mauris pellentesque pulvinar pellentesque habitant morbi tristique senectus.Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Sed turpis tincidunt id aliquet risus. Eget mauris pharetra et ultrices neque ornare aenean euismod. Diam quis enim lobortis scelerisque fermentum. Varius duis at consectetur lorem donec massa sapien. Diam sit amet nisl suscipit adipiscing bibendum est ultricies integer. Lectus urna duis convallis convallis tellus. Nibh ipsum consequat nisl vel pretium lectus quam id leo. Feugiat in ante metus dictum at tempor commodo. Velit dignissim sodales ut eu sem integer. Dictum sit amet justo donec. Scelerisque mauris pellentesque pulvinar pellentesque habitant morbi tristique senectus. Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Sed turpis tincidunt id aliquet risus. Eget mauris pharetra et ultrices neque ornare aenean euismod. Diam quis enim lobortis scelerisque fermentum. Varius duis at consectetur lorem donec massa sapien. Diam sit amet nisl suscipit adipiscing bibendum est ultricies integer. Lectus urna duis convallis convallis tellus. Nibh ipsum consequat nisl vel pretium lectus quam id leo. Feugiat in ante metus dictum at tempor commodo. Velit dignissim sodales ut eu sem integer. Dictum sit amet justo donec. Scelerisque mauris pellentesque pulvinar pellentesque habitant morbi tristique senectus. Scelerisque mauris pellentesque pulvinar pellentesque habitant morbi tristique senectus. Scelerisque mauris pellentesque pulvinar pellentesque habitant morbi tristique senectus. Scelerisque mauris pellentesque pulvinar pellentesque habitant morbi tristique senectus. Scelerisque mauris pellentesque pulvinar pellentesque habitant morbi tristique senectus. Scelerisque mauris pellentesque pulvinar pellentesque habitant morbi tristique senectus. ", i, 800-i) for i in std.range(0,100)1347 ],1348}1349```1350</details>13511352| Command | Mean [ms] | Min [ms] | Max [ms] | Relative |1353|:---|---:|---:|---:|---:|1354| `Rust` | 2.2 ± 0.2 | 1.9 | 3.2 | 1.00 |1355| `Rust (alternative, rsjsonnet)` | 3.2 ± 0.1 | 3.1 | 3.6 | 1.49 ± 0.11 |1356| `Go` | 6.8 ± 0.2 | 6.3 | 7.4 | 3.12 ± 0.24 |1357| `Scala` | 303.6 ± 3.6 | 300.5 | 318.2 | 139.43 ± 9.76 |1358| `C++` | 29.1 ± 0.4 | 28.3 | 30.2 | 13.36 ± 0.94 |13591360### Comparsion for array13611362> Note: No results for Scala, array comparsion is not implemented13631364<details>1365<summary>Source</summary>13661367```jsonnet1368local long_array = std.range(1, 1000000);1369long_array + [1] < long_array + [2]13701371```1372</details>13731374| Command | Mean [ms] | Min [ms] | Max [ms] | Relative |1375|:---|---:|---:|---:|---:|1376| `Rust` | 25.7 ± 0.2 | 25.0 | 26.0 | 1.00 |1377| `Rust (alternative, rsjsonnet)` | 228.1 ± 7.9 | 214.0 | 245.1 | 8.89 ± 0.31 |1378| `Go` | 150.4 ± 10.4 | 135.9 | 169.4 | 5.86 ± 0.41 |1379| `C++` | 125755.8 ± 989.6 | 123095.8 | 127475.4 | 4901.85 ± 49.12 |13801381### Comparsion for primitives13821383> Note: No results for C++, can't run: uses up to 192GB of RAM13841385<details>1386<summary>Source</summary>13871388```jsonnet1389([ i < j for i in std.range(1, 1000) for j in std.range(1, 1000)])13901391```1392</details>13931394| Command | Mean [ms] | Min [ms] | Max [ms] | Relative |1395|:---|---:|---:|---:|---:|1396| `Rust` | 385.9 ± 4.2 | 372.4 | 391.5 | 1.00 |1397| `Rust (alternative, rsjsonnet)` | 1287.4 ± 27.0 | 1244.2 | 1335.1 | 3.34 ± 0.08 |1398| `Go` | 1817.1 ± 18.6 | 1779.7 | 1842.9 | 4.71 ± 0.07 |1399| `Scala` | 453.1 ± 3.9 | 448.1 | 462.2 | 1.17 ± 0.02 |