json-model-compiler 2.0b39__tar.gz → 2.0b41__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {json_model_compiler-2.0b39/site → json_model_compiler-2.0b41}/BACKLOG.md +11 -5
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/BENCH.md +3 -8
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/Makefile +26 -5
- {json_model_compiler-2.0b39/json_model_compiler.egg-info → json_model_compiler-2.0b41}/PKG-INFO +1 -1
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/data/perl_entry.pl +7 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/data/perl_pkg.pl +1 -1
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/javascript.py +2 -1
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/optim.py +108 -41
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/runtime/c/main.c +44 -4
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/runtime/java/json_model/Main.java +4 -2
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/runtime/java/pom.xml +1 -1
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/runtime/js/main.js +1 -1
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/runtime/pl/lib/JSON/JsonModel.pm +1 -1
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/script.py +5 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/xstatic.py +101 -57
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41/json_model_compiler.egg-info}/PKG-INFO +1 -1
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model_compiler.egg-info/SOURCES.txt +7 -22
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/pyproject.toml +1 -1
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41/site}/BACKLOG.md +11 -5
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/site/BENCH.md +3 -8
- json_model_compiler-2.0b41/site/benchmarks/2026031000.csv +171 -0
- json_model_compiler-2.0b41/site/benchmarks/2026031000.json +296 -0
- json_model_compiler-2.0b41/site/benchmarks/2026031000.md +216 -0
- json_model_compiler-2.0b41/site/benchmarks/2026031300.csv +171 -0
- json_model_compiler-2.0b41/site/benchmarks/2026031300.json +296 -0
- json_model_compiler-2.0b41/site/benchmarks/2026031300.md +216 -0
- json_model_compiler-2.0b39/site/benchmarks/2026010600.csv +0 -172
- json_model_compiler-2.0b39/site/benchmarks/2026010600.json +0 -296
- json_model_compiler-2.0b39/site/benchmarks/2026010600.md +0 -215
- json_model_compiler-2.0b39/site/benchmarks/2026010900.csv +0 -172
- json_model_compiler-2.0b39/site/benchmarks/2026010900.json +0 -296
- json_model_compiler-2.0b39/site/benchmarks/2026010900.md +0 -215
- json_model_compiler-2.0b39/site/benchmarks/2026011500.csv +0 -172
- json_model_compiler-2.0b39/site/benchmarks/2026011500.json +0 -296
- json_model_compiler-2.0b39/site/benchmarks/2026011500.md +0 -215
- json_model_compiler-2.0b39/site/benchmarks/2026012000.csv +0 -172
- json_model_compiler-2.0b39/site/benchmarks/2026012000.json +0 -296
- json_model_compiler-2.0b39/site/benchmarks/2026012000.md +0 -215
- json_model_compiler-2.0b39/site/benchmarks/2026012200.csv +0 -173
- json_model_compiler-2.0b39/site/benchmarks/2026012200.json +0 -296
- json_model_compiler-2.0b39/site/benchmarks/2026012200.md +0 -216
- json_model_compiler-2.0b39/site/benchmarks/2026012400.csv +0 -173
- json_model_compiler-2.0b39/site/benchmarks/2026012400.json +0 -296
- json_model_compiler-2.0b39/site/benchmarks/2026012400.md +0 -216
- json_model_compiler-2.0b39/site/benchmarks/2026012700.csv +0 -173
- json_model_compiler-2.0b39/site/benchmarks/2026012700.json +0 -296
- json_model_compiler-2.0b39/site/benchmarks/2026012700.md +0 -216
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/.gitignore +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/.gitmodules +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/API.md +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/DESIGN.md +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/DEV.md +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/DOC.md +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/HOWTO.md +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/INTEGRATION.md +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/MANIFEST.in +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/PUBS.md +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/README.md +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/SPEC.md +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/TUTO.md +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/about.sh +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/container/.dockerignore +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/container/.gitignore +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/container/Containerfile +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/container/Makefile +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/container/README.md +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/container/jmc +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/README.md +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/__init__.py +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/analyze.py +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/clang.py +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/convert.py +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/data/clang_entry.c +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/data/clang_free.c +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/data/clang_init.c +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/data/clang_pcre2_fun.c +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/data/clang_re2_fun.c +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/data/java_free.java +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/data/java_init.java +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/data/javascript_exe.js +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/data/javascript_foot.js +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/data/javascript_free.js +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/data/javascript_head.js +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/data/javascript_init.js +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/data/javascript_main.js +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/data/jmc.pod +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/data/perl_exe.pl +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/data/perl_free.pl +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/data/perl_init.pl +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/data/perl_main.pl +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/data/plpgsql_entry.sql +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/data/python_entry.py +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/data/python_exe.py +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/data/python_free.py +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/data/python_init.py +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/data/python_main.py +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/export.py +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/irep.py +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/java.py +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/language.py +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/model.py +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/mtypes.py +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/objmerge.py +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/perl.py +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/plpgsql.py +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/python.py +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/recurse.py +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/resolver.py +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/runtime/Makefile +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/runtime/__init__.py +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/runtime/c/Makefile +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/runtime/c/json-model.c +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/runtime/c/json-model.h +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/runtime/java/.gitignore +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/runtime/java/Makefile +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/runtime/java/README.md +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/runtime/java/env.bash +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/runtime/java/json_model/Checker.java +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/runtime/java/json_model/GSON.java +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/runtime/java/json_model/JSON.java +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/runtime/java/json_model/JSONP.java +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/runtime/java/json_model/Jackson.java +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/runtime/java/json_model/ModelChecker.java +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/runtime/java/json_model/Path.java +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/runtime/java/json_model/Report.java +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/runtime/java/json_model/Runtime.java +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/runtime/js/README.md +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/runtime/js/index.js +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/runtime/js/package.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/runtime/pl/.gitignore +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/runtime/pl/Changes +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/runtime/pl/LICENSE +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/runtime/pl/MANIFEST +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/runtime/pl/Makefile.PL +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/runtime/pl/README +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/runtime/pl/env.bash +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/runtime/pl/ignore.txt +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/runtime/pl/t/00-load.t +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/runtime/pl/t/manifest.t +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/runtime/pl/t/pod-coverage.t +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/runtime/pl/t/pod.t +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/runtime/pl/xt/boilerplate.t +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/runtime/sql/META.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/runtime/sql/Makefile +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/runtime/sql/json_model--2.0.sql +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/runtime/sql/json_model.control +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/runtime/support.py +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/runtime/types.py +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/url_cache.py +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model/utils.py +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model_compiler.egg-info/dependency_links.txt +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model_compiler.egg-info/entry_points.txt +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model_compiler.egg-info/requires.txt +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/json_model_compiler.egg-info/top_level.txt +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/models/ansiblelint-meta.model.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/models/cypress.model.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/models/diploma-arrete.model.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/models/diploma-export.model.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/models/everything.model.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/models/fresq.model.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/models/geo-easy.model.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/models/geo.model.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/models/jmc-ir.model.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/models/json-model-latest.model.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/models/json-model-moschin.model.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/models/json-model-no-merge.model.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/models/json-model-v1.model.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/models/json-model-v2-en.model.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/models/json-model-v2.model.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/models/json-model.model.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/models/json-schema-draft-01-fuzzy.model.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/models/json-schema-draft-01-nesting.model.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/models/json-schema-draft-01.model.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/models/json-schema-draft-02-fuzzy.model.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/models/json-schema-draft-02-nesting.model.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/models/json-schema-draft-02.model.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/models/json-schema-draft-03-fuzzy.model.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/models/json-schema-draft-03-nesting.model.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/models/json-schema-draft-03.model.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/models/json-schema-draft-04-fuzzy.model.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/models/json-schema-draft-04-mongodb.model.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/models/json-schema-draft-04-nesting.model.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/models/json-schema-draft-04.model.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/models/json-schema-draft-06-fuzzy.model.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/models/json-schema-draft-06.model.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/models/json-schema-draft-07-fuzzy.model.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/models/json-schema-draft-07.model.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/models/json-schema-draft-2019-09-fuzzy.model.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/models/json-schema-draft-2019-09.model.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/models/json-schema-draft-2020-12-fuzzy.model.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/models/json-schema-draft-2020-12-tight.model.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/models/json-schema-draft-2020-12.model.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/models/json-schema-draft-next-fuzzy.model.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/models/json-schema-draft-next.model.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/models/json-schema-draft-tight.model.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/models/json-schema-draft-tighter-loose.model.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/models/json-schema-draft-tighter.model.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/models/json-schema-linter.model.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/models/jsound.model.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/models/l10n.model.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/models/lazygit.model.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/models/openapi-311-fuzzy.model.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/models/openapi-311-models.model.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/models/openapi-311.model.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/models/person.model.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/models/person2.model.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/models/pgxn.model.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/models/test-schema.model.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/package.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/setup.cfg +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/site/API.md +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/site/DEV.md +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/site/DOC.md +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/site/HOWTO.md +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/site/PUBS.md +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/site/README.md +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/site/SPEC.md +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/site/TUTO.md +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/site/benchmarks/2026020500.csv +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/site/benchmarks/2026020500.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/site/benchmarks/2026020500.md +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/site/benchmarks/2026020600.csv +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/site/benchmarks/2026020600.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/site/benchmarks/2026020600.md +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/site/benchmarks/2026021000.csv +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/site/benchmarks/2026021000.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/site/benchmarks/2026021000.md +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/site/benchmarks/2026021300.csv +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/site/benchmarks/2026021300.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/site/benchmarks/2026021300.md +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/site/benchmarks/2026021700.csv +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/site/benchmarks/2026021700.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/site/benchmarks/2026021700.md +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/site/benchmarks/2026021701.csv +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/site/benchmarks/2026021701.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/site/benchmarks/2026021701.md +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/site/benchmarks/2026021702.csv +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/site/benchmarks/2026021702.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/site/benchmarks/2026021702.md +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/site/benchmarks/2026021900.csv +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/site/benchmarks/2026021900.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/site/benchmarks/2026021900.md +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/site/benchmarks/2026022000.csv +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/site/benchmarks/2026022000.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/site/benchmarks/2026022000.md +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/site/benchmarks/2026022400.csv +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/site/benchmarks/2026022400.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/site/benchmarks/2026022400.md +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/site/benchmarks/2026030700.csv +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/site/benchmarks/2026030700.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/site/benchmarks/2026030700.md +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/site/benchmarks/2026030703.csv +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/site/benchmarks/2026030703.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/site/benchmarks/2026030703.md +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/site/benchmarks/2026030901.csv +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/site/benchmarks/2026030901.json +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/site/benchmarks/2026030901.md +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/site/cover.md +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/site/favicon.ico +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/site/index.html +0 -0
- {json_model_compiler-2.0b39 → json_model_compiler-2.0b41}/site/json_logo.svg +0 -0
|
@@ -2,13 +2,13 @@
|
|
|
2
2
|
|
|
3
3
|
## Current Tasks
|
|
4
4
|
|
|
5
|
-
- [x] optim:
|
|
6
|
-
- [x]
|
|
7
|
-
- [x]
|
|
8
|
-
- [x]
|
|
5
|
+
- [x] optim: do not recheck object if not necessary
|
|
6
|
+
- [x] command: show runtime directory with `--runtime`
|
|
7
|
+
- [x] optim: better merge `&` list when possible, including regex prefix incompatibilities
|
|
8
|
+
- [x] js-backend: export model map
|
|
9
|
+
- [x] pl-backend: add and export `_mapper` function
|
|
9
10
|
- [ ] optim: simplify _(x ^ M) & (x | T)_ where _M in T_
|
|
10
11
|
- [ ] optim: recognize typed not: _"" ^ "xxx"_
|
|
11
|
-
- [ ] optim: merge `&` list when possible, eg inclusions or compatibility
|
|
12
12
|
- [ ] backend: implement new predefs with IP4, IP6, HOSTNAME, JSONPT, DURATION (just with regex?)
|
|
13
13
|
- [ ] \*-backend: add support for embedded nul characters in strings, when possible, or fail gracefully
|
|
14
14
|
- [ ] doc: add _known limitations_ stuff
|
|
@@ -790,3 +790,9 @@
|
|
|
790
790
|
- [x] tests: add _stats_ target
|
|
791
791
|
- [x] perf: add missing warmup to C runtime for jsonschema benchmark
|
|
792
792
|
- [x] perl-backend: be resilient on missing RE2 module
|
|
793
|
+
- [x] optim: implement any type but one constrained optimization (jsu)
|
|
794
|
+
- [x] ir: fix bad elimination when bool var was used
|
|
795
|
+
- [x] ir: add bool var assign elimination on return with only one use
|
|
796
|
+
- [x] c-backend: fix long option parsing
|
|
797
|
+
- [x] c-backend: use monotonic instead of realtime clock which has a better precision
|
|
798
|
+
- [x] java-backend: fix previously untested `--jsonschema-benchmark` implementation
|
|
@@ -9,7 +9,9 @@ schema to model converter in C, JS, Java (GSON, Jackson and JSONP using Johnzon)
|
|
|
9
9
|
|
|
10
10
|
## Recent Artifacts
|
|
11
11
|
|
|
12
|
-
- [
|
|
12
|
+
- [2026031300](benchmarks/2026031300.md) clang, no predefs, jsu 0.9.1/jmc 2.0b40 vs sbc 14.14.2, 11 runs, 1000 iterations.
|
|
13
|
+
- [2026031000](benchmarks/2026031000.md) clang, no predefs, jsu 0.9.1/jmc 2.0b39 vs sbc 14.14.2, 11 runs, 1000 iterations.
|
|
14
|
+
- [2026030901](benchmarks/2026030901.md) clang, no predefs, jsu 0.9.1/jmc 2.0b38 vs sbc 14.14.2, 11 runs, 1000 iterations.
|
|
13
15
|
- [2026030703](benchmarks/2026030703.md) clang, no predefs, jmc 2.0b37 vs sbc 14.14.2, 11 runs, 1000 iterations.
|
|
14
16
|
- [2026030700](benchmarks/2026030700.md) clang, no predefs, jmc 2.0b37 vs sbc 14.13.4, 5 runs, 1000 iterations.
|
|
15
17
|
- [2026022400](benchmarks/2026022400.md) clang, no predefs, jmc 2.0b36 vs sbc 14.13.4, 11 runs, 1000 iterations.
|
|
@@ -22,13 +24,6 @@ schema to model converter in C, JS, Java (GSON, Jackson and JSONP using Johnzon)
|
|
|
22
24
|
- [2026021000](benchmarks/2026021000.md) clang, no predefs, jmc 2.0b36 vs sbc 14.7.2, 11 runs, 1000 iterations.
|
|
23
25
|
- [2026020600](benchmarks/2026020600.md) clang, no predefs, jmc 2.0b36 vs sbc 14.7.1, 11 runs, 1000 iterations.
|
|
24
26
|
- [2026020500](benchmarks/2026020500.md) clang, no predefs, jmc 2.0b36 vs sbc 14.6.1, 11 runs, 1000 iterations.
|
|
25
|
-
- [2026012700](benchmarks/2026012700.md) clang, no predefs, jmc 2.0b36 vs sbc 14.5.0, 11 runs, 1000 iterations.
|
|
26
|
-
- [2026012400](benchmarks/2026012400.md) clang, no predefs, jmc 2.0b36 vs sbc 14.4.0, 11 runs, 1000 iterations.
|
|
27
|
-
- [2026012200](benchmarks/2026012200.md) clang, no predefs, jmc 2.0b36 vs sbc 14.2.0, 11 runs, 1000 iterations.
|
|
28
|
-
- [2026012000](benchmarks/2026012000.md) clang, no predefs, jmc 2.0b36 vs sbc 14.1.0, 11 runs, 1000 iterations.
|
|
29
|
-
- [2026011500](benchmarks/2026011500.md) clang, no predefs, jmc 2.0b36 vs sbc 14.0.4, 11 runs, 1000 iterations.
|
|
30
|
-
- [2026010900](benchmarks/2026010900.md) clang, no predefs, jmc 2.0b36 vs sbc 14.0.3, 11 runs, 1000 iterations.
|
|
31
|
-
- [2026010600](benchmarks/2026010600.md) clang, no predefs, jmc 2.0b36 vs sbc 14.0.2, 11 runs, 1000 iterations.
|
|
32
27
|
|
|
33
28
|
## Benchmarking Script
|
|
34
29
|
|
|
@@ -7,14 +7,35 @@ ifndef PYTHON
|
|
|
7
7
|
PYTHON = python
|
|
8
8
|
endif
|
|
9
9
|
|
|
10
|
-
venv:
|
|
10
|
+
venv: venv/.init
|
|
11
|
+
|
|
12
|
+
venv/.init:
|
|
11
13
|
$(PYTHON) -m venv venv
|
|
12
14
|
source venv/bin/activate
|
|
13
15
|
pip install -U pip
|
|
16
|
+
pip install -e .
|
|
17
|
+
touch $@
|
|
18
|
+
|
|
19
|
+
venv/.dev: venv/.init
|
|
14
20
|
pip install -e .[dev]
|
|
21
|
+
touch $@
|
|
22
|
+
|
|
23
|
+
venv/.dist: venv/.dev
|
|
24
|
+
pip install -e .[dist]
|
|
25
|
+
touch $@
|
|
15
26
|
|
|
16
27
|
.PHONY: dev
|
|
17
|
-
dev: venv
|
|
28
|
+
dev: venv/.dev dev.js dev.java
|
|
29
|
+
|
|
30
|
+
.PHONY: dev.js
|
|
31
|
+
dev.js: node_modules
|
|
32
|
+
|
|
33
|
+
node_modules:
|
|
34
|
+
npm install
|
|
35
|
+
|
|
36
|
+
.PHONY: dev.java
|
|
37
|
+
dev.java:
|
|
38
|
+
$(MAKE) -C json_model/runtime/java jar
|
|
18
39
|
|
|
19
40
|
.PHONY: clean
|
|
20
41
|
clean: clean.site
|
|
@@ -110,7 +131,7 @@ publish.site: build.site
|
|
|
110
131
|
ssh $(SITE) chmod a+r $(SITEPATH)/* $(SITEPATH)/models/* $(SITEPATH)/benchmarks/*
|
|
111
132
|
|
|
112
133
|
.PHONY: publish.py
|
|
113
|
-
publish.py:
|
|
134
|
+
publish.py: venv/.dist
|
|
114
135
|
source venv/bin/activate
|
|
115
136
|
python -m build
|
|
116
137
|
twine check dist/*
|
|
@@ -137,12 +158,12 @@ publish.perl:
|
|
|
137
158
|
# $(RM) $(RT.dir)/pl/Makefile.old
|
|
138
159
|
|
|
139
160
|
.PHONY: publish.js
|
|
140
|
-
publish.js:
|
|
161
|
+
publish.js: dev.js
|
|
141
162
|
npm publish --dry-run $(RT.dir)/js
|
|
142
163
|
echo npm publish --access public --tag latest $(RT.dir)/js
|
|
143
164
|
|
|
144
165
|
.PHONY: publish.java
|
|
145
|
-
publish.java:
|
|
166
|
+
publish.java: dev.java
|
|
146
167
|
$(MAKE) -C $(RT.dir)/java zip
|
|
147
168
|
# see https://central.sonatype.org/publish/requirements/
|
|
148
169
|
# upload zip on https://central.sonatype.com/publishing as org.json-model:json-model:VERSION
|
|
@@ -281,7 +281,8 @@ class JavaScript(Language):
|
|
|
281
281
|
# Property Map
|
|
282
282
|
#
|
|
283
283
|
def def_pmap(self, name: str, pmap: PropMap, public: bool) -> Block:
|
|
284
|
-
|
|
284
|
+
export = "export " if public else ""
|
|
285
|
+
return [ f"{export}var {name} = new Map()" ]
|
|
285
286
|
|
|
286
287
|
def ini_pmap(self, name: str, pmap: PropMap, public: bool) -> Block:
|
|
287
288
|
return [ f"{name}.set({self.esc(p)}, {f})" for p, f in pmap.items() ]
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
#
|
|
2
2
|
# Model Optimizations
|
|
3
3
|
#
|
|
4
|
+
import re
|
|
4
5
|
from .mtypes import ModelPath, ModelType
|
|
5
6
|
from .utils import log, is_cst, _structurally_distinct_models, model_type, is_base_model
|
|
6
7
|
from .utils import constant_values, same_model, model_eq
|
|
@@ -53,35 +54,6 @@ def normalizeModels(models: list[ModelType]) -> int:
|
|
|
53
54
|
|
|
54
55
|
return changes
|
|
55
56
|
|
|
56
|
-
def _simple_open_object(model: ModelType, jm: JsonModel, path: ModelPath) -> list[str]|None:
|
|
57
|
-
"""Detect simple may/must open objects, return property names."""
|
|
58
|
-
if jm._isRef(model):
|
|
59
|
-
model = jm.resolveRef(model, path)._model
|
|
60
|
-
if isinstance(model, dict):
|
|
61
|
-
props, is_open = [], False
|
|
62
|
-
for prop in model.keys():
|
|
63
|
-
assert isinstance(prop, str)
|
|
64
|
-
if prop == "":
|
|
65
|
-
is_open = model[""] == "$ANY"
|
|
66
|
-
if not is_open:
|
|
67
|
-
return None
|
|
68
|
-
elif prop in ("$", "%", "~") or prop[0] == "#":
|
|
69
|
-
pass
|
|
70
|
-
elif prop[0] in ("$", "/"):
|
|
71
|
-
return None
|
|
72
|
-
elif prop[0] in ("?", "_", "!"):
|
|
73
|
-
name = prop[1:]
|
|
74
|
-
if name in props: # not safe?
|
|
75
|
-
return None
|
|
76
|
-
props.append(name)
|
|
77
|
-
else:
|
|
78
|
-
if prop in props: # not safe?
|
|
79
|
-
return None
|
|
80
|
-
props.append(prop)
|
|
81
|
-
return props if is_open else None
|
|
82
|
-
else:
|
|
83
|
-
return None
|
|
84
|
-
|
|
85
57
|
def and_not_simpler(jm: JsonModel) -> bool:
|
|
86
58
|
"""Change and(T, xor(ANY, …)) to xor(T, and(T, …))."""
|
|
87
59
|
# this does not generalize, the idea is to forward the type to both sides
|
|
@@ -131,6 +103,77 @@ def and_not_simpler(jm: JsonModel) -> bool:
|
|
|
131
103
|
log.debug(f"{jm._id}: ans {changes}")
|
|
132
104
|
return changes > 0
|
|
133
105
|
|
|
106
|
+
def _simple_open_object(model: ModelType, jm: JsonModel, path: ModelPath) -> list[str]|None:
|
|
107
|
+
"""Detect simple may/must/regs open objects, return property names and regs."""
|
|
108
|
+
if jm._isRef(model):
|
|
109
|
+
model = jm.resolveRef(model, path)._model
|
|
110
|
+
if isinstance(model, dict):
|
|
111
|
+
props, is_open = [], False
|
|
112
|
+
for prop in model.keys():
|
|
113
|
+
assert isinstance(prop, str)
|
|
114
|
+
if prop == "":
|
|
115
|
+
is_open = model[""] == "$ANY"
|
|
116
|
+
# NOTE it could also be partially open…
|
|
117
|
+
if not is_open:
|
|
118
|
+
return None
|
|
119
|
+
elif prop in ("$", "%", "~") or prop[0] == "#":
|
|
120
|
+
pass
|
|
121
|
+
elif prop[0] == "$":
|
|
122
|
+
# TODO follow definition!
|
|
123
|
+
return None
|
|
124
|
+
elif prop[0] == "/":
|
|
125
|
+
props.append(prop)
|
|
126
|
+
elif prop[0] in ("?", "_", "!"):
|
|
127
|
+
name = "_" + prop[1:]
|
|
128
|
+
if name in props: # not safe?
|
|
129
|
+
return None
|
|
130
|
+
props.append(name)
|
|
131
|
+
else:
|
|
132
|
+
name = "_" + prop
|
|
133
|
+
if name in props: # not safe?
|
|
134
|
+
return None
|
|
135
|
+
props.append(name)
|
|
136
|
+
return props if is_open else None
|
|
137
|
+
else:
|
|
138
|
+
return None
|
|
139
|
+
|
|
140
|
+
def _prefix_reg(reg: str) -> str|None:
|
|
141
|
+
"""Prefix of simple prefix regex."""
|
|
142
|
+
# FIXME must handle ignore-case option
|
|
143
|
+
m = re.match(r"/\^([-_A-Za-z0-9]+)", reg)
|
|
144
|
+
return m.group(1) if m else None
|
|
145
|
+
|
|
146
|
+
def _bad_regs(lobj: list[list[str]|None]) -> set[str]:
|
|
147
|
+
"""Identify regs which cannot be merged, based on prefix compatibilities."""
|
|
148
|
+
# NOTE we could check only with regs with props from **other** objects
|
|
149
|
+
all_props, all_regs, bad_regs = set(), set(), set()
|
|
150
|
+
for lp in lobj:
|
|
151
|
+
if lp is not None:
|
|
152
|
+
assert isinstance(lp, list)
|
|
153
|
+
all_props.update(filter(lambda s: s[0] == "_", lp))
|
|
154
|
+
all_regs.update(filter(lambda s: s[0] == "/", lp))
|
|
155
|
+
# drop leading "_"
|
|
156
|
+
all_props = { s[1:] for s in all_props }
|
|
157
|
+
prefixes = {}
|
|
158
|
+
for r in all_regs:
|
|
159
|
+
# regex incompatibilities between themselves
|
|
160
|
+
prefix = _prefix_reg(r)
|
|
161
|
+
if prefix is None:
|
|
162
|
+
bad_regs.add(r)
|
|
163
|
+
continue
|
|
164
|
+
# check for prefix inclusions, including ==
|
|
165
|
+
for p, pr in prefixes.items():
|
|
166
|
+
if prefix.startswith(p) or p.startswith(prefix):
|
|
167
|
+
bad_regs.add(r)
|
|
168
|
+
bad_regs.add(pr)
|
|
169
|
+
prefixes[prefix] = r
|
|
170
|
+
# rough regex incompatibilities with properties
|
|
171
|
+
for p in all_props:
|
|
172
|
+
if p.startswith(prefix):
|
|
173
|
+
bad_regs.add(r)
|
|
174
|
+
# log.debug(f"bad_regs={bad_regs}")
|
|
175
|
+
return bad_regs
|
|
176
|
+
|
|
134
177
|
def and_to_merge(jm: JsonModel) -> bool:
|
|
135
178
|
"""Change and to less costly merge if possible."""
|
|
136
179
|
|
|
@@ -142,19 +185,43 @@ def and_to_merge(jm: JsonModel) -> bool:
|
|
|
142
185
|
land = model["&"]
|
|
143
186
|
assert isinstance(land, list)
|
|
144
187
|
lobj: list[list[str]|None] = list(map(lambda i: _simple_open_object(i, jm, path), land))
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
188
|
+
# subset of mergeables
|
|
189
|
+
n_merges = sum(map(lambda i: 1 if i is not None else 0, lobj))
|
|
190
|
+
if n_merges <= 1:
|
|
191
|
+
return model
|
|
192
|
+
# else something to try
|
|
193
|
+
# FIXME for now partial merges may fail
|
|
194
|
+
sprops, nprops, sregs, nregs, move = set(), 0, set(), 0, []
|
|
195
|
+
# regular expressions to skip
|
|
196
|
+
bad_regs = _bad_regs(lobj)
|
|
197
|
+
for i, lp in enumerate(lobj):
|
|
198
|
+
if lp is not None:
|
|
199
|
+
props = list(filter(lambda s: s[0] == "_", lp))
|
|
200
|
+
regs = list(filter(lambda s: s[0] == "/", lp))
|
|
201
|
+
# skip objects with a bad regular expression for merging
|
|
202
|
+
if any(filter(lambda r: r in bad_regs, regs)):
|
|
203
|
+
# skip object
|
|
204
|
+
continue
|
|
205
|
+
# else let us accumulate
|
|
206
|
+
nprops += len(props)
|
|
207
|
+
sprops.update(props)
|
|
208
|
+
nregs += len(regs)
|
|
209
|
+
sregs.update(regs)
|
|
210
|
+
move.append(i)
|
|
211
|
+
# log.debug(f"move={move} sprops={sprops} sregs={sregs}")
|
|
212
|
+
# no property intersection, change is safe
|
|
213
|
+
if len(move) > 1 and nprops == len(sprops) and nregs == len(sregs):
|
|
214
|
+
# FIXME the generated merge may fail, which may denote an unfeasible model?
|
|
215
|
+
changes += 1
|
|
216
|
+
merge = [ land[i] for i in move ]
|
|
217
|
+
for i in reversed(move):
|
|
218
|
+
land.pop(i)
|
|
219
|
+
if len(land) == 0:
|
|
156
220
|
del model["&"]
|
|
157
|
-
|
|
221
|
+
model["+"] = merge
|
|
222
|
+
else:
|
|
223
|
+
land.append({"+": merge})
|
|
224
|
+
# else property collision, probably not safe
|
|
158
225
|
return model
|
|
159
226
|
|
|
160
227
|
jm._model = recModel(jm._model, builtFlt, a2mRwt)
|
|
@@ -9,6 +9,8 @@
|
|
|
9
9
|
|
|
10
10
|
#include <json-model.h>
|
|
11
11
|
|
|
12
|
+
#define str_eq(s1, s2) (strcmp(s1, s2) == 0)
|
|
13
|
+
|
|
12
14
|
typedef enum {
|
|
13
15
|
expect_nothing,
|
|
14
16
|
expect_anything,
|
|
@@ -16,11 +18,14 @@ typedef enum {
|
|
|
16
18
|
expect_pass
|
|
17
19
|
} process_mode_t;
|
|
18
20
|
|
|
19
|
-
//
|
|
21
|
+
// NOTE CLOCK_REALTIME resolution seems low at 0.250 µs
|
|
22
|
+
static clockid_t current_clock = CLOCK_MONOTONIC;
|
|
23
|
+
|
|
24
|
+
// return realtime(?) µs
|
|
20
25
|
static INLINE double now(void)
|
|
21
26
|
{
|
|
22
27
|
struct timespec ts;
|
|
23
|
-
if (unlikely(clock_gettime(
|
|
28
|
+
if (unlikely(clock_gettime(current_clock, &ts)))
|
|
24
29
|
{
|
|
25
30
|
fprintf(stderr, "cannot get time (%d): %s\n", errno, strerror(errno));
|
|
26
31
|
exit(2);
|
|
@@ -28,6 +33,18 @@ static INLINE double now(void)
|
|
|
28
33
|
return 1000000.0 * ts.tv_sec + 0.001 * ts.tv_nsec;
|
|
29
34
|
}
|
|
30
35
|
|
|
36
|
+
// return clock resolution in µs (may be probably optimistic)
|
|
37
|
+
static double getres(void)
|
|
38
|
+
{
|
|
39
|
+
struct timespec ts;
|
|
40
|
+
if (unlikely(clock_getres(current_clock, &ts)))
|
|
41
|
+
{
|
|
42
|
+
fprintf(stderr, "cannot get clock resolution (%d): %s\n", errno, strerror(errno));
|
|
43
|
+
exit(2);
|
|
44
|
+
}
|
|
45
|
+
return 1000000.0 * ts.tv_sec + 0.001 * ts.tv_nsec;
|
|
46
|
+
}
|
|
47
|
+
|
|
31
48
|
// small computation to avoid compiler optimizations that could remove empty loops
|
|
32
49
|
#define NEXT_STUFF(v, pi) v = frexp(3.141592653589793 * v + 2.718281828459045, pi)
|
|
33
50
|
|
|
@@ -291,10 +308,12 @@ int main(int argc, char* argv[])
|
|
|
291
308
|
{ "slow", no_argument, NULL, 1001 },
|
|
292
309
|
{ "jsonschema-benchmark", no_argument, NULL, 1002 },
|
|
293
310
|
{ "no-report", no_argument, NULL, 1003 },
|
|
311
|
+
{ "resolution", no_argument, NULL, 1004 },
|
|
312
|
+
{ "clock", required_argument, NULL, 'C' },
|
|
294
313
|
{ NULL, 0, NULL, 0 }
|
|
295
314
|
};
|
|
296
315
|
|
|
297
|
-
while ((opt = getopt_long(argc, argv, "hvln:rtT:", options, NULL)) != -1)
|
|
316
|
+
while ((opt = getopt_long(argc, argv, "hvln:rtT:C:", options, NULL)) != -1)
|
|
298
317
|
{
|
|
299
318
|
switch (opt) {
|
|
300
319
|
case 'h': // FIXME expand help!
|
|
@@ -343,6 +362,27 @@ int main(int argc, char* argv[])
|
|
|
343
362
|
case 1003:
|
|
344
363
|
report = false;
|
|
345
364
|
break;
|
|
365
|
+
case 1004:
|
|
366
|
+
fprintf(stderr, "clock resolution: %.03f µs\n", getres());
|
|
367
|
+
break;
|
|
368
|
+
case 'C':
|
|
369
|
+
if (str_eq(optarg, "monotonic") || str_eq(optarg, "m"))
|
|
370
|
+
current_clock = CLOCK_MONOTONIC;
|
|
371
|
+
else if (str_eq(optarg, "realtime") || str_eq(optarg, "r"))
|
|
372
|
+
current_clock = CLOCK_REALTIME;
|
|
373
|
+
#ifdef CLOCK_PROCESS_CPUTIME_ID
|
|
374
|
+
else if (str_eq(optarg, "process") || str_eq(optarg, "p"))
|
|
375
|
+
current_clock = CLOCK_PROCESS_CPUTIME_ID;
|
|
376
|
+
#endif
|
|
377
|
+
#ifdef CLOCK_THREAD_CPUTIME_ID
|
|
378
|
+
else if (str_eq(optarg, "thread") || str_eq(optarg, "t"))
|
|
379
|
+
current_clock = CLOCK_THREAD_CPUTIME_ID;
|
|
380
|
+
#endif
|
|
381
|
+
else {
|
|
382
|
+
fprintf(stderr, "unexpected clock %s for [mrpt]\n", optarg);
|
|
383
|
+
return 1;
|
|
384
|
+
}
|
|
385
|
+
break;
|
|
346
386
|
case '?':
|
|
347
387
|
default:
|
|
348
388
|
fprintf(stdout, "unexpected option encountered\n");
|
|
@@ -386,7 +426,7 @@ int main(int argc, char* argv[])
|
|
|
386
426
|
{
|
|
387
427
|
int exponent;
|
|
388
428
|
double v = frexp(loop / 13.0, &exponent);
|
|
389
|
-
int count =
|
|
429
|
+
int count = 1000;
|
|
390
430
|
while (count)
|
|
391
431
|
{
|
|
392
432
|
double e = overhead_estimation(loop, &v);
|
|
@@ -47,7 +47,7 @@ public class Main
|
|
|
47
47
|
// cold run
|
|
48
48
|
long cold_start = System.nanoTime();
|
|
49
49
|
for (Object value: values)
|
|
50
|
-
if (check.call(value))
|
|
50
|
+
if (!check.call(value))
|
|
51
51
|
errors++;
|
|
52
52
|
double cold_run = 0.001 * (System.nanoTime() - cold_start);
|
|
53
53
|
|
|
@@ -60,7 +60,7 @@ public class Main
|
|
|
60
60
|
|
|
61
61
|
// measure
|
|
62
62
|
double sum = 0.0, sum2 = 0.0;
|
|
63
|
-
for (int n = time; n > 0;
|
|
63
|
+
for (int n = time; n > 0; n--)
|
|
64
64
|
{
|
|
65
65
|
long start = System.nanoTime();
|
|
66
66
|
for (Object value: values)
|
|
@@ -231,6 +231,8 @@ public class Main
|
|
|
231
231
|
break;
|
|
232
232
|
case 1002: // --jsonschema-benchmark
|
|
233
233
|
jsbench = true;
|
|
234
|
+
jsonl = true;
|
|
235
|
+
if (time <= 0) time = 1;
|
|
234
236
|
break;
|
|
235
237
|
case 1003: // --no-report
|
|
236
238
|
report = false;
|
|
@@ -78,7 +78,7 @@ function jsonschema_benchmark(values, checker, times)
|
|
|
78
78
|
const WARMUP_ITERATIONS = 1000 // unless too long
|
|
79
79
|
const max_iterations = Math.ceil(WARMUP_MAX_TIME * 1000.0 / cold_delay)
|
|
80
80
|
const warmup_iterations = Math.min(WARMUP_ITERATIONS, max_iterations)
|
|
81
|
-
console.error(`warmup iterations: ${warmup_iterations}`)
|
|
81
|
+
// console.error(`warmup iterations: ${warmup_iterations}`)
|
|
82
82
|
for (let i = 0; i < warmup_iterations; i++)
|
|
83
83
|
for (const v of values)
|
|
84
84
|
checker(v, '', null)
|
|
@@ -10,7 +10,7 @@ use warnings;
|
|
|
10
10
|
|
|
11
11
|
# no Carp, this modules runs with automatically generated code, all issues are ours?
|
|
12
12
|
|
|
13
|
-
our $VERSION = 1.
|
|
13
|
+
our $VERSION = 1.999038; # aka 2.0b38
|
|
14
14
|
|
|
15
15
|
eval "use re::engine::RE2"; # try to replace regex engine
|
|
16
16
|
use List::Util qw( min );
|
|
@@ -286,6 +286,7 @@ def jmc_script():
|
|
|
286
286
|
arg("--doc", choices=["pod", "syn", "help", "man"], default=None,
|
|
287
287
|
help="show documentation and exit")
|
|
288
288
|
arg("--man", dest="doc", action="store_const", const="man", help="show man page")
|
|
289
|
+
arg("--runtime", default=False, action="store_true", help="show runtime source directory")
|
|
289
290
|
|
|
290
291
|
# verbosity and checks
|
|
291
292
|
arg("--version", action="store_true", help="show current version and exit")
|
|
@@ -464,6 +465,10 @@ def jmc_script():
|
|
|
464
465
|
print(pkg_version("json_model_compiler"))
|
|
465
466
|
sys.exit(0)
|
|
466
467
|
|
|
468
|
+
if args.runtime:
|
|
469
|
+
print(files("json_model.runtime"))
|
|
470
|
+
sys.exit(0)
|
|
471
|
+
|
|
467
472
|
# POD - Plain Old Documentation
|
|
468
473
|
if args.doc:
|
|
469
474
|
# Python does not provide any help to write man pages for the user
|