Closed tiensonqin closed 2 years ago
Related to #113
Benchmark result:
make bench dune exec ./bench/bench.exe Estimated testing time 1m (6 benchmarks x 10s). Change using '-quota'. ┌──────────────────────────────────────┬──────────┬─────────────┬────────────┬────────────┬────────────┐ │ Name │ Time/Run │ mWd/Run │ mjWd/Run │ Prom/Run │ Percentage │ ├──────────────────────────────────────┼──────────┼─────────────┼────────────┼────────────┼────────────┤ │ Inline parse (doc) │ 4.89ms │ 1_846.67kw │ 281.61kw │ 133.81kw │ 3.27% │ │ Inline parse outline (doc) │ 1.11ms │ 454.27kw │ 54.17kw │ 54.17kw │ 0.74% │ │ Mldoc Org mode parser │ 149.58ms │ 84_303.34kw │ 1_857.82kw │ 1_857.82kw │ 100.00% │ │ Mldoc Org mode parser (outline only) │ 123.64ms │ 68_350.74kw │ 1_620.65kw │ 1_620.65kw │ 82.66% │ │ Mldoc Markdown parser │ 2.06ms │ 1_067.95kw │ 29.25kw │ 29.25kw │ 1.38% │ │ Mldoc Markdown parser (outline only) │ 1.32ms │ 915.82kw │ 25.28kw │ 25.28kw │ 0.88% │ └──────────────────────────────────────┴──────────┴─────────────┴────────────┴────────────┴────────────┘ Benchmarks that take 1ns to 100ms can be estimated precisely. For more reliable estimates, redesign your benchmark to have a shorter execution time.
@RCmerci I copied most of the tests from test_markdown to test_outline_markdown, also added some tests related to timestamps.
Related to #113
Benchmark result: