PEGO

Benchmark Results

The results of the benchmarks in bench/: every PEGO backend (closure, recursive and iterative bytecode VMs, Go parsers generated by pego gen) and, where a comparable parser exists, the Go standard library. What the benchmarks measure, the analysis of these results, and the history of the optimizations behind them are in performance.md.

This file is generated: go run ./bench/report runs the benchmarks, measures the generated TypeScript parsers and the sizes of the generated parsers, saves the raw results to bench/results.txt, bench/results-ts.txt and bench/results-size.txt and writes this file from them; go run ./bench/report -in bench/results.txt rewrites it from saved results. Do not edit it by hand: a test checks that it matches the results.

Run

Measured on 2026-10-29 at commit 13b3d186 with go1.27.1 on Apple M3 Max (darwin/arm64, 16 cores), with a load average of 3.54 3.98 4.39 (1, 5 and 15 minutes) when the run started. Times and memory are per operation, the median of 3 runs. Factors in parentheses are relative to the closure backend (lower is faster), except where a table says otherwise. The generated TypeScript parsers were measured with Node v24.13.0.

Results

Parsing Time (Position Unit: Code Points)

Workload Closure Bytecode (recursive) Bytecode (iterative) Generated Go Generated Go, typed (ParseAST) Standard library
JSON 12.8 ms 15.6 ms (1.21×) 17.7 ms (1.38×) 5.67 ms (0.44×) 3.89 ms (0.30×) 3.50 ms (encoding/json)
CSV 5.09 ms 6.73 ms (1.32×) 7.31 ms (1.44×) 2.77 ms (0.54×) 2.27 ms (0.45×) 733 µs (encoding/csv)
XML 13.1 ms 15.8 ms (1.21×) 17.4 ms (1.33×) 6.84 ms (0.52×) 5.15 ms (0.39×) 3.88 ms (encoding/xml)
Arith_OperatorsRule 12.3 ms 15.5 ms (1.26×) 21.5 ms (1.76×) 7.43 ms (0.61×) 7.29 ms (0.59×) 2.17 ms (go/parser)
Arith_LeftRec 28.2 ms 32.1 ms (1.14×) 38.6 ms (1.37×) 14.7 ms (0.52×) 11.8 ms (0.42×) 2.18 ms (go/parser)
Minilang 15.6 ms 20.0 ms (1.29×) 24.7 ms (1.59×) 8.77 ms (0.56×) 8.33 ms (0.54×) –
Recovery 15.1 ms 19.3 ms (1.28×) 23.9 ms (1.58×) 8.47 ms (0.56×) 8.09 ms (0.54×) –
Outline 4.89 ms 6.27 ms (1.28×) 6.75 ms (1.38×) 2.44 ms (0.50×) 1.75 ms (0.36×) –

Parsing Time (Position Unit: Bytes)

Workload Closure Bytecode (recursive) Bytecode (iterative) Generated Go
JSON 12.8 ms 17.0 ms (1.33×) 17.7 ms (1.38×) 6.33 ms (0.50×)
CSV 5.15 ms 6.97 ms (1.35×) 7.20 ms (1.40×) 3.12 ms (0.61×)
XML 13.0 ms 16.1 ms (1.23×) 17.6 ms (1.35×) 7.35 ms (0.57×)
Arith_OperatorsRule 12.6 ms 15.9 ms (1.27×) 22.1 ms (1.76×) 8.29 ms (0.66×)
Arith_LeftRec 28.5 ms 32.2 ms (1.13×) 39.3 ms (1.38×) 15.5 ms (0.55×)
Minilang 15.7 ms 20.8 ms (1.32×) 25.2 ms (1.61×) 9.62 ms (0.61×)
Recovery 15.4 ms 20.0 ms (1.29×) 24.3 ms (1.57×) 9.33 ms (0.60×)
Outline 4.91 ms 6.20 ms (1.26×) 6.66 ms (1.36×) 2.86 ms (0.58×)

Memory per Parse (Position Unit: Code Points)

Bytes allocated / number of allocations.

Workload Closure Bytecode (recursive) Bytecode (iterative) Generated Go Generated Go, typed (ParseAST) Standard library
JSON 11.3 MB / 767 12.6 MB / 982 12.6 MB / 1.0 k 9.14 MB / 469 2.58 MB / 260 2.19 MB / 53 k
CSV 5.96 MB / 318 7.67 MB / 577 7.67 MB / 587 5.55 MB / 253 1.92 MB / 184 1.20 MB / 10 k
XML 13.6 MB / 835 15.1 MB / 1.1 k 15.0 MB / 1.1 k 11.6 MB / 553 3.17 MB / 263 2.54 MB / 80 k
Arith_OperatorsRule 11.4 MB / 633 11.6 MB / 658 11.7 MB / 814 11.1 MB / 575 3.92 MB / 335 2.41 MB / 69 k
Arith_LeftRec 18.0 MB / 1.7 k 18.8 MB / 1.8 k 19.0 MB / 2.2 k 10.7 MB / 767 4.39 MB / 510 2.41 MB / 69 k
Minilang 11.0 MB / 1.1 k 10.3 MB / 1.1 k 10.3 MB / 1.1 k 7.74 MB / 594 2.20 MB / 382 –
Recovery 10.6 MB / 1.9 k 9.95 MB / 1.9 k 9.99 MB / 2.0 k 7.47 MB / 1.5 k 2.27 MB / 1.2 k –
Outline 4.57 MB / 1.9 k 5.03 MB / 2.0 k 5.05 MB / 2.1 k 3.82 MB / 1.8 k 1.15 MB / 1.8 k –

Memory per Parse (Position Unit: Bytes)

Workload Closure Bytecode (recursive) Bytecode (iterative) Generated Go
JSON 11.3 MB / 767 12.6 MB / 982 12.6 MB / 1.0 k 9.13 MB / 470
CSV 5.95 MB / 319 7.66 MB / 577 7.66 MB / 587 5.54 MB / 255
XML 13.6 MB / 835 15.1 MB / 1.1 k 15.1 MB / 1.1 k 11.6 MB / 554
Arith_OperatorsRule 11.4 MB / 633 11.6 MB / 658 11.7 MB / 814 11.1 MB / 576
Arith_LeftRec 18.0 MB / 1.7 k 18.8 MB / 1.8 k 19.0 MB / 2.2 k 10.7 MB / 770
Minilang 11.0 MB / 1.1 k 10.3 MB / 1.1 k 10.3 MB / 1.1 k 7.74 MB / 596
Recovery 10.6 MB / 1.9 k 9.94 MB / 1.9 k 9.98 MB / 2.0 k 7.47 MB / 1.5 k
Outline 4.56 MB / 1.9 k 5.03 MB / 2.0 k 5.05 MB / 2.1 k 3.82 MB / 1.8 k

Typed Values (ParseAST of pego gen -types)

ParseAST builds the grammar's Go types directly when every value it can return has a Go type of its own ("direct"); otherwise (the values include CST nodes, as in minilang and recovery) it runs Parse and converts the tree ("converted"). CSV builds typed File, Record, and Field values directly. See code generation. The factor is relative to the generated parser's Parse (code points).

Workload ParseAST Parse ParseAST Memory (Parse → ParseAST)
JSON direct 5.67 ms 3.89 ms (0.69×) 9.14 MB / 469 → 2.58 MB / 260
CSV direct 2.77 ms 2.27 ms (0.82×) 5.55 MB / 253 → 1.92 MB / 184
XML direct 6.84 ms 5.15 ms (0.75×) 11.6 MB / 553 → 3.17 MB / 263
Arith_OperatorsRule direct 7.43 ms 7.29 ms (0.98×) 11.1 MB / 575 → 3.92 MB / 335
Arith_LeftRec direct 14.7 ms 11.8 ms (0.80×) 10.7 MB / 767 → 4.39 MB / 510
Minilang converted 8.77 ms 8.33 ms (0.95×) 7.74 MB / 594 → 2.20 MB / 382
Recovery converted 8.47 ms 8.09 ms (0.95×) 7.47 MB / 1.5 k → 2.27 MB / 1.2 k
Outline direct 2.44 ms 1.75 ms (0.72×) 3.82 MB / 1.8 k → 1.15 MB / 1.8 k

Recognition Only (RecognizeOnly, No Tree)

Workload Closure Bytecode (recursive) Bytecode (iterative) Generated Go (Recognize) Standard library
JSON 7.95 ms 10.1 ms (1.27×) 11.6 ms (1.46×) 2.53 ms (0.32×) 314 µs (json.Valid)
CSV 3.57 ms 4.21 ms (1.18×) 4.51 ms (1.27×) 1.20 ms (0.34×) –
XML 9.08 ms 11.7 ms (1.29×) 13.1 ms (1.44×) 3.29 ms (0.36×) –
Arith_OperatorsRule 8.40 ms 11.9 ms (1.42×) 17.7 ms (2.11×) 4.76 ms (0.57×) –
Arith_LeftRec 20.5 ms 24.5 ms (1.20×) 29.1 ms (1.42×) 9.60 ms (0.47×) –
Minilang 11.0 ms 16.2 ms (1.46×) 20.5 ms (1.86×) 6.07 ms (0.55×) –
Recovery 10.7 ms 15.6 ms (1.46×) 19.6 ms (1.84×) 5.90 ms (0.55×) –
Outline 3.91 ms 5.11 ms (1.31×) 5.55 ms (1.42×) 1.59 ms (0.41×) –

Memory per recognition (bytes allocated / number of allocations):

Workload Closure Bytecode (recursive) Bytecode (iterative) Generated Go (Recognize) Standard library
JSON 11.2 KB / 7 17.9 KB / 15 20.5 KB / 39 5.01 KB / 0 0 B / 0
CSV 4.52 KB / 4 5.66 KB / 10 6.41 KB / 18 1.57 KB / 0 –
XML 3.57 MB / 149 3.75 MB / 181 3.76 MB / 222 2.04 MB / 74 –
Arith_OperatorsRule 6.68 KB / 7 8.60 KB / 9 39.7 KB / 165 4.66 KB / 0 –
Arith_LeftRec 1.31 MB / 255 1.37 MB / 263 1.51 MB / 587 1.14 MB / 241 –
Minilang 573 KB / 135 605 KB / 150 638 KB / 219 534 KB / 123 –
Recovery 695 KB / 414 727 KB / 429 759 KB / 498 658 KB / 402 –
Outline 2.07 MB / 1.8 k 2.18 MB / 1.8 k 2.19 MB / 1.9 k 1.34 MB / 1.7 k –

Incremental Parsing (Minilang, One-Character Edit Followed by a Parse)

