leptris 1.9.457.0-arm-linux → 1.9.460.0-arm-linux
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.
- checksums.yaml +4 -4
- data/CHANGELOG.md +22 -0
- data/CONTEXT.md +9 -3
- data/README.adoc +28 -17
- data/Rakefile +1 -1
- data/lib/leptris/version.rb +1 -1
- data/lib/leptris/xml/document.rb +75 -48
- data/lib/leptris/xml/ffi.rb +8 -0
- data/lib/libleptris.so +0 -0
- data/vendor-src/README.md +1 -1
- data/vendor-src/libleptris/CHANGELOG.md +54 -0
- data/vendor-src/libleptris/CMakeLists.txt +1 -1
- data/vendor-src/libleptris/README.adoc +19 -0
- data/vendor-src/libleptris/benchmarks/CMakeLists.txt +23 -2
- data/vendor-src/libleptris/benchmarks/README.adoc +15 -0
- data/vendor-src/libleptris/benchmarks/README.md +17 -4
- data/vendor-src/libleptris/benchmarks/comprehensive/benchmark_decomp.cpp +2 -1
- data/vendor-src/libleptris/benchmarks/comprehensive/benchmark_first_access.cpp +2 -1
- data/vendor-src/libleptris/benchmarks/comprehensive/benchmark_many_attrs.cpp +2 -1
- data/vendor-src/libleptris/benchmarks/comprehensive/benchmark_memory.cpp +2 -1
- data/vendor-src/libleptris/benchmarks/comprehensive/benchmark_parse.cpp +2 -2
- data/vendor-src/libleptris/benchmarks/comprehensive/benchmark_parse_ops.cpp +8 -4
- data/vendor-src/libleptris/benchmarks/comprehensive/benchmark_write.cpp +4 -2
- data/vendor-src/libleptris/benchmarks/dom/dom_benchmark_v2.cpp +8 -4
- data/vendor-src/libleptris/benchmarks/fixtures/serialbench_users_medium.xml +13004 -0
- data/vendor-src/libleptris/benchmarks/matrix/bench_matrix.cpp +21 -76
- data/vendor-src/libleptris/benchmarks/matrix/bench_matrix_fused.cpp +31 -0
- data/vendor-src/libleptris/benchmarks/matrix/bench_rows.h +94 -0
- data/vendor-src/libleptris/benchmarks/modification/bench_append_attr_pugixml.cpp +2 -1
- data/vendor-src/libleptris/benchmarks/parse/bench_parse_ab.cpp +2 -1
- data/vendor-src/libleptris/benchmarks/twins/generation_users.sh +49 -0
- data/vendor-src/libleptris/benchmarks/twins/generation_users_fixture.h +78 -0
- data/vendor-src/libleptris/benchmarks/twins/generation_users_leptris.c +122 -0
- data/vendor-src/libleptris/benchmarks/twins/generation_users_pugixml.cpp +231 -0
- data/vendor-src/libleptris/benchmarks/twins/parse_pugixml.cpp +1 -1
- data/vendor-src/libleptris/benchmarks/twins/parse_users_ab.cpp +158 -0
- data/vendor-src/libleptris/benchmarks/workflows/bench_pipeline_shapes.cpp +12 -4
- data/vendor-src/libleptris/benchmarks/xpath/bench_pugixml.cpp +2 -1
- data/vendor-src/libleptris/cli/CLI_ARCHITECTURE.md +9 -1
- data/vendor-src/libleptris/cli/commands/diff.c +26 -28
- data/vendor-src/libleptris/cli/commands/format.c +3 -1
- data/vendor-src/libleptris/cli/commands/parse.c +3 -1
- data/vendor-src/libleptris/cli/commands/validate.c +22 -24
- data/vendor-src/libleptris/cli/commands/xpath.c +9 -1
- data/vendor-src/libleptris/cli/commands/xquery.c +12 -3
- data/vendor-src/libleptris/cli/commands/xslt.c +24 -8
- data/vendor-src/libleptris/cli/error.c +91 -0
- data/vendor-src/libleptris/cli/error.h +84 -0
- data/vendor-src/libleptris/cli/man/leptris-parse.1.adoc +21 -10
- data/vendor-src/libleptris/cli/man/leptris.1.adoc +19 -0
- data/vendor-src/libleptris/cli/output.c +18 -9
- data/vendor-src/libleptris/cli/output.h +17 -0
- data/vendor-src/libleptris/src/CMakeLists.txt +3 -0
- data/vendor-src/libleptris/src/include/leptris/types.h +25 -1
- data/vendor-src/libleptris/src/include/leptris/xquery/xquery.h +9 -1
- data/vendor-src/libleptris/src/include/leptris.h +48 -3
- data/vendor-src/libleptris/src/leptris/common/entities.c +2 -2
- data/vendor-src/libleptris/src/leptris/common/entities.h +8 -2
- data/vendor-src/libleptris/src/leptris/common/port.h +62 -0
- data/vendor-src/libleptris/src/leptris/common/uri_base.c +284 -0
- data/vendor-src/libleptris/src/leptris/common/uri_base.h +62 -0
- data/vendor-src/libleptris/src/leptris/core.c +33 -2
- data/vendor-src/libleptris/src/leptris/dom/compact.h +51 -0
- data/vendor-src/libleptris/src/leptris/dom/element.c +18 -0
- data/vendor-src/libleptris/src/leptris/dom/element.h +201 -12
- data/vendor-src/libleptris/src/leptris/dom/element_modify.c +611 -210
- data/vendor-src/libleptris/src/leptris/dom/element_query.c +72 -1
- data/vendor-src/libleptris/src/leptris/dom/name_intern.c +3 -1
- data/vendor-src/libleptris/src/leptris/dtd/model.c +13 -0
- data/vendor-src/libleptris/src/leptris/dtd/model.h +95 -6
- data/vendor-src/libleptris/src/leptris/dtd/resolver.c +302 -215
- data/vendor-src/libleptris/src/leptris/flat/direct_parse.c +801 -294
- data/vendor-src/libleptris/src/leptris/leptris.c +20 -5
- data/vendor-src/libleptris/src/leptris/leptris_internal.h +68 -22
- data/vendor-src/libleptris/src/leptris/serialize/serialize.c +289 -57
- data/vendor-src/libleptris/src/leptris/xinclude/xinclude.c +14 -125
- data/vendor-src/libleptris/src/leptris/xpath/evaluator.c +105 -41
- data/vendor-src/libleptris/src/leptris/xpath/evaluator_path.c +11 -8
- data/vendor-src/libleptris/src/leptris/xpath/functions_ext31.c +188 -24
- data/vendor-src/libleptris/src/leptris/xpath/vm.c +3 -1
- data/vendor-src/libleptris/src/leptris/xquery/xquery.c +5 -0
- data/vendor-src/libleptris/src/leptris/xsd/compile.c +272 -41
- data/vendor-src/libleptris/src/leptris/xsd/validate.c +338 -196
- data/vendor-src/libleptris/src/leptris/xsd/xsd_internal.h +27 -0
- data/vendor-src/libleptris/test/CMakeLists.txt +53 -0
- data/vendor-src/libleptris/test/abi/test_public_surface.cpp +37 -0
- data/vendor-src/libleptris/test/cli/test_cli.cpp +228 -0
- data/vendor-src/libleptris/test/common/hang_guard.h +179 -0
- data/vendor-src/libleptris/test/dom/test_compact.cpp +46 -0
- data/vendor-src/libleptris/test/dom/test_mut_append_contracts.cpp +173 -0
- data/vendor-src/libleptris/test/dom/test_mut_set_attr_contracts.cpp +771 -7
- data/vendor-src/libleptris/test/fixtures/entity_limits/good.xml +100 -0
- data/vendor-src/libleptris/test/fixtures/entity_limits/good_attr.xml +100 -0
- data/vendor-src/libleptris/test/fixtures/entity_limits/lol_classic.xml +51 -0
- data/vendor-src/libleptris/test/fixtures/entity_limits/lol_ig_attr.xml +23 -0
- data/vendor-src/libleptris/test/fixtures/entity_limits/lol_ig_content.xml +23 -0
- data/vendor-src/libleptris/test/fixtures/entity_limits/lol_long_name.xml +23 -0
- data/vendor-src/libleptris/test/memory/test_oom_injection.cpp +63 -0
- data/vendor-src/libleptris/test/memory/test_synth_graveyard.cpp +207 -0
- data/vendor-src/libleptris/test/parser/test_entity_limits.cpp +404 -0
- data/vendor-src/libleptris/test/parser/test_parser.cpp +126 -0
- data/vendor-src/libleptris/test/serializer/test_serialize.cpp +491 -0
- data/vendor-src/libleptris/test/xpath/test_base_uri.cpp +368 -0
- data/vendor-src/libleptris/test/xpath/test_xpath.cpp +86 -0
- data/vendor-src/libleptris/test/xsd/libxml2-cases/rs97_w3c/addB034.xml +1 -0
- data/vendor-src/libleptris/test/xsd/libxml2-cases/rs97_w3c/addB034.xsd +13 -0
- data/vendor-src/libleptris/test/xsd/libxml2-cases/rs97_w3c/addB136.xml +4 -0
- data/vendor-src/libleptris/test/xsd/libxml2-cases/rs97_w3c/addB136.xsd +15 -0
- data/vendor-src/libleptris/test/xsd/test_rs97_regression.cpp +132 -0
- data/vendor-src/libleptris/test/xsd/test_xsd11_base_uri.cpp +145 -0
- data/vendor-src/libleptris/test/xsd/test_xsd11_conformance.cpp +23 -5
- data/vendor-src/libleptris/test/xsd/test_xsd11_cta_context.cpp +385 -0
- data/vendor-src/libleptris/test/xsd/test_xsd11_cta_set.cpp +201 -0
- data/vendor-src/libleptris/test/xsd/test_xsd11_opencontent_set.cpp +245 -0
- data/vendor-src/libleptris/test/xsd/xsd-dispositions/README.md +8 -3
- data/vendor-src/libleptris/test/xsd/xsd11-all/all-restrict.xsd +3 -2
- data/vendor-src/libleptris/test/xsd/xsd11-all/all-wildcard.xsd +3 -2
- data/vendor-src/libleptris/test/xsd/xsd11-cases/MANIFEST.tsv +19 -2
- data/vendor-src/libleptris/test/xsd/xsd11-cases/saxonData/CTA/cta0003.n01.xml +5 -0
- data/vendor-src/libleptris/test/xsd/xsd11-cases/saxonData/CTA/cta0003.v01.xml +4 -0
- data/vendor-src/libleptris/test/xsd/xsd11-cases/saxonData/CTA/cta0003.xsd +46 -0
- data/vendor-src/libleptris/test/xsd/xsd11-cases/saxonData/CTA/cta0006.v01.xml +6 -0
- data/vendor-src/libleptris/test/xsd/xsd11-cases/saxonData/CTA/cta0006.xsd +83 -0
- data/vendor-src/libleptris/test/xsd/xsd11-cases/saxonData/CTA/cta0017.v01.xml +3 -0
- data/vendor-src/libleptris/test/xsd/xsd11-cases/saxonData/CTA/cta0017.xsd +36 -0
- data/vendor-src/libleptris/test/xsd/xsd11-cases/saxonData/CTA/cta0021.n01.xml +3 -0
- data/vendor-src/libleptris/test/xsd/xsd11-cases/saxonData/CTA/cta0021.v01.xml +3 -0
- data/vendor-src/libleptris/test/xsd/xsd11-cases/saxonData/CTA/cta0021.xsd +36 -0
- data/vendor-src/libleptris/test/xsd/xsd11-cases/saxonData/CTA/cta0023.v01.xml +3 -0
- data/vendor-src/libleptris/test/xsd/xsd11-cases/saxonData/CTA/cta0024.xsd +40 -0
- data/vendor-src/libleptris/test/xsd/xsd11-dispositions/README.md +67 -0
- data/vendor-src/libleptris/vcpkg.json +1 -1
- metadata +43 -2
|
@@ -138,7 +138,8 @@ static uint64_t workflow_parse_and_read_simple() {
|
|
|
138
138
|
start = Timer::now_ns();
|
|
139
139
|
{
|
|
140
140
|
pugi::xml_document doc;
|
|
141
|
-
doc.load_buffer(test_xml, strlen(test_xml)
|
|
141
|
+
doc.load_buffer(test_xml, strlen(test_xml),
|
|
142
|
+
pugi::parse_default | pugi::parse_ws_pcdata);
|
|
142
143
|
pugi::xml_node root = doc.child("root");
|
|
143
144
|
pugi::xml_node header = root.child("header");
|
|
144
145
|
pugi::xml_node title = header.child("title");
|
|
@@ -187,7 +188,8 @@ static void leptris_workflow_attribute_query() {
|
|
|
187
188
|
|
|
188
189
|
static void pugixml_workflow_attribute_query() {
|
|
189
190
|
pugi::xml_document doc;
|
|
190
|
-
doc.load_buffer(test_xml, strlen(test_xml)
|
|
191
|
+
doc.load_buffer(test_xml, strlen(test_xml),
|
|
192
|
+
pugi::parse_default | pugi::parse_ws_pcdata);
|
|
191
193
|
pugi::xml_node root = doc.child("root");
|
|
192
194
|
pugi::xml_node data = root.child("data");
|
|
193
195
|
|
|
@@ -231,7 +233,8 @@ static void leptris_workflow_tree_traversal() {
|
|
|
231
233
|
|
|
232
234
|
static void pugixml_workflow_tree_traversal() {
|
|
233
235
|
pugi::xml_document doc;
|
|
234
|
-
doc.load_buffer(test_xml, strlen(test_xml)
|
|
236
|
+
doc.load_buffer(test_xml, strlen(test_xml),
|
|
237
|
+
pugi::parse_default | pugi::parse_ws_pcdata);
|
|
235
238
|
|
|
236
239
|
int node_count = 0;
|
|
237
240
|
struct walker {
|
|
@@ -345,7 +348,8 @@ int main(int argc, char** argv) {
|
|
|
345
348
|
|
|
346
349
|
Stats pugixml_simple = benchmark_pugixml_parse_ops([]() {
|
|
347
350
|
pugi::xml_document doc;
|
|
348
|
-
doc.load_buffer(test_xml, strlen(test_xml)
|
|
351
|
+
doc.load_buffer(test_xml, strlen(test_xml),
|
|
352
|
+
pugi::parse_default | pugi::parse_ws_pcdata);
|
|
349
353
|
pugi::xml_node title = doc.child("root").child("header").child("title");
|
|
350
354
|
const char* text = title.child_value();
|
|
351
355
|
(void)text;
|
|
@@ -59,7 +59,8 @@ static void leptris_parse_fresh(void* ctx) {
|
|
|
59
59
|
static void pugixml_parse_fresh(void* ctx) {
|
|
60
60
|
leptris_ctx_t* c = (leptris_ctx_t*)ctx;
|
|
61
61
|
pugi::xml_document doc;
|
|
62
|
-
doc.load_buffer(c->xml, c->len
|
|
62
|
+
doc.load_buffer(c->xml, c->len,
|
|
63
|
+
pugi::parse_default | pugi::parse_ws_pcdata);
|
|
63
64
|
pugi::xml_node root = doc.root().first_child();
|
|
64
65
|
for (int i = 0; i < 10; i++) {
|
|
65
66
|
pugi::xml_node child = root.append_child("child");
|
|
@@ -232,7 +233,8 @@ static void leptris_write_parsed(void* ctx) {
|
|
|
232
233
|
static void pugixml_write_parsed(void* ctx) {
|
|
233
234
|
write_parsed_ctx_t* w = (write_parsed_ctx_t*)ctx;
|
|
234
235
|
pugi::xml_document doc;
|
|
235
|
-
doc.load_buffer(w->xml, w->len
|
|
236
|
+
doc.load_buffer(w->xml, w->len,
|
|
237
|
+
pugi::parse_default | pugi::parse_ws_pcdata);
|
|
236
238
|
pugi::xml_node root = doc.first_child();
|
|
237
239
|
char value[32];
|
|
238
240
|
for (int i = 0; i < w->n_writes; i++) {
|
|
@@ -53,7 +53,8 @@ static void bench_leptris_parse(const char* xml, size_t len) {
|
|
|
53
53
|
|
|
54
54
|
static void bench_pugixml_parse(const char* xml, size_t len) {
|
|
55
55
|
pugi::xml_document doc;
|
|
56
|
-
doc.load_buffer(xml, len
|
|
56
|
+
doc.load_buffer(xml, len,
|
|
57
|
+
pugi::parse_default | pugi::parse_ws_pcdata);
|
|
57
58
|
}
|
|
58
59
|
|
|
59
60
|
// ============================================================================
|
|
@@ -93,7 +94,8 @@ static void bench_leptris_child_access(const char* xml, size_t len) {
|
|
|
93
94
|
static void bench_pugixml_child_access(const char* xml, size_t len) {
|
|
94
95
|
// Parse ONCE
|
|
95
96
|
pugi::xml_document doc;
|
|
96
|
-
doc.load_buffer(xml, len
|
|
97
|
+
doc.load_buffer(xml, len,
|
|
98
|
+
pugi::parse_default | pugi::parse_ws_pcdata);
|
|
97
99
|
pugi::xml_node root = doc.root().first_child();
|
|
98
100
|
|
|
99
101
|
// Warmup
|
|
@@ -153,7 +155,8 @@ static void bench_leptris_attribute_access(const char* xml, size_t len) {
|
|
|
153
155
|
|
|
154
156
|
static void bench_pugixml_attribute_access(const char* xml, size_t len) {
|
|
155
157
|
pugi::xml_document doc;
|
|
156
|
-
doc.load_buffer(xml, len
|
|
158
|
+
doc.load_buffer(xml, len,
|
|
159
|
+
pugi::parse_default | pugi::parse_ws_pcdata);
|
|
157
160
|
pugi::xml_node root = doc.root().first_child();
|
|
158
161
|
|
|
159
162
|
// Warmup
|
|
@@ -223,7 +226,8 @@ static int walk_pugixml(pugi::xml_node node) {
|
|
|
223
226
|
|
|
224
227
|
static void bench_pugixml_tree_walk(const char* xml, size_t len) {
|
|
225
228
|
pugi::xml_document doc;
|
|
226
|
-
doc.load_buffer(xml, len
|
|
229
|
+
doc.load_buffer(xml, len,
|
|
230
|
+
pugi::parse_default | pugi::parse_ws_pcdata);
|
|
227
231
|
pugi::xml_node root = doc.root().first_child();
|
|
228
232
|
|
|
229
233
|
// Warmup
|