JSON parsers comparison

JavaScript performance comparison

Revision 21 of this test case created by

Preparation code

<script src="https://sap.github.io/chevrotain/bower_components/chevrotain/release/chevrotain.js"></script>
<script src="https://sap.github.io/chevrotain/performance/samples/10K_json.js"></script>
<script src="https://sap.github.io/chevrotain/performance/jsonParsers/chevrotain/chevrotainParser.js"></script>
<script src="https://sap.github.io/chevrotain/performance/jsonParsers/chevrotain/api.js"></script>
<script src="https://sap.github.io/chevrotain/performance/jsonParsers/jison/jisonParser.js"></script>
<script src="https://sap.github.io/chevrotain/performance/jsonParsers/pegjs/pegjs_jison_parser.js"></script>

<script src="https://sap.github.io/chevrotain/performance/jsonParsers/jison/jisonParser.js"></script>
<script src="https://sap.github.io/chevrotain/performance/jsonParsers/pegjs/pegjs_jison_parser.js"></script>

<script src="https://sap.github.io/chevrotain/bower_components/antlr4/antlr4.js"></script>
<script src="https://sap.github.io/chevrotain/performance/jsonParsers/antlr/JSON_ANTLRLexer.js"></script>
<script src="https://sap.github.io/chevrotain/performance/jsonParsers/antlr/JSON_ANTLRListener.js"></script>
<script src="https://sap.github.io/chevrotain/performance/jsonParsers/antlr/JSON_ANTLRParser.js"></script>
<script src="https://sap.github.io/chevrotain/performance/jsonParsers/antlr/api.js"></script>
    

Preparation code output

Test runner

Warning! For accurate results, please disable Firebug before running the tests. (Why?)

Java applet disabled.

Testing in CCBot 2.0.0 / Other 0.0.0
Test Ops/sec
Jison
jisonJsonLexerAndParser.parse(json_sample10k)
pending…
Chevrotain
chevrotainParseWithChevrotainLexer(json_sample10k)
pending…
ANTLR4
antlr4LexerAndParser(json_sample10k)
pending…
PEG.js
pegjsJsonLexerAndParser.parse(json_sample10k)
pending…

Compare results of other browsers

Revisions

You can edit these tests or add even more tests to this page by appending /edit to the URL.

0 Comments