Backend Document: time Document: memory Full parse each time: time Full parse each time: memory
Closure 133 µs 81.8 KB / 41 15.6 ms 11.0 MB / 1.1 k
Bytecode (recursive) 116 µs 80.3 KB / 49 20.1 ms 10.3 MB / 1.1 k
Bytecode (iterative) 118 µs 83.5 KB / 71 24.5 ms 10.3 MB / 1.1 k

Incremental Parsing of a Long Document (CSV, 50,000 Records, One-Character Edit Followed by a Parse)

Backend Time Memory
Closure 1.76 ms 487 KB / 31
Bytecode (recursive) 1.80 ms 503 KB / 49
Bytecode (iterative) 1.80 ms 504 KB / 60

Streaming (CSV, 50,000 Rows, 2.17 MB)

Backend Time Throughput Memory
Closure 78.5 ms 28 MB/s 94.8 MB / 8.2 k
Bytecode (recursive) 95.2 ms 23 MB/s 106 MB / 11 k
Bytecode (iterative) 99.0 ms 22 MB/s 106 MB / 11 k
encoding/csv (Read loop) 6.82 ms 320 MB/s 6.98 MB / 100 k

Preparation (Time Until a Grammar Is Ready to Use)

Loading a .pegoc file includes the execution setup performed on the first parse after loading (preparing the VM). A compiled grammar holds the module of one mode and runs on the bytecode backend; each column loads the file of its mode and sets it up with a parse that the mode serves.

Grammar Compile from source .pegoc parse mode .pegoc recognize mode .pegoc document mode
json 382 µs 57.5 µs 35.5 µs 59.3 µs
minilang 1.61 ms 120 µs 77.8 µs 135 µs

Memory (bytes allocated / number of allocations) and file sizes:

Grammar Source Compile from source .pegoc parse mode Load .pegoc recognize mode Load .pegoc document mode Load
json 1.56 KB 506 KB / 5.9 k 2.20 KB 96.6 KB / 573 1.40 KB 51.5 KB / 444 2.20 KB 97.3 KB / 577
minilang 4.38 KB 1.77 MB / 20 k 5.01 KB 256 KB / 1.2 k 3.39 KB 158 KB / 951 5.01 KB 257 KB / 1.2 k

Generated TypeScript (Node v24.13.0)

pego gen -lang ts -types -recognize parsers, run under node --experimental-strip-types (16 cores, V8 13.6.233.17-node.37, commit 13b3d186, measured on 2026-10-29, load average 2.69 3.50 3.90 when the run started). Each figure is the median of 3 runs of bench/ts-parse.mjs, one fresh process per run, after a warm-up of one second: the mean time of a parse of the same input as the Go tables, in code points, with the throughput in parentheses. parse builds the Node tree, parseAST the typed values and recognize builds nothing. The last column is the time of parse relative to the generated Go Parse of the table above (lower is faster).

Workload parse parseAST recognize parse relative to generated Go
JSON 21.7 ms (12 MB/s) 29.9 ms (8.8 MB/s) 9.14 ms (29 MB/s) 3.82×
CSV 9.23 ms (23 MB/s) 13.2 ms (16 MB/s) 2.83 ms (75 MB/s) 3.33×
XML 23.5 ms (11 MB/s) 31.2 ms (8.4 MB/s) 12.4 ms (21 MB/s) 3.43×
Arith_OperatorsRule 26.6 ms (5.0 MB/s) 34.8 ms (3.8 MB/s) 17.4 ms (7.7 MB/s) 3.58×
Arith_LeftRec 44.3 ms (3.0 MB/s) 54.3 ms (2.5 MB/s) 25.9 ms (5.2 MB/s) 3.01×
Minilang 35.1 ms (2.5 MB/s) 40.2 ms (2.2 MB/s) 25.3 ms (3.5 MB/s) 4.00×
Outline 5.93 ms (14 MB/s) 6.67 ms (12 MB/s) 3.82 ms (22 MB/s) 2.43×

Generated Parser Size

Sizes of the parsers in parsers/, generated with the options of parsers/generate.go (commit 13b3d186, go1.27.1). "Go source" is the committed parser.go; "Go binary" is a program that calls the parser's ParseAST, built with -trimpath -ldflags="-s -w", so it includes the PEGO runtime and the parser's types. "TypeScript" is the generated parser.ts, raw and compressed with gzip -9; it imports the embedded runtime, which is the same for every parser and weighs 146 KB (36.9 KB gzipped).

Parser Go source Go binary TypeScript TypeScript, gzip -9
json 58.3 KB 2.18 MB 70.9 KB 9.88 KB
csv 25.3 KB 2.15 MB 32.0 KB 6.57 KB
xml 301 KB 2.91 MB 272 KB 28.8 KB
yaml 522 KB 3.07 MB 571 KB 56.5 KB
cel 113 KB 2.39 MB 216 KB 25.7 KB
cue 397 KB 3.09 MB 619 KB 81.1 KB
golang 524 KB 3.33 MB 836 KB 88.6 KB
python 603 KB 3.70 MB 941 KB 110 KB
typescript 943 KB 4.63 MB 1.51 MB 166 KB
duckdb 1.59 MB 6.45 MB 3.32 MB 257 KB

All Results

Every benchmark of the run, by its name under bench/ (median of the runs; the throughput is in MB/s of input).

