Skip to content

Commit

Permalink
Fix instance locations framing calculations (#1537)
Browse files Browse the repository at this point in the history
Signed-off-by: Juan Cruz Viotti <[email protected]>
  • Loading branch information
jviotti authored Feb 8, 2025
1 parent fda03b1 commit a33e514
Show file tree
Hide file tree
Showing 2 changed files with 36 additions and 15 deletions.
18 changes: 7 additions & 11 deletions src/core/jsonschema/frame.cc
Original file line number Diff line number Diff line change
Expand Up @@ -258,19 +258,17 @@ struct InternalEntry {
static auto traverse_instance_locations(
const sourcemeta::core::SchemaFrame::Locations &frame,
const sourcemeta::core::SchemaFrame::LocationsEntry &entry,
sourcemeta::core::PointerTemplate &&current,
std::vector<sourcemeta::core::PointerTemplate> &output,
const bool left = true) -> void {
const std::optional<sourcemeta::core::PointerTemplate> &current,
std::vector<sourcemeta::core::PointerTemplate> &output) -> void {
// We only care about subschemas
if (entry.type != sourcemeta::core::SchemaFrame::LocationType::Resource &&
entry.type != sourcemeta::core::SchemaFrame::LocationType::Subschema) {
return;
}

if (entry.destination_of.empty() && !left &&
std::find(output.cbegin(), output.cend(), current) == output.cend()) {
output.push_back(std::move(current));
return;
if (current.has_value() && std::find(output.cbegin(), output.cend(),
current.value()) == output.cend()) {
output.push_back(current.value());
}

for (const auto &origin : entry.destination_of) {
Expand All @@ -281,9 +279,7 @@ static auto traverse_instance_locations(
}

for (const auto &instance_location : subentry.instance_locations) {
traverse_instance_locations(frame, subentry,
instance_location.concat(std::move(current)),
output, false);
traverse_instance_locations(frame, subentry, instance_location, output);
}
}
}
Expand Down Expand Up @@ -787,7 +783,7 @@ auto internal_analyse(const sourcemeta::core::JSON &schema,

// Calculate alternative unresolved instance locations
for (auto &entry : frame) {
traverse_instance_locations(frame, entry.second, {},
traverse_instance_locations(frame, entry.second, std::nullopt,
entry.second.instance_locations);
}
}
Expand Down
33 changes: 29 additions & 4 deletions test/jsonschema/jsonschema_frame_2020_12_test.cc
Original file line number Diff line number Diff line change
Expand Up @@ -1787,6 +1787,11 @@ TEST(JSONSchema_frame_2020_12, properties_with_refs) {
},
"bar": {
"$ref": "#/properties/foo"
},
"baz": {
"items": {
"$ref": "#/properties/bar"
}
}
}
})JSON");
Expand All @@ -1795,7 +1800,7 @@ TEST(JSONSchema_frame_2020_12, properties_with_refs) {
frame.analyse(document, sourcemeta::core::schema_official_walker,
sourcemeta::core::schema_official_resolver);

EXPECT_EQ(frame.locations().size(), 8);
EXPECT_EQ(frame.locations().size(), 11);

EXPECT_FRAME_STATIC_2020_12_RESOURCE(
frame, "https://www.sourcemeta.com/schema",
Expand All @@ -1821,23 +1826,39 @@ TEST(JSONSchema_frame_2020_12, properties_with_refs) {
frame, "https://www.sourcemeta.com/schema#/properties/foo",
"https://www.sourcemeta.com/schema", "/properties/foo",
"https://www.sourcemeta.com/schema", "/properties/foo",
POINTER_TEMPLATES("/foo", "/bar"), 1);
POINTER_TEMPLATES("/foo", "/bar", "/baz/~I~"), 1);
EXPECT_FRAME_STATIC_2020_12_POINTER(
frame, "https://www.sourcemeta.com/schema#/properties/foo/type",
"https://www.sourcemeta.com/schema", "/properties/foo/type",
"https://www.sourcemeta.com/schema", "/properties/foo/type", {}, 0);

EXPECT_FRAME_STATIC_2020_12_SUBSCHEMA(
frame, "https://www.sourcemeta.com/schema#/properties/bar",
"https://www.sourcemeta.com/schema", "/properties/bar",
"https://www.sourcemeta.com/schema", "/properties/bar", {"/bar"}, 0);
"https://www.sourcemeta.com/schema", "/properties/bar",
POINTER_TEMPLATES("/bar", "/baz/~I~"), 1);
EXPECT_FRAME_STATIC_2020_12_POINTER(
frame, "https://www.sourcemeta.com/schema#/properties/bar/$ref",
"https://www.sourcemeta.com/schema", "/properties/bar/$ref",
"https://www.sourcemeta.com/schema", "/properties/bar/$ref", {}, 0);

EXPECT_FRAME_STATIC_2020_12_SUBSCHEMA(
frame, "https://www.sourcemeta.com/schema#/properties/baz",
"https://www.sourcemeta.com/schema", "/properties/baz",
"https://www.sourcemeta.com/schema", "/properties/baz", {"/baz"}, 0);
EXPECT_FRAME_STATIC_2020_12_SUBSCHEMA(
frame, "https://www.sourcemeta.com/schema#/properties/baz/items",
"https://www.sourcemeta.com/schema", "/properties/baz/items",
"https://www.sourcemeta.com/schema", "/properties/baz/items",
{"/baz/~I~"}, 0);
EXPECT_FRAME_STATIC_2020_12_POINTER(
frame, "https://www.sourcemeta.com/schema#/properties/baz/items/$ref",
"https://www.sourcemeta.com/schema", "/properties/baz/items/$ref",
"https://www.sourcemeta.com/schema", "/properties/baz/items/$ref", {}, 0);

// References

EXPECT_EQ(frame.references().size(), 2);
EXPECT_EQ(frame.references().size(), 3);

EXPECT_STATIC_REFERENCE(
frame, "/$schema", "https://json-schema.org/draft/2020-12/schema",
Expand All @@ -1846,4 +1867,8 @@ TEST(JSONSchema_frame_2020_12, properties_with_refs) {
"https://www.sourcemeta.com/schema#/properties/foo",
"https://www.sourcemeta.com/schema",
"/properties/foo");
EXPECT_STATIC_REFERENCE(frame, "/properties/baz/items/$ref",
"https://www.sourcemeta.com/schema#/properties/bar",
"https://www.sourcemeta.com/schema",
"/properties/bar");
}

5 comments on commit a33e514

@github-actions
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Benchmark (linux/llvm)

Benchmark suite Current: a33e514 Previous: fda03b1 Ratio
Regex_Lower_S_Or_Upper_S_Asterisk 2.199477447110509 ns/iter 2.2336741487646257 ns/iter 0.98
Regex_Caret_Lower_S_Or_Upper_S_Asterisk_Dollar 2.193409980520937 ns/iter 2.1998278574521093 ns/iter 1.00
Regex_Period_Asterisk 2.2118093846717533 ns/iter 2.2030333650856577 ns/iter 1.00
Regex_Group_Period_Asterisk_Group 2.202666264922767 ns/iter 2.2006870220245505 ns/iter 1.00
Regex_Period_Plus 2.488546403220857 ns/iter 2.4932381471042055 ns/iter 1.00
Regex_Period 2.368688763778354 ns/iter 2.486912626682726 ns/iter 0.95
Regex_Caret_Period_Plus_Dollar 2.2568673555444843 ns/iter 2.4868855823286515 ns/iter 0.91
Regex_Caret_Group_Period_Plus_Group_Dollar 2.2502290939277354 ns/iter 2.4871614658758228 ns/iter 0.90
Regex_Caret_Period_Asterisk_Dollar 2.4870523053589313 ns/iter 3.4182787055000214 ns/iter 0.73
Regex_Caret_Group_Period_Asterisk_Group_Dollar 2.486463131466549 ns/iter 3.4206254740223927 ns/iter 0.73
Regex_Caret_X_Hyphen 13.054122826716226 ns/iter 13.056098282204163 ns/iter 1.00
Regex_Period_Md_Dollar 73.19295466819632 ns/iter 73.46712957188181 ns/iter 1.00
Regex_Caret_Slash_Period_Asterisk 6.218909714744673 ns/iter 7.156694735849628 ns/iter 0.87
Regex_Caret_Period_Range_Dollar 3.729052271561638 ns/iter 3.7316836168284913 ns/iter 1.00
Regex_Nested_Backtrack 496.0048145117899 ns/iter 485.2630255048362 ns/iter 1.02
JSON_Array_Of_Objects_Unique 403.414118845858 ns/iter 402.45412710769835 ns/iter 1.00
JSON_Parse_1 30350.94983133155 ns/iter 30407.57334313253 ns/iter 1.00
JSON_Fast_Hash_Helm_Chart_Lock 61.79176499057533 ns/iter 59.598606247993644 ns/iter 1.04
JSON_Equality_Helm_Chart_Lock 150.3266049148963 ns/iter 165.11003232527395 ns/iter 0.91
JSON_String_Equal/10 7.053403775058149 ns/iter 7.787664065285024 ns/iter 0.91
JSON_String_Equal/100 6.84958918973883 ns/iter 8.407204586793029 ns/iter 0.81
JSON_String_Equal_Small_By_Perfect_Hash/10 0.9404173824875727 ns/iter 0.9384289914300863 ns/iter 1.00
JSON_String_Equal_Small_By_Runtime_Perfect_Hash/10 14.706862561365595 ns/iter 14.640083799115693 ns/iter 1.00
JSON_String_Fast_Hash/10 2.193838899320927 ns/iter 2.175940174776645 ns/iter 1.01
JSON_String_Fast_Hash/100 2.1753933770975586 ns/iter 2.175741868528294 ns/iter 1.00
JSON_String_Key_Hash/10 2.704383781492049 ns/iter 2.6701311682197795 ns/iter 1.01
JSON_String_Key_Hash/100 2.1793860403954057 ns/iter 2.178798735946459 ns/iter 1.00
JSON_Object_Defines_Miss_Same_Length 3.7339395187332705 ns/iter 3.734540959201007 ns/iter 1.00
JSON_Object_Defines_Miss_Too_Small 3.7346075244758286 ns/iter 3.7334752803021507 ns/iter 1.00
JSON_Object_Defines_Miss_Too_Large 3.7379832380111813 ns/iter 3.7398870239541897 ns/iter 1.00
Pointer_Object_Traverse 44.42958104805373 ns/iter 44.43611001304772 ns/iter 1.00
Pointer_Object_Try_Traverse 52.322245052963375 ns/iter 52.37266170773179 ns/iter 1.00
Pointer_Push_Back_Pointer_To_Weak_Pointer 303.02891613645744 ns/iter 357.29744783983693 ns/iter 0.85
Schema_Frame_OMC_Full 228703040.9999981 ns/iter 232583570.33334205 ns/iter 0.98
Schema_Bundle_Meta_2020_12 10326601.283576287 ns/iter 10353314.661764845 ns/iter 1.00

This comment was automatically generated by workflow using github-action-benchmark.

@github-actions
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Benchmark (macos/llvm)

Benchmark suite Current: a33e514 Previous: fda03b1 Ratio
Regex_Lower_S_Or_Upper_S_Asterisk 1.7771014213115193 ns/iter 1.7137214696524412 ns/iter 1.04
Regex_Caret_Lower_S_Or_Upper_S_Asterisk_Dollar 2.285432056447565 ns/iter 1.740183745510081 ns/iter 1.31
Regex_Period_Asterisk 2.2083781389827384 ns/iter 1.8274557066684596 ns/iter 1.21
Regex_Group_Period_Asterisk_Group 2.2271864465206663 ns/iter 1.7018531408990956 ns/iter 1.31
Regex_Period_Plus 2.7484525180364905 ns/iter 2.0299604587211713 ns/iter 1.35
Regex_Period 2.6006081443616953 ns/iter 2.0467096858204434 ns/iter 1.27
Regex_Caret_Period_Plus_Dollar 2.344614732554976 ns/iter 2.0233620684731446 ns/iter 1.16
Regex_Caret_Group_Period_Plus_Group_Dollar 2.3592183150381016 ns/iter 2.2884759793187195 ns/iter 1.03
Regex_Caret_Period_Asterisk_Dollar 1.8072134947493812 ns/iter 1.7009053337551143 ns/iter 1.06
Regex_Caret_Group_Period_Asterisk_Group_Dollar 1.7514786431241807 ns/iter 1.6979726504083035 ns/iter 1.03
Regex_Caret_X_Hyphen 8.427351528155123 ns/iter 7.121488707866663 ns/iter 1.18
Regex_Period_Md_Dollar 79.19829582089561 ns/iter 73.11886334830353 ns/iter 1.08
Regex_Caret_Slash_Period_Asterisk 5.634147644437735 ns/iter 5.580149036592864 ns/iter 1.01
Regex_Caret_Period_Range_Dollar 2.6527386617465156 ns/iter 2.368089762335691 ns/iter 1.12
Regex_Nested_Backtrack 851.1676129952813 ns/iter 791.0111391841551 ns/iter 1.08
JSON_Array_Of_Objects_Unique 356.5978218515214 ns/iter 352.0678359507631 ns/iter 1.01
JSON_Parse_1 26328.926044267253 ns/iter 23371.222222222772 ns/iter 1.13
JSON_Fast_Hash_Helm_Chart_Lock 57.28246376940729 ns/iter 51.35871365720913 ns/iter 1.12
JSON_Equality_Helm_Chart_Lock 125.82693511145122 ns/iter 125.71266315040694 ns/iter 1.00
JSON_String_Equal/10 8.794689430787257 ns/iter 8.74230628030261 ns/iter 1.01
JSON_String_Equal/100 6.482213409949045 ns/iter 6.480534694471614 ns/iter 1.00
JSON_String_Equal_Small_By_Perfect_Hash/10 0.3633727151937147 ns/iter 0.33817903637576774 ns/iter 1.07
JSON_String_Equal_Small_By_Runtime_Perfect_Hash/10 4.195336563901842 ns/iter 3.203461165353918 ns/iter 1.31
JSON_String_Fast_Hash/10 1.8958521541728328 ns/iter 1.7214694705522184 ns/iter 1.10
JSON_String_Fast_Hash/100 2.3119832050976004 ns/iter 2.0667852455348115 ns/iter 1.12
JSON_String_Key_Hash/10 1.4349934488048597 ns/iter 1.3492895708258672 ns/iter 1.06
JSON_String_Key_Hash/100 1.4492705723771309 ns/iter 1.35164620721881 ns/iter 1.07
JSON_Object_Defines_Miss_Same_Length 2.385452643472702 ns/iter 2.357502254807884 ns/iter 1.01
JSON_Object_Defines_Miss_Too_Small 2.712397937542276 ns/iter 2.3636122978048575 ns/iter 1.15
JSON_Object_Defines_Miss_Too_Large 2.423431595407739 ns/iter 2.412681881764084 ns/iter 1.00
Pointer_Object_Traverse 18.611608460219006 ns/iter 19.70547256100379 ns/iter 0.94
Pointer_Object_Try_Traverse 26.09043065125342 ns/iter 26.587518635235295 ns/iter 0.98
Pointer_Push_Back_Pointer_To_Weak_Pointer 198.50049811813076 ns/iter 203.81207581209424 ns/iter 0.97
Schema_Frame_OMC_Full 193039874.99998242 ns/iter 178876072.99999785 ns/iter 1.08
Schema_Bundle_Meta_2020_12 8581606.09302532 ns/iter 7944661.533329307 ns/iter 1.08

This comment was automatically generated by workflow using github-action-benchmark.

@github-actions
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Benchmark (windows/msvc)

Benchmark suite Current: a33e514 Previous: fda03b1 Ratio
Regex_Lower_S_Or_Upper_S_Asterisk 6.677368303569559 ns/iter 6.690396205356766 ns/iter 1.00
Regex_Caret_Lower_S_Or_Upper_S_Asterisk_Dollar 6.776823660713051 ns/iter 6.799989955358195 ns/iter 1.00
Regex_Period_Asterisk 6.525842857143971 ns/iter 6.598251116070993 ns/iter 0.99
Regex_Group_Period_Asterisk_Group 6.962426339285343 ns/iter 6.857341964285573 ns/iter 1.02
Regex_Period_Plus 6.961770089287508 ns/iter 6.985137276784213 ns/iter 1.00
Regex_Period 7.046362499999808 ns/iter 7.277477678570168 ns/iter 0.97
Regex_Caret_Period_Plus_Dollar 6.961337499999688 ns/iter 7.054868303570621 ns/iter 0.99
Regex_Caret_Group_Period_Plus_Group_Dollar 7.239315848214086 ns/iter 6.900253094195784 ns/iter 1.05
Regex_Caret_Period_Asterisk_Dollar 6.644004464284591 ns/iter 6.682283035715386 ns/iter 0.99
Regex_Caret_Group_Period_Asterisk_Group_Dollar 6.541016964285566 ns/iter 6.883854910714352 ns/iter 0.95
Regex_Caret_X_Hyphen 11.848114285714116 ns/iter 14.45242857142505 ns/iter 0.82
Regex_Period_Md_Dollar 142.56019452855065 ns/iter 146.97696442065094 ns/iter 0.97
Regex_Caret_Slash_Period_Asterisk 9.979335937501332 ns/iter 10.21878437499879 ns/iter 0.98
Regex_Caret_Period_Range_Dollar 7.420222098214627 ns/iter 7.459709821426535 ns/iter 0.99
Regex_Nested_Backtrack 588.101160714213 ns/iter 591.9013000000177 ns/iter 0.99
JSON_Array_Of_Objects_Unique 413.8001360847846 ns/iter 420.4773938246067 ns/iter 0.98
JSON_Parse_1 80580.31249998773 ns/iter 97270.81826704559 ns/iter 0.83
JSON_Fast_Hash_Helm_Chart_Lock 57.53515178570622 ns/iter 54.291970000008405 ns/iter 1.06
JSON_Equality_Helm_Chart_Lock 189.30398118780775 ns/iter 188.9828472306345 ns/iter 1.00
JSON_String_Equal/10 9.364003083194794 ns/iter 9.451536118520519 ns/iter 0.99
JSON_String_Equal/100 9.928311116391775 ns/iter 10.316693749999217 ns/iter 0.96
JSON_String_Equal_Small_By_Perfect_Hash/10 2.1740881249996846 ns/iter 2.170701874999992 ns/iter 1.00
JSON_String_Equal_Small_By_Runtime_Perfect_Hash/10 14.614537946425596 ns/iter 14.393411510753863 ns/iter 1.02
JSON_String_Fast_Hash/10 3.098911160713718 ns/iter 3.1038580357147794 ns/iter 1.00
JSON_String_Fast_Hash/100 3.0980446428573924 ns/iter 3.1043620535718173 ns/iter 1.00
JSON_String_Key_Hash/10 7.9724296875000835 ns/iter 7.5131964285723996 ns/iter 1.06
JSON_String_Key_Hash/100 3.7151582076516467 ns/iter 3.7421673147462333 ns/iter 0.99
JSON_Object_Defines_Miss_Same_Length 4.02909000719523 ns/iter 4.064358815150397 ns/iter 0.99
JSON_Object_Defines_Miss_Too_Small 3.413533130333902 ns/iter 3.415517672471738 ns/iter 1.00
JSON_Object_Defines_Miss_Too_Large 3.716965820084807 ns/iter 3.766335528988553 ns/iter 0.99
Pointer_Object_Traverse 52.77635714285063 ns/iter 52.48794999999973 ns/iter 1.01
Pointer_Object_Try_Traverse 64.52571428569951 ns/iter 65.40291964286992 ns/iter 0.99
Pointer_Push_Back_Pointer_To_Weak_Pointer 184.37926646242053 ns/iter 162.11872290973392 ns/iter 1.14
Schema_Frame_OMC_Full 473985650.0000315 ns/iter 473063700.0000115 ns/iter 1.00
Schema_Bundle_Meta_2020_12 23522313.33331929 ns/iter 23273949.999997966 ns/iter 1.01

This comment was automatically generated by workflow using github-action-benchmark.

@github-actions
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Benchmark (linux/gcc)

Benchmark suite Current: a33e514 Previous: fda03b1 Ratio
Schema_Frame_OMC_Full 229638939.6666806 ns/iter 236797640.3333311 ns/iter 0.97
Schema_Bundle_Meta_2020_12 10553003.621224076 ns/iter 10586084.803023685 ns/iter 1.00
Pointer_Object_Traverse 46.98024021964946 ns/iter 46.81200242408507 ns/iter 1.00
Pointer_Object_Try_Traverse 22.983863531629883 ns/iter 22.97158781708668 ns/iter 1.00
Pointer_Push_Back_Pointer_To_Weak_Pointer 174.07297113478097 ns/iter 175.49131103956395 ns/iter 0.99
JSON_Array_Of_Objects_Unique 403.8238098174628 ns/iter 396.11499510424005 ns/iter 1.02
JSON_Parse_1 33264.51917152465 ns/iter 34568.253961457485 ns/iter 0.96
JSON_Fast_Hash_Helm_Chart_Lock 68.98810395470427 ns/iter 63.08419691361196 ns/iter 1.09
JSON_Equality_Helm_Chart_Lock 142.8634296835539 ns/iter 152.0929075735853 ns/iter 0.94
JSON_String_Equal/10 5.991362253503112 ns/iter 5.95740197832579 ns/iter 1.01
JSON_String_Equal/100 6.612846474554077 ns/iter 6.60326600057428 ns/iter 1.00
JSON_String_Equal_Small_By_Perfect_Hash/10 0.973588410217398 ns/iter 0.6236909884266193 ns/iter 1.56
JSON_String_Equal_Small_By_Runtime_Perfect_Hash/10 11.772402822512122 ns/iter 11.678899622542186 ns/iter 1.01
JSON_String_Fast_Hash/10 0.9329932441075371 ns/iter 0.9413067412028505 ns/iter 0.99
JSON_String_Fast_Hash/100 0.9344089652390237 ns/iter 0.9330292259327174 ns/iter 1.00
JSON_String_Key_Hash/10 1.244825350917254 ns/iter 1.2798826596108541 ns/iter 0.97
JSON_String_Key_Hash/100 0.9367759545836406 ns/iter 0.9338053372460723 ns/iter 1.00
JSON_Object_Defines_Miss_Same_Length 2.503534156667099 ns/iter 2.488661350250763 ns/iter 1.01
JSON_Object_Defines_Miss_Too_Small 2.4867709763852375 ns/iter 2.501112228666333 ns/iter 0.99
JSON_Object_Defines_Miss_Too_Large 2.508729630355586 ns/iter 2.7972271675506932 ns/iter 0.90
Regex_Lower_S_Or_Upper_S_Asterisk 3.425454392350101 ns/iter 3.4260464462651723 ns/iter 1.00
Regex_Caret_Lower_S_Or_Upper_S_Asterisk_Dollar 3.4261502691248285 ns/iter 3.4220049367608136 ns/iter 1.00
Regex_Period_Asterisk 3.4239162200882887 ns/iter 3.4228110389579234 ns/iter 1.00
Regex_Group_Period_Asterisk_Group 3.4244132712925097 ns/iter 3.4258876544149124 ns/iter 1.00
Regex_Period_Plus 3.7380862945280824 ns/iter 3.740245466141779 ns/iter 1.00
Regex_Period 3.7355903461167554 ns/iter 3.734240957090219 ns/iter 1.00
Regex_Caret_Period_Plus_Dollar 3.731154045133004 ns/iter 3.735879220551134 ns/iter 1.00
Regex_Caret_Group_Period_Plus_Group_Dollar 3.72977400436281 ns/iter 3.729458822337646 ns/iter 1.00
Regex_Caret_Period_Asterisk_Dollar 4.697403204975513 ns/iter 4.66305252035665 ns/iter 1.01
Regex_Caret_Group_Period_Asterisk_Group_Dollar 4.281328386369071 ns/iter 4.663468017888071 ns/iter 0.92
Regex_Caret_X_Hyphen 13.683040437588355 ns/iter 13.685841694399066 ns/iter 1.00
Regex_Period_Md_Dollar 89.623667873938 ns/iter 89.27482095114195 ns/iter 1.00
Regex_Caret_Slash_Period_Asterisk 8.403672761121067 ns/iter 9.659672161367928 ns/iter 0.87
Regex_Caret_Period_Range_Dollar 3.7307341160997143 ns/iter 4.662041599379986 ns/iter 0.80
Regex_Nested_Backtrack 819.093706440628 ns/iter 824.0128051375157 ns/iter 0.99

This comment was automatically generated by workflow using github-action-benchmark.

@github-actions
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Benchmark (macos/gcc)

Benchmark suite Current: a33e514 Previous: fda03b1 Ratio
Regex_Lower_S_Or_Upper_S_Asterisk 1.8982915359433419 ns/iter 1.8819393735658194 ns/iter 1.01
Regex_Caret_Lower_S_Or_Upper_S_Asterisk_Dollar 1.934593624582003 ns/iter 1.8865815551340634 ns/iter 1.03
Regex_Period_Asterisk 2.008895790042319 ns/iter 1.8815880617887382 ns/iter 1.07
Regex_Group_Period_Asterisk_Group 2.024797097800918 ns/iter 1.8815222917460157 ns/iter 1.08
Regex_Period_Plus 1.692533908222527 ns/iter 1.568298186804448 ns/iter 1.08
Regex_Period 1.6851444467469088 ns/iter 1.5674850176895074 ns/iter 1.08
Regex_Caret_Period_Plus_Dollar 1.6865511066851457 ns/iter 1.567882934604193 ns/iter 1.08
Regex_Caret_Group_Period_Plus_Group_Dollar 1.5777480559822712 ns/iter 1.5701730750578107 ns/iter 1.00
Regex_Caret_Period_Asterisk_Dollar 1.8860097239774885 ns/iter 1.8951602922147244 ns/iter 1.00
Regex_Caret_Group_Period_Asterisk_Group_Dollar 1.8891087124710917 ns/iter 1.8839616515132878 ns/iter 1.00
Regex_Caret_X_Hyphen 5.973620713159586 ns/iter 5.961069647159391 ns/iter 1.00
Regex_Period_Md_Dollar 69.50343687672377 ns/iter 71.47107863668744 ns/iter 0.97
Regex_Caret_Slash_Period_Asterisk 4.392749707466728 ns/iter 4.396877786369835 ns/iter 1.00
Regex_Caret_Period_Range_Dollar 1.8949233242314547 ns/iter 1.8809101826593893 ns/iter 1.01
Regex_Nested_Backtrack 849.7375339839182 ns/iter 847.1087546916384 ns/iter 1.00
JSON_Array_Of_Objects_Unique 214.33681587908143 ns/iter 200.49322175626634 ns/iter 1.07
JSON_Parse_1 23345.33199187248 ns/iter 23107.85438039079 ns/iter 1.01
JSON_Fast_Hash_Helm_Chart_Lock 23.455478822940048 ns/iter 23.423087280009902 ns/iter 1.00
JSON_Equality_Helm_Chart_Lock 113.80121947664394 ns/iter 113.91210945414859 ns/iter 1.00
JSON_String_Equal/10 5.58180361028161 ns/iter 5.372109582476497 ns/iter 1.04
JSON_String_Equal/100 5.103697066392692 ns/iter 5.087144367338979 ns/iter 1.00
JSON_String_Equal_Small_By_Perfect_Hash/10 0.7491807030197054 ns/iter 0.7464216457152769 ns/iter 1.00
JSON_String_Equal_Small_By_Runtime_Perfect_Hash/10 3.4545674161955597 ns/iter 3.450758477807526 ns/iter 1.00
JSON_String_Fast_Hash/10 1.8919453090360518 ns/iter 1.8921518330145015 ns/iter 1.00
JSON_String_Fast_Hash/100 1.8916381099130353 ns/iter 1.9019557366011353 ns/iter 0.99
JSON_String_Key_Hash/10 1.43201025390625 ns/iter 1.4330597408007124 ns/iter 1.00
JSON_String_Key_Hash/100 1.9181218425543323 ns/iter 1.9238142491309502 ns/iter 1.00
JSON_Object_Defines_Miss_Same_Length 1.7331064182754707 ns/iter 1.7309543696857883 ns/iter 1.00
JSON_Object_Defines_Miss_Too_Small 1.8905975204249226 ns/iter 1.8837757507252442 ns/iter 1.00
JSON_Object_Defines_Miss_Too_Large 1.7244660381686439 ns/iter 1.7252176388473617 ns/iter 1.00
Pointer_Object_Traverse 51.99264167081417 ns/iter 53.68908335450118 ns/iter 0.97
Pointer_Object_Try_Traverse 36.27883191611546 ns/iter 35.96947147862546 ns/iter 1.01
Pointer_Push_Back_Pointer_To_Weak_Pointer 155.82141704603052 ns/iter 156.05208907179644 ns/iter 1.00
Schema_Frame_OMC_Full 181380331.51626587 ns/iter 184282779.69360352 ns/iter 0.98
Schema_Bundle_Meta_2020_12 8445647.825677712 ns/iter 9211242.934803903 ns/iter 0.92

This comment was automatically generated by workflow using github-action-benchmark.

Please sign in to comment.