Benchmark Time Throughput Memory Allocations Other
Parse/JSON/closure/codepoints 12.8 ms 20.5 11.3 MB 767 –
Parse/JSON/closure/bytes 12.8 ms 20.5 11.3 MB 767 –
Parse/JSON/bytecode/codepoints 15.6 ms 16.9 12.6 MB 982 –
Parse/JSON/bytecode/bytes 17.0 ms 15.5 12.6 MB 982 –
Parse/JSON/iterative/codepoints 17.7 ms 14.8 12.6 MB 1.0 k –
Parse/JSON/iterative/bytes 17.7 ms 14.8 12.6 MB 1.0 k –
Parse/JSON/generated/codepoints 5.67 ms 46.2 9.14 MB 469 –
Parse/JSON/generated/bytes 6.33 ms 41.4 9.13 MB 470 –
Parse/JSON/generated_ast 3.89 ms 67.4 2.58 MB 260 –
Parse/JSON/encoding_json 3.50 ms 74.9 2.19 MB 53 k –
Parse/CSV/closure/codepoints 5.09 ms 41.5 5.96 MB 318 –
Parse/CSV/closure/bytes 5.15 ms 41.1 5.95 MB 319 –
Parse/CSV/bytecode/codepoints 6.73 ms 31.4 7.67 MB 577 –
Parse/CSV/bytecode/bytes 6.97 ms 30.3 7.66 MB 577 –
Parse/CSV/iterative/codepoints 7.31 ms 28.9 7.67 MB 587 –
Parse/CSV/iterative/bytes 7.20 ms 29.4 7.66 MB 587 –
Parse/CSV/generated/codepoints 2.77 ms 76.4 5.55 MB 253 –
Parse/CSV/generated/bytes 3.12 ms 67.7 5.54 MB 255 –
Parse/CSV/generated_ast 2.27 ms 93.1 1.92 MB 184 –
Parse/CSV/encoding_csv 733 µs 288 1.20 MB 10 k –
Parse/XML/closure/codepoints 13.1 ms 20.0 13.6 MB 835 –
Parse/XML/closure/bytes 13.0 ms 20.1 13.6 MB 835 –
Parse/XML/bytecode/codepoints 15.8 ms 16.6 15.1 MB 1.1 k –
Parse/XML/bytecode/bytes 16.1 ms 16.3 15.1 MB 1.1 k –
Parse/XML/iterative/codepoints 17.4 ms 15.1 15.0 MB 1.1 k –
Parse/XML/iterative/bytes 17.6 ms 14.9 15.1 MB 1.1 k –
Parse/XML/generated/codepoints 6.84 ms 38.3 11.6 MB 553 –
Parse/XML/generated/bytes 7.35 ms 35.6 11.6 MB 554 –
Parse/XML/generated_ast 5.15 ms 51.0 3.17 MB 263 –
Parse/XML/encoding_xml 3.88 ms 67.5 2.54 MB 80 k –
Parse/Arith_OperatorsRule/closure/codepoints 12.3 ms 10.9 11.4 MB 633 –
Parse/Arith_OperatorsRule/closure/bytes 12.6 ms 10.6 11.4 MB 633 –
Parse/Arith_OperatorsRule/bytecode/codepoints 15.5 ms 8.60 11.6 MB 658 –
Parse/Arith_OperatorsRule/bytecode/bytes 15.9 ms 8.40 11.6 MB 658 –
Parse/Arith_OperatorsRule/iterative/codepoints 21.5 ms 6.19 11.7 MB 814 –
Parse/Arith_OperatorsRule/iterative/bytes 22.1 ms 6.04 11.7 MB 814 –
Parse/Arith_OperatorsRule/generated/codepoints 7.43 ms 17.9 11.1 MB 575 –
Parse/Arith_OperatorsRule/generated/bytes 8.29 ms 16.1 11.1 MB 576 –
Parse/Arith_OperatorsRule/generated_ast 7.29 ms 18.3 3.92 MB 335 –
Parse/Arith_OperatorsRule/go_parser 2.17 ms 61.5 2.41 MB 69 k –
Parse/Arith_LeftRec/closure/codepoints 28.2 ms 4.73 18.0 MB 1.7 k –
Parse/Arith_LeftRec/closure/bytes 28.5 ms 4.69 18.0 MB 1.7 k –
Parse/Arith_LeftRec/bytecode/codepoints 32.1 ms 4.16 18.8 MB 1.8 k –
Parse/Arith_LeftRec/bytecode/bytes 32.2 ms 4.14 18.8 MB 1.8 k –
Parse/Arith_LeftRec/iterative/codepoints 38.6 ms 3.46 19.0 MB 2.2 k –
Parse/Arith_LeftRec/iterative/bytes 39.3 ms 3.40 19.0 MB 2.2 k –
Parse/Arith_LeftRec/generated/codepoints 14.7 ms 9.06 10.7 MB 767 –
Parse/Arith_LeftRec/generated/bytes 15.5 ms 8.60 10.7 MB 770 –
Parse/Arith_LeftRec/generated_ast 11.8 ms 11.3 4.39 MB 510 –
Parse/Arith_LeftRec/go_parser 2.18 ms 61.3 2.41 MB 69 k –
Parse/Minilang/closure/codepoints 15.6 ms 5.71 11.0 MB 1.1 k –
Parse/Minilang/closure/bytes 15.7 ms 5.66 11.0 MB 1.1 k –
Parse/Minilang/bytecode/codepoints 20.0 ms 4.44 10.3 MB 1.1 k –
Parse/Minilang/bytecode/bytes 20.8 ms 4.28 10.3 MB 1.1 k –
Parse/Minilang/iterative/codepoints 24.7 ms 3.60 10.3 MB 1.1 k –
Parse/Minilang/iterative/bytes 25.2 ms 3.52 10.3 MB 1.1 k –
Parse/Minilang/generated/codepoints 8.77 ms 10.1 7.74 MB 594 –
Parse/Minilang/generated/bytes 9.62 ms 9.24 7.74 MB 596 –
Parse/Minilang/generated_ast 8.33 ms 10.7 2.20 MB 382 –
Parse/Recovery/closure/codepoints 15.1 ms 5.91 10.6 MB 1.9 k –
Parse/Recovery/closure/bytes 15.4 ms 5.79 10.6 MB 1.9 k –
Parse/Recovery/bytecode/codepoints 19.3 ms 4.62 9.95 MB 1.9 k –
Parse/Recovery/bytecode/bytes 20.0 ms 4.48 9.94 MB 1.9 k –
Parse/Recovery/iterative/codepoints 23.9 ms 3.75 9.99 MB 2.0 k –
Parse/Recovery/iterative/bytes 24.3 ms 3.68 9.98 MB 2.0 k –
Parse/Recovery/generated/codepoints 8.47 ms 10.6 7.47 MB 1.5 k –
Parse/Recovery/generated/bytes 9.33 ms 9.58 7.47 MB 1.5 k –
Parse/Recovery/generated_ast 8.09 ms 11.1 2.27 MB 1.2 k –
Parse/Outline/closure/codepoints 4.89 ms 17.0 4.57 MB 1.9 k –
Parse/Outline/closure/bytes 4.91 ms 17.0 4.56 MB 1.9 k –
Parse/Outline/bytecode/codepoints 6.27 ms 13.3 5.03 MB 2.0 k –
Parse/Outline/bytecode/bytes 6.20 ms 13.4 5.03 MB 2.0 k –
Parse/Outline/iterative/codepoints 6.75 ms 12.3 5.05 MB 2.1 k –
Parse/Outline/iterative/bytes 6.66 ms 12.5 5.05 MB 2.1 k –
Parse/Outline/generated/codepoints 2.44 ms 34.2 3.82 MB 1.8 k –
Parse/Outline/generated/bytes 2.86 ms 29.1 3.82 MB 1.8 k –
Parse/Outline/generated_ast 1.75 ms 47.8 1.15 MB 1.8 k –
Recognize/JSON/closure 7.95 ms 33.0 11.2 KB 7 –
Recognize/JSON/bytecode 10.1 ms 26.0 17.9 KB 15 –
Recognize/JSON/iterative 11.6 ms 22.6 20.5 KB 39 –
Recognize/JSON/generated 2.53 ms 104 5.01 KB 0 –
Recognize/JSON/json_Valid 314 µs 835 0 B 0 –
Recognize/CSV/closure 3.57 ms 59.3 4.52 KB 4 –
Recognize/CSV/bytecode 4.21 ms 50.2 5.66 KB 10 –
Recognize/CSV/iterative 4.51 ms 46.9 6.41 KB 18 –
Recognize/CSV/generated 1.20 ms 176 1.57 KB 0 –
Recognize/XML/closure 9.08 ms 28.9 3.57 MB 149 –
Recognize/XML/bytecode 11.7 ms 22.4 3.75 MB 181 –
Recognize/XML/iterative 13.1 ms 20.1 3.76 MB 222 –
Recognize/XML/generated 3.29 ms 79.7 2.04 MB 74 –
Recognize/Arith_OperatorsRule/closure 8.40 ms 15.9 6.68 KB 7 –
Recognize/Arith_OperatorsRule/bytecode 11.9 ms 11.2 8.60 KB 9 –
Recognize/Arith_OperatorsRule/iterative 17.7 ms 7.54 39.7 KB 165 –
Recognize/Arith_OperatorsRule/generated 4.76 ms 28.0 4.66 KB 0 –
Recognize/Arith_LeftRec/closure 20.5 ms 6.52 1.31 MB 255 –
Recognize/Arith_LeftRec/bytecode 24.5 ms 5.46 1.37 MB 263 –
Recognize/Arith_LeftRec/iterative 29.1 ms 4.58 1.51 MB 587 –
Recognize/Arith_LeftRec/generated 9.60 ms 13.9 1.14 MB 241 –
Recognize/Minilang/closure 11.0 ms 8.05 573 KB 135 –
Recognize/Minilang/bytecode 16.2 ms 5.50 605 KB 150 –
Recognize/Minilang/iterative 20.5 ms 4.34 638 KB 219 –
Recognize/Minilang/generated 6.07 ms 14.6 534 KB 123 –
Recognize/Recovery/closure 10.7 ms 8.39 695 KB 414 –
Recognize/Recovery/bytecode 15.6 ms 5.75 727 KB 429 –
Recognize/Recovery/iterative 19.6 ms 4.55 759 KB 498 –
Recognize/Recovery/generated 5.90 ms 15.2 658 KB 402 –
Recognize/Outline/closure 3.91 ms 21.3 2.07 MB 1.8 k –
Recognize/Outline/bytecode 5.11 ms 16.3 2.18 MB 1.8 k –
Recognize/Outline/iterative 5.55 ms 15.0 2.19 MB 1.9 k –
Recognize/Outline/generated 1.59 ms 52.3 1.34 MB 1.7 k –
Incremental/closure/document 133 µs – 81.8 KB 41 –
Incremental/closure/fresh 15.6 ms – 11.0 MB 1.1 k –
Incremental/bytecode/document 116 µs – 80.3 KB 49 –
Incremental/bytecode/fresh 20.1 ms – 10.3 MB 1.1 k –
Incremental/iterative/document 118 µs – 83.5 KB 71 –
Incremental/iterative/fresh 24.5 ms – 10.3 MB 1.1 k –
IncrementalLong/closure 1.76 ms – 487 KB 31 –
IncrementalLong/bytecode 1.80 ms – 503 KB 49 –
IncrementalLong/iterative 1.80 ms – 504 KB 60 –
Stream/closure 78.5 ms 27.6 94.8 MB 8.2 k –
Stream/bytecode 95.2 ms 22.8 106 MB 11 k –
Stream/iterative 99.0 ms 21.9 106 MB 11 k –
Stream/encoding_csv 6.82 ms 318 6.98 MB 100 k –
Prepare/json/source 382 µs – 506 KB 5.9 k –
Prepare/json/pegoc/parse/bytecode 57.5 µs – 96.6 KB 573 2200 file-bytes
Prepare/json/pegoc/recognize/bytecode 35.5 µs – 51.5 KB 444 1400 file-bytes
Prepare/json/pegoc/document/bytecode 59.3 µs – 97.3 KB 577 2200 file-bytes
Prepare/minilang/source 1.61 ms – 1.77 MB 20 k –
Prepare/minilang/pegoc/parse/bytecode 120 µs – 256 KB 1.2 k 5010 file-bytes
Prepare/minilang/pegoc/recognize/bytecode 77.8 µs – 158 KB 951 3390 file-bytes
Prepare/minilang/pegoc/document/bytecode 135 µs – 257 KB 1.2 k 5010 file-bytes
StreamDeliveryAdoption/closure/codepoints/callback 79.6 ms 27.2 94.8 MB 8.2 k 50000 elements/op
StreamDeliveryAdoption/closure/codepoints/iterator 83.2 ms 26.1 94.8 MB 8.2 k 50000 elements/op
StreamDeliveryAdoption/closure/bytes/callback 68.3 ms 31.7 94.7 MB 8.9 k 50000 elements/op
StreamDeliveryAdoption/closure/bytes/iterator 72.8 ms 29.8 94.7 MB 8.9 k 50000 elements/op
StreamDeliveryAdoption/bytecode/codepoints/callback 95.6 ms 22.7 106 MB 11 k 50000 elements/op
StreamDeliveryAdoption/bytecode/codepoints/iterator 99.8 ms 21.7 106 MB 11 k 50000 elements/op
StreamDeliveryAdoption/bytecode/bytes/callback 85.6 ms 25.3 106 MB 11 k 50000 elements/op
StreamDeliveryAdoption/bytecode/bytes/iterator 89.7 ms 24.2 106 MB 11 k 50000 elements/op
StreamDeliveryAdoption/iterative/codepoints/callback 99.6 ms 21.8 106 MB 11 k 50000 elements/op
StreamDeliveryAdoption/iterative/codepoints/iterator 104 ms 20.9 106 MB 11 k 50000 elements/op
StreamDeliveryAdoption/iterative/bytes/callback 89.4 ms 24.2 106 MB 11 k 50000 elements/op
StreamDeliveryAdoption/iterative/bytes/iterator 93.3 ms 23.2 106 MB 11 k 50000 elements/op
StreamFirstElementAdoption/closure/codepoints/callback 78.6 ms – 94.8 MB 8.2 k 45000 ns/first
StreamFirstElementAdoption/closure/codepoints/iterator 83.4 ms – 94.8 MB 8.2 k 62200 ns/first
StreamFirstElementAdoption/closure/bytes/callback 68.4 ms – 94.7 MB 8.9 k 42900 ns/first
StreamFirstElementAdoption/closure/bytes/iterator 72.7 ms – 94.7 MB 8.9 k 35000 ns/first
StreamFirstElementAdoption/bytecode/codepoints/callback 96.1 ms – 106 MB 11 k 66900 ns/first
StreamFirstElementAdoption/bytecode/codepoints/iterator 99.2 ms – 106 MB 11 k 60000 ns/first
StreamFirstElementAdoption/bytecode/bytes/callback 85.5 ms – 106 MB 11 k 28000 ns/first
StreamFirstElementAdoption/bytecode/bytes/iterator 89.4 ms – 106 MB 11 k 41600 ns/first
StreamFirstElementAdoption/iterative/codepoints/callback 98.8 ms – 106 MB 11 k 49600 ns/first
StreamFirstElementAdoption/iterative/codepoints/iterator 102 ms – 106 MB 11 k 57200 ns/first
StreamFirstElementAdoption/iterative/bytes/callback 88.4 ms – 106 MB 11 k 38500 ns/first
StreamFirstElementAdoption/iterative/bytes/iterator 92.4 ms – 106 MB 11 k 37100 ns/first
DocumentCacheAdoption/closure/codepoints/CacheStats 228 µs – 0 B 0 20800000 cached-B
DocumentCacheAdoption/closure/codepoints/ResetAndParse 27.2 ms – 40.9 MB 27 k 20800000 cached-B
DocumentCacheAdoption/closure/codepoints/FreshDocument 27.5 ms – 41.6 MB 27 k –
DocumentCacheAdoption/closure/bytes/CacheStats 227 µs – 0 B 0 20800000 cached-B
DocumentCacheAdoption/closure/bytes/ResetAndParse 30.4 ms – 40.9 MB 27 k 20800000 cached-B
DocumentCacheAdoption/closure/bytes/FreshDocument 30.4 ms – 40.9 MB 27 k –
DocumentCacheAdoption/bytecode/codepoints/CacheStats 231 µs – 0 B 0 20800000 cached-B
DocumentCacheAdoption/bytecode/codepoints/ResetAndParse 31.3 ms – 32.7 MB 1.8 k 20800000 cached-B
DocumentCacheAdoption/bytecode/codepoints/FreshDocument 31.6 ms – 33.4 MB 1.8 k –
DocumentCacheAdoption/bytecode/bytes/CacheStats 230 µs – 0 B 0 20800000 cached-B
DocumentCacheAdoption/bytecode/bytes/ResetAndParse 36.9 ms – 32.7 MB 1.8 k 20800000 cached-B
DocumentCacheAdoption/bytecode/bytes/FreshDocument 37.1 ms – 32.7 MB 1.8 k –
DocumentCacheAdoption/iterative/codepoints/CacheStats 228 µs – 0 B 0 20800000 cached-B
DocumentCacheAdoption/iterative/codepoints/ResetAndParse 36.9 ms – 32.7 MB 1.9 k 20800000 cached-B
DocumentCacheAdoption/iterative/codepoints/FreshDocument 37.3 ms – 33.4 MB 1.9 k –
DocumentCacheAdoption/iterative/bytes/CacheStats 223 µs – 0 B 0 20800000 cached-B
DocumentCacheAdoption/iterative/bytes/ResetAndParse 42.6 ms – 32.7 MB 1.9 k 20800000 cached-B
DocumentCacheAdoption/iterative/bytes/FreshDocument 42.9 ms – 32.7 MB 1.9 k –
StreamDiagnosticLimit/closure/codepoints/complete 875 µs 4.57 581 KB 8.0 k –
StreamDiagnosticLimit/closure/codepoints/limit-32 893 µs 4.48 564 KB 8.0 k –
StreamDiagnosticLimit/closure/bytes/complete 875 µs 4.57 538 KB 8.0 k –
StreamDiagnosticLimit/closure/bytes/limit-32 886 µs 4.51 521 KB 8.0 k –
StreamDiagnosticLimit/bytecode/codepoints/complete 935 µs 4.28 599 KB 8.0 k –
StreamDiagnosticLimit/bytecode/codepoints/limit-32 949 µs 4.21 582 KB 8.0 k –
StreamDiagnosticLimit/bytecode/bytes/complete 929 µs 4.30 556 KB 8.0 k –
StreamDiagnosticLimit/bytecode/bytes/limit-32 949 µs 4.21 539 KB 8.0 k –
StreamDiagnosticLimit/iterative/codepoints/complete 957 µs 4.18 599 KB 8.0 k –
StreamDiagnosticLimit/iterative/codepoints/limit-32 969 µs 4.13 582 KB 8.0 k –
StreamDiagnosticLimit/iterative/bytes/complete 948 µs 4.22 556 KB 8.0 k –
StreamDiagnosticLimit/iterative/bytes/limit-32 965 µs 4.14 540 KB 8.0 k –
ControlledParse/JSON/closure/codepoints 22.4 ms 11.7 11.3 MB 767 –
ControlledParse/JSON/closure/bytes 20.8 ms 12.6 11.3 MB 767 –
ControlledParse/JSON/bytecode/codepoints 26.5 ms 9.89 12.6 MB 982 –
ControlledParse/JSON/bytecode/bytes 24.9 ms 10.5 12.6 MB 982 –
ControlledParse/JSON/iterative/codepoints 29.7 ms 8.83 12.6 MB 1.0 k –
ControlledParse/JSON/iterative/bytes 28.0 ms 9.37 12.6 MB 1.0 k –
ControlledParse/JSON/generated/codepoints 7.39 ms 35.5 9.15 MB 471 –
ControlledParse/JSON/generated_ast/codepoints 5.71 ms 45.9 2.58 MB 262 –
ControlledParse/JSON/generated/bytes 7.03 ms 37.3 9.13 MB 471 –
ControlledParse/JSON/generated_ast/bytes 5.23 ms 50.2 2.57 MB 262 –
ControlledParse/XML/closure/codepoints 22.9 ms 11.4 13.5 MB 835 –
ControlledParse/XML/closure/bytes 21.3 ms 12.3 13.5 MB 835 –
ControlledParse/XML/bytecode/codepoints 26.0 ms 10.1 15.0 MB 1.1 k –
ControlledParse/XML/bytecode/bytes 24.3 ms 10.8 15.0 MB 1.1 k –
ControlledParse/XML/iterative/codepoints 28.3 ms 9.25 15.0 MB 1.1 k –
ControlledParse/XML/iterative/bytes 26.9 ms 9.76 15.0 MB 1.1 k –
ControlledParse/XML/generated/codepoints 10.1 ms 26.1 11.7 MB 556 –
ControlledParse/XML/generated_ast/codepoints 8.30 ms 31.6 3.21 MB 266 –
ControlledParse/XML/generated/bytes 9.56 ms 27.4 11.6 MB 555 –
ControlledParse/XML/generated_ast/bytes 7.72 ms 34.0 3.19 MB 265 –
WorkControlModes/JSON/closure/codepoints/inactive 12.6 ms 20.9 11.3 MB 766 –
WorkControlModes/JSON/closure/codepoints/context 21.0 ms 12.5 11.3 MB 767 –
WorkControlModes/JSON/closure/codepoints/budget 22.5 ms 11.7 11.3 MB 767 –
WorkControlModes/JSON/closure/codepoints/combined 22.4 ms 11.7 11.3 MB 767 –
WorkControlModes/JSON/closure/bytes/inactive 12.5 ms 21.1 11.3 MB 766 –
WorkControlModes/JSON/closure/bytes/context 19.5 ms 13.4 11.3 MB 767 –
WorkControlModes/JSON/closure/bytes/budget 20.7 ms 12.7 11.3 MB 767 –
WorkControlModes/JSON/closure/bytes/combined 20.7 ms 12.7 11.3 MB 767 –
WorkControlModes/JSON/bytecode/codepoints/inactive 15.8 ms 16.6 12.6 MB 981 –
WorkControlModes/JSON/bytecode/codepoints/context 24.2 ms 10.8 12.6 MB 982 –
WorkControlModes/JSON/bytecode/codepoints/budget 26.6 ms 9.87 12.6 MB 982 –
WorkControlModes/JSON/bytecode/codepoints/combined 26.8 ms 9.80 12.6 MB 982 –
WorkControlModes/JSON/bytecode/bytes/inactive 15.7 ms 16.7 12.6 MB 981 –
WorkControlModes/JSON/bytecode/bytes/context 23.0 ms 11.4 12.6 MB 982 –
WorkControlModes/JSON/bytecode/bytes/budget 25.0 ms 10.5 12.6 MB 982 –
WorkControlModes/JSON/bytecode/bytes/combined 24.9 ms 10.5 12.6 MB 982 –
WorkControlModes/JSON/iterative/codepoints/inactive 17.6 ms 14.9 12.6 MB 1.0 k –
WorkControlModes/JSON/iterative/codepoints/context 27.9 ms 9.39 12.6 MB 1.0 k –
WorkControlModes/JSON/iterative/codepoints/budget 29.6 ms 8.86 12.6 MB 1.0 k –
WorkControlModes/JSON/iterative/codepoints/combined 29.7 ms 8.84 12.6 MB 1.0 k –
WorkControlModes/JSON/iterative/bytes/inactive 17.7 ms 14.8 12.6 MB 1.0 k –
WorkControlModes/JSON/iterative/bytes/context 26.8 ms 9.80 12.6 MB 1.0 k –
WorkControlModes/JSON/iterative/bytes/budget 27.9 ms 9.39 12.6 MB 1.0 k –
WorkControlModes/JSON/iterative/bytes/combined 28.0 ms 9.38 12.6 MB 1.0 k –
WorkControlModes/XML/closure/codepoints/inactive 13.0 ms 20.2 13.5 MB 834 –
WorkControlModes/XML/closure/codepoints/context 21.8 ms 12.0 13.5 MB 835 –
WorkControlModes/XML/closure/codepoints/budget 23.1 ms 11.3 13.5 MB 835 –
WorkControlModes/XML/closure/codepoints/combined 23.1 ms 11.3 13.5 MB 835 –
WorkControlModes/XML/closure/bytes/inactive 13.0 ms 20.2 13.5 MB 834 –
WorkControlModes/XML/closure/bytes/context 20.4 ms 12.8 13.5 MB 835 –
WorkControlModes/XML/closure/bytes/budget 21.3 ms 12.3 13.5 MB 835 –
WorkControlModes/XML/closure/bytes/combined 21.4 ms 12.3 13.5 MB 835 –
WorkControlModes/XML/bytecode/codepoints/inactive 15.7 ms 16.6 15.0 MB 1.1 k –
WorkControlModes/XML/bytecode/codepoints/context 23.9 ms 11.0 15.0 MB 1.1 k –
WorkControlModes/XML/bytecode/codepoints/budget 25.8 ms 10.2 15.0 MB 1.1 k –
WorkControlModes/XML/bytecode/codepoints/combined 25.9 ms 10.1 15.0 MB 1.1 k –
WorkControlModes/XML/bytecode/bytes/inactive 15.7 ms 16.7 15.0 MB 1.1 k –
WorkControlModes/XML/bytecode/bytes/context 22.7 ms 11.5 15.0 MB 1.1 k –
WorkControlModes/XML/bytecode/bytes/budget 24.3 ms 10.8 15.0 MB 1.1 k –
WorkControlModes/XML/bytecode/bytes/combined 24.3 ms 10.8 15.0 MB 1.1 k –
WorkControlModes/XML/iterative/codepoints/inactive 17.3 ms 15.1 15.0 MB 1.1 k –
WorkControlModes/XML/iterative/codepoints/context 26.7 ms 9.81 15.0 MB 1.1 k –
WorkControlModes/XML/iterative/codepoints/budget 28.2 ms 9.28 15.0 MB 1.1 k –
WorkControlModes/XML/iterative/codepoints/combined 28.2 ms 9.29 15.0 MB 1.1 k –
WorkControlModes/XML/iterative/bytes/inactive 17.3 ms 15.2 15.0 MB 1.1 k –
WorkControlModes/XML/iterative/bytes/context 25.7 ms 10.2 15.0 MB 1.1 k –
WorkControlModes/XML/iterative/bytes/budget 26.7 ms 9.82 15.0 MB 1.1 k –
WorkControlModes/XML/iterative/bytes/combined 26.7 ms 9.82 15.0 MB 1.1 k –