Skip to content

Implement a is_canonical_langtag helper - #2641

Merged
jviotti merged 1 commit into
mainfrom
canonical-langtag
Jul 20, 2026
Merged

Implement a is_canonical_langtag helper#2641
jviotti merged 1 commit into
mainfrom
canonical-langtag

Conversation

@jviotti

@jviotti jviotti commented Jul 20, 2026

Copy link
Copy Markdown
Member

Signed-off-by: Juan Cruz Viotti jv@jviotti.com

Review in cubic

Signed-off-by: Juan Cruz Viotti <jv@jviotti.com>
@augmentcode

augmentcode Bot commented Jul 20, 2026

Copy link
Copy Markdown
🤖 Augment PR Summary

Summary: This PR adds a new helper to validate whether a BCP 47 language tag is not only well‑formed, but also uses RFC 5646’s recommended canonical casing.

Changes:

  • Exposes is_canonical_langtag(std::string_view) in sourcemeta/core/langtag.h.
  • Implements canonical-casing checks in src/core/langtag/langtag.cc by first validating with is_langtag, rejecting irregular grandfathered tags, then enforcing casing per-subtag (script=Titlecase, region=UPPERCASE, others=lowercase).
  • Adds a comprehensive set of unit tests covering canonical vs non-canonical casing across language, script, region (including numeric), extlang, variants, extensions, private-use, and grandfathered tags.

Technical Notes: The implementation is allocation-free and reuses existing subtag scanning helpers (subtag_at/advance) to walk the tag and enforce RFC 5646 §2.1.1 casing conventions.

🤖 Was this summary useful? React with 👍 or 👎

@augmentcode augmentcode Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Review completed. No suggestions at this time.

Comment augment review to trigger a new review at any time.

@cubic-dev-ai cubic-dev-ai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

No issues found across 3 files

Re-trigger cubic

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Benchmark (macos/llvm)

Details
Benchmark suite Current: a1e0b0d Previous: 1c2c0f1 Ratio
Regex_Lower_S_Or_Upper_S_Asterisk 2.130439649082648 ns/iter 2.35786216258816 ns/iter 0.90
Regex_Caret_Lower_S_Or_Upper_S_Asterisk_Dollar 2.239951338522933 ns/iter 2.380802401549196 ns/iter 0.94
Regex_Period_Asterisk 2.0429237323001894 ns/iter 2.5623889324653404 ns/iter 0.80
Regex_Group_Period_Asterisk_Group 2.6586288717867768 ns/iter 2.287949390975727 ns/iter 1.16
Regex_Period_Plus 2.5504031569551153 ns/iter 2.9767584122790103 ns/iter 0.86
Regex_Period 2.7514350084014256 ns/iter 2.9492865154053725 ns/iter 0.93
Regex_Caret_Period_Plus_Dollar 2.8458654470051474 ns/iter 3.125407791549456 ns/iter 0.91
Regex_Caret_Group_Period_Plus_Group_Dollar 2.5063518165766827 ns/iter 2.7943063627860862 ns/iter 0.90
Regex_Caret_Period_Asterisk_Dollar 2.495587555833908 ns/iter 2.2229963739549623 ns/iter 1.12
Regex_Caret_Group_Period_Asterisk_Group_Dollar 2.1046648721003494 ns/iter 2.368084974986094 ns/iter 0.89
Regex_Caret_X_Hyphen 7.123381159079949 ns/iter 8.465211666878732 ns/iter 0.84
Regex_Period_Md_Dollar 28.613015924929762 ns/iter 25.03163698689652 ns/iter 1.14
Regex_Caret_Slash_Period_Asterisk 6.7670390657610655 ns/iter 7.736421027783621 ns/iter 0.87
Regex_Caret_Period_Range_Dollar 3.7627111685649446 ns/iter 2.8544417189161932 ns/iter 1.32
Regex_Nested_Backtrack 40.79154596151945 ns/iter 43.31923051626222 ns/iter 0.94
JSON_Array_Of_Objects_Unique 574.1979169999922 ns/iter 503.14938032433116 ns/iter 1.14
JSON_Parse_1 13615.05482284851 ns/iter 8474.079394140383 ns/iter 1.61
JSON_Parse_Real 13392.536652143113 ns/iter 8075.44508490696 ns/iter 1.66
JSON_Parse_Decimal 11872.91312750801 ns/iter 11904.746590068773 ns/iter 1.00
JSON_Parse_Schema_ISO_Language 7117954.633333232 ns/iter 4865768.420289817 ns/iter 1.46
JSON_Parse_Integer 9890.677689364831 ns/iter 5916.813329999968 ns/iter 1.67
JSON_Parse_String_NonSSO_Plain 9749.430422761303 ns/iter 10081.106695291932 ns/iter 0.97
JSON_Parse_String_SSO_Plain 3694.3600550751235 ns/iter 3417.7888495892707 ns/iter 1.08
JSON_Parse_String_Escape_Heavy 25414.485884046055 ns/iter 29281.971398889786 ns/iter 0.87
JSON_Parse_Object_Short_Keys 11595.752090831471 ns/iter 9604.44980393724 ns/iter 1.21
JSON_Parse_Object_Scalar_Properties 6323.745319183106 ns/iter 5985.35189452567 ns/iter 1.06
JSON_Parse_Object_Array_Properties 9771.183804346305 ns/iter 9243.84326125066 ns/iter 1.06
JSON_Parse_Object_Object_Properties 10234.98375124576 ns/iter 9741.878308713645 ns/iter 1.05
JSON_Parse_Nested_Containers 80702.17325227965 ns/iter 74194.02343440037 ns/iter 1.09
JSON_From_String_Copy 35.98609197630877 ns/iter 34.73485491949724 ns/iter 1.04
JSON_From_String_Temporary 29.128771429733103 ns/iter 24.47701006045776 ns/iter 1.19
JSON_Number_To_Double 53.09495779068388 ns/iter 41.02713101256642 ns/iter 1.29
JSON_Object_At_Last_Key/8 5.638328869467966 ns/iter 5.076207281007111 ns/iter 1.11
JSON_Object_At_Last_Key/32 17.485853502181048 ns/iter 15.01960377569276 ns/iter 1.16
JSON_Object_At_Last_Key/128 76.82027392571864 ns/iter 66.49863890732249 ns/iter 1.16
JSON_Object_At_Last_Key/512 287.0488594934173 ns/iter 291.350042026764 ns/iter 0.99
JSON_Fast_Hash_Helm_Chart_Lock 84.42642213362667 ns/iter 79.97959001121164 ns/iter 1.06
JSON_Equality_Helm_Chart_Lock 255.55283619665036 ns/iter 193.6862760568845 ns/iter 1.32
JSON_Divisible_By_Decimal 266.2150965930078 ns/iter 226.10229872251983 ns/iter 1.18
JSON_String_Equal/10 11.102971915166995 ns/iter 8.064574001987426 ns/iter 1.38
JSON_String_Equal/100 10.034078853178134 ns/iter 8.416080805944489 ns/iter 1.19
JSON_String_Equal_Small_By_Perfect_Hash/10 0.39223450376902125 ns/iter 0.38781508681969007 ns/iter 1.01
JSON_String_Equal_Small_By_Runtime_Perfect_Hash/10 4.84636208835658 ns/iter 4.458957924530574 ns/iter 1.09
JSON_String_Fast_Hash/10 3.117819298832545 ns/iter 2.742852434952748 ns/iter 1.14
JSON_String_Fast_Hash/100 2.561579071306085 ns/iter 2.746911020828241 ns/iter 0.93
JSON_String_Key_Hash/10 2.0998096711796235 ns/iter 2.2517110179549458 ns/iter 0.93
JSON_String_Key_Hash/100 2.950558218178622 ns/iter 3.1091970895168637 ns/iter 0.95
JSON_Object_Defines_Miss_Same_Length 3.270834677070076 ns/iter 3.4584777949405545 ns/iter 0.95
JSON_Object_Defines_Miss_Too_Small 3.4775891390001186 ns/iter 3.273996419190332 ns/iter 1.06
JSON_Object_Defines_Miss_Too_Large 3.606526366339481 ns/iter 3.5176294896677756 ns/iter 1.03
Pointer_Object_Traverse 31.92857765929937 ns/iter 28.51931219917467 ns/iter 1.12
Pointer_Object_Try_Traverse 33.17871950268105 ns/iter 30.122347365825632 ns/iter 1.10
Pointer_Push_Back_Pointer_To_Weak_Pointer 239.96718090600052 ns/iter 216.436855507281 ns/iter 1.11
Pointer_Walker_Schema_ISO_Language 4583326.19889549 ns/iter 3540999.8019321687 ns/iter 1.29
Pointer_Maybe_Tracked_Deeply_Nested/0 1621915.6050954363 ns/iter 1700413.4481236967 ns/iter 0.95
Pointer_Maybe_Tracked_Deeply_Nested/1 1450525.2287970262 ns/iter 1363604.1666667087 ns/iter 1.06
Pointer_Position_Tracker_Get_Deeply_Nested 472.8298642056048 ns/iter 488.4530912303491 ns/iter 0.97
JSONPath_Descendant_Filter_Nested 1689.3190970256383 ns/iter 1524.4429176817114 ns/iter 1.11
URITemplateRouter_Create 30581.343901826447 ns/iter 29816.045481825964 ns/iter 1.03
URITemplateRouter_Match 226.3769261641787 ns/iter 185.4536036733332 ns/iter 1.22
URITemplateRouter_Match_BasePath 266.7710991061934 ns/iter 242.37487999360138 ns/iter 1.10
URITemplateRouterView_Restore 18541.89465746189 ns/iter 16102.299957996674 ns/iter 1.15
URITemplateRouterView_Match 176.58927477901997 ns/iter 179.4219763467766 ns/iter 0.98
URITemplateRouterView_Match_BasePath 191.88673846900804 ns/iter 201.07175570313083 ns/iter 0.95
URITemplateRouterView_Arguments 657.4859544796674 ns/iter 671.1885321532578 ns/iter 0.98
JSONL_Parse_Large 15259999.06666584 ns/iter 15677150.186048111 ns/iter 0.97
JSONL_Parse_Large_GZIP 16706228.124999711 ns/iter 14115609.119046656 ns/iter 1.18
JSONLD_Catalog_Annotation_List_Populate 1316195.348591595 ns/iter 1331750.7987219945 ns/iter 0.99
JSONLD_Catalog_Materialize 7247152.472527037 ns/iter 7352088.271186288 ns/iter 0.99
HTML_Build_Table_100000 54292904.10000931 ns/iter 53434236.08332879 ns/iter 1.02
HTML_Render_Table_100000 2750530.946058427 ns/iter 2382350.9534048913 ns/iter 1.15
GZIP_Compress_ISO_Language_Set_3_Locations 36839285.39999784 ns/iter 38686877.15789507 ns/iter 0.95
GZIP_Decompress_ISO_Language_Set_3_Locations 3833696.283132361 ns/iter 5168816.485293933 ns/iter 0.74
GZIP_Compress_ISO_Language_Set_3_Schema 1871667.753623141 ns/iter 1944445.0567821595 ns/iter 0.96
GZIP_Decompress_ISO_Language_Set_3_Schema 342379.69897484645 ns/iter 343775.4490603259 ns/iter 1.00
JOSE_VerifySignature_RS256 33293.33829454163 ns/iter 30270.296989132174 ns/iter 1.10
JOSE_VerifySignature_ES512 1440579.213483054 ns/iter 1434660.9195401394 ns/iter 1.00

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

@jviotti
jviotti merged commit 8c9b7bc into main Jul 20, 2026
12 checks passed
@jviotti
jviotti deleted the canonical-langtag branch July 20, 2026 22:41

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Benchmark (linux/gcc)

Details
Benchmark suite Current: a1e0b0d Previous: 1c2c0f1 Ratio
JOSE_VerifySignature_RS256 22403.228402558547 ns/iter 16120.523798488757 ns/iter 1.39
JOSE_VerifySignature_ES512 576197.2767710503 ns/iter 359800.8835300067 ns/iter 1.60
GZIP_Compress_ISO_Language_Set_3_Locations 36268653.26315822 ns/iter 24541034.65625046 ns/iter 1.48
GZIP_Decompress_ISO_Language_Set_3_Locations 4123555.064705563 ns/iter 3128974.3497755695 ns/iter 1.32
GZIP_Compress_ISO_Language_Set_3_Schema 2023682.0028900432 ns/iter 1544296.768722483 ns/iter 1.31
GZIP_Decompress_ISO_Language_Set_3_Schema 379504.39544963604 ns/iter 269361.84407058766 ns/iter 1.41
HTML_Build_Table_100000 68608601.39998977 ns/iter 36776507.263159364 ns/iter 1.87
HTML_Render_Table_100000 1798907.284237794 ns/iter 2843622.424489806 ns/iter 0.63
JSONLD_Catalog_Annotation_List_Populate 1296444.3147114606 ns/iter 863284.3366093771 ns/iter 1.50
JSONLD_Catalog_Materialize 6954039.475728183 ns/iter 4565509.116882926 ns/iter 1.52
JSONL_Parse_Large 13934227.52000106 ns/iter 8307303.595237786 ns/iter 1.68
JSONL_Parse_Large_GZIP 15355542.239131844 ns/iter 9316791.92000047 ns/iter 1.65
URITemplateRouter_Create 30955.966807143122 ns/iter 19099.202060113617 ns/iter 1.62
URITemplateRouter_Match 155.323409027943 ns/iter 110.42960582853183 ns/iter 1.41
URITemplateRouter_Match_BasePath 180.69984392976286 ns/iter 118.87075168501141 ns/iter 1.52
URITemplateRouterView_Restore 8448.919147056527 ns/iter 2400.577427148385 ns/iter 3.52
URITemplateRouterView_Match 124.58809224063458 ns/iter 80.97125255900579 ns/iter 1.54
URITemplateRouterView_Match_BasePath 143.29516224204582 ns/iter 92.11817570188096 ns/iter 1.56
URITemplateRouterView_Arguments 480.0219144305147 ns/iter 367.9664956277469 ns/iter 1.30
JSONPath_Descendant_Filter_Nested 1665.2142540503055 ns/iter 1011.2357365224242 ns/iter 1.65
Pointer_Object_Traverse 30.044157183508194 ns/iter 21.172521619784064 ns/iter 1.42
Pointer_Object_Try_Traverse 25.348526132607407 ns/iter 19.772334121494904 ns/iter 1.28
Pointer_Push_Back_Pointer_To_Weak_Pointer 159.25326322601728 ns/iter 109.01614559852608 ns/iter 1.46
Pointer_Walker_Schema_ISO_Language 2783767.130434894 ns/iter 1760580.5454545352 ns/iter 1.58
Pointer_Maybe_Tracked_Deeply_Nested/0 1837430.0808625415 ns/iter 1422809.404471613 ns/iter 1.29
Pointer_Maybe_Tracked_Deeply_Nested/1 1701117.5951808244 ns/iter 1223318.1940559575 ns/iter 1.39
Pointer_Position_Tracker_Get_Deeply_Nested 486.89008760962776 ns/iter 339.4474242098625 ns/iter 1.43
JSON_Array_Of_Objects_Unique 424.35093427477807 ns/iter 235.29171339920322 ns/iter 1.80
JSON_Parse_1 10037.44454934329 ns/iter 6118.635974829568 ns/iter 1.64
JSON_Parse_Real 8109.316514080613 ns/iter 4705.714218664015 ns/iter 1.72
JSON_Parse_Decimal 12894.266349956995 ns/iter 7930.2076581112115 ns/iter 1.63
JSON_Parse_Schema_ISO_Language 6711891.98076897 ns/iter 4793607.965753347 ns/iter 1.40
JSON_Parse_Integer 5761.533177635206 ns/iter 3844.6051775435717 ns/iter 1.50
JSON_Parse_String_NonSSO_Plain 12126.96693128565 ns/iter 8755.076327222305 ns/iter 1.39
JSON_Parse_String_SSO_Plain 5199.083455137866 ns/iter 3123.655631980411 ns/iter 1.66
JSON_Parse_String_Escape_Heavy 25835.653451561604 ns/iter 17815.203301168214 ns/iter 1.45
JSON_Parse_Object_Short_Keys 13958.40761469443 ns/iter 8826.774610432818 ns/iter 1.58
JSON_Parse_Object_Scalar_Properties 7017.460874131917 ns/iter 4368.1354661976375 ns/iter 1.61
JSON_Parse_Object_Array_Properties 12230.445512876258 ns/iter 7396.061950270568 ns/iter 1.65
JSON_Parse_Object_Object_Properties 12582.918374329489 ns/iter 7380.879222162478 ns/iter 1.70
JSON_Parse_Nested_Containers 102734.56934622601 ns/iter 64644.301822214264 ns/iter 1.59
JSON_From_String_Copy 17.814793005052024 ns/iter 13.120662640882566 ns/iter 1.36
JSON_From_String_Temporary 15.045994609750506 ns/iter 11.47747718533662 ns/iter 1.31
JSON_Number_To_Double 20.584552501464152 ns/iter 14.076566228299058 ns/iter 1.46
JSON_Object_At_Last_Key/8 3.812688463549452 ns/iter 3.118289476339198 ns/iter 1.22
JSON_Object_At_Last_Key/32 11.894855079094503 ns/iter 9.700098641735636 ns/iter 1.23
JSON_Object_At_Last_Key/128 48.60889853517651 ns/iter 45.078291556942524 ns/iter 1.08
JSON_Object_At_Last_Key/512 216.84142651050524 ns/iter 154.81579639536378 ns/iter 1.40
JSON_Fast_Hash_Helm_Chart_Lock 62.710495255475536 ns/iter 35.83448750261832 ns/iter 1.75
JSON_Equality_Helm_Chart_Lock 160.4735580112658 ns/iter 89.80393363095327 ns/iter 1.79
JSON_Divisible_By_Decimal 251.87785584172514 ns/iter 177.83197487160433 ns/iter 1.42
JSON_String_Equal/10 5.08258389765414 ns/iter 3.1841955273382196 ns/iter 1.60
JSON_String_Equal/100 5.691605721240888 ns/iter 4.143523561654992 ns/iter 1.37
JSON_String_Equal_Small_By_Perfect_Hash/10 0.6234054586669182 ns/iter 0.6930717755801125 ns/iter 0.90
JSON_String_Equal_Small_By_Runtime_Perfect_Hash/10 25.196500744034434 ns/iter 13.201756945051018 ns/iter 1.91
JSON_String_Fast_Hash/10 2.260261299248711 ns/iter 1.5476330532896134 ns/iter 1.46
JSON_String_Fast_Hash/100 2.260404686447927 ns/iter 1.5478603520258811 ns/iter 1.46
JSON_String_Key_Hash/10 1.2470520749849765 ns/iter 0.6085154028062943 ns/iter 2.05
JSON_String_Key_Hash/100 12.44266802869741 ns/iter 9.87054395802615 ns/iter 1.26
JSON_Object_Defines_Miss_Same_Length 3.1123139586892643 ns/iter 2.0412279567764577 ns/iter 1.52
JSON_Object_Defines_Miss_Too_Small 3.113696636781007 ns/iter 2.2654455259192554 ns/iter 1.37
JSON_Object_Defines_Miss_Too_Large 3.1164851626486767 ns/iter 2.2196779809063787 ns/iter 1.40
Regex_Lower_S_Or_Upper_S_Asterisk 0.6271632337240829 ns/iter 0.36040253928528787 ns/iter 1.74
Regex_Caret_Lower_S_Or_Upper_S_Asterisk_Dollar 0.6235488387937386 ns/iter 0.36032422774939943 ns/iter 1.73
Regex_Period_Asterisk 0.6307636955176078 ns/iter 0.3603152981954473 ns/iter 1.75
Regex_Group_Period_Asterisk_Group 0.6233677307375514 ns/iter 0.3604754773330087 ns/iter 1.73
Regex_Period_Plus 0.6233505650721614 ns/iter 0.36014620219063037 ns/iter 1.73
Regex_Period 0.6231852786992261 ns/iter 0.3602814168564026 ns/iter 1.73
Regex_Caret_Period_Plus_Dollar 0.6228530000115439 ns/iter 0.3601254909439891 ns/iter 1.73
Regex_Caret_Group_Period_Plus_Group_Dollar 0.6265825214965969 ns/iter 0.3602087964118885 ns/iter 1.74
Regex_Caret_Period_Asterisk_Dollar 0.6231795731513661 ns/iter 0.3602812022942287 ns/iter 1.73
Regex_Caret_Group_Period_Asterisk_Group_Dollar 0.6231342106346872 ns/iter 0.36671599161692653 ns/iter 1.70
Regex_Caret_X_Hyphen 4.052160801967916 ns/iter 1.5022739776541671 ns/iter 2.70
Regex_Period_Md_Dollar 42.27086880621333 ns/iter 15.690435348469261 ns/iter 2.69
Regex_Caret_Slash_Period_Asterisk 4.364296001671113 ns/iter 1.503983193171789 ns/iter 2.90
Regex_Caret_Period_Range_Dollar 1.2486624026444753 ns/iter 1.203473577305924 ns/iter 1.04
Regex_Nested_Backtrack 44.21053072264141 ns/iter 24.501158663771687 ns/iter 1.80

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

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Benchmark (linux/llvm)

Details
Benchmark suite Current: a1e0b0d Previous: 1c2c0f1 Ratio
Regex_Lower_S_Or_Upper_S_Asterisk 2.826089443607088 ns/iter 2.520738496978584 ns/iter 1.12
Regex_Caret_Lower_S_Or_Upper_S_Asterisk_Dollar 2.4613728497323937 ns/iter 2.2175201556945723 ns/iter 1.11
Regex_Period_Asterisk 2.4622882670137836 ns/iter 2.205075539285451 ns/iter 1.12
Regex_Group_Period_Asterisk_Group 2.8128655251889194 ns/iter 2.5272053424364227 ns/iter 1.11
Regex_Period_Plus 4.220517698663256 ns/iter 3.1272648853156 ns/iter 1.35
Regex_Period 3.874704793337554 ns/iter 2.814246491641432 ns/iter 1.38
Regex_Caret_Period_Plus_Dollar 3.8739405829464633 ns/iter 2.8171323451606827 ns/iter 1.38
Regex_Caret_Group_Period_Plus_Group_Dollar 4.225380973507479 ns/iter 3.115704523577877 ns/iter 1.36
Regex_Caret_Period_Asterisk_Dollar 3.191654325114108 ns/iter 3.733952278928808 ns/iter 0.85
Regex_Caret_Group_Period_Asterisk_Group_Dollar 2.829120864930846 ns/iter 3.4234991878680185 ns/iter 0.83
Regex_Caret_X_Hyphen 6.910651400423963 ns/iter 6.540447664706389 ns/iter 1.06
Regex_Period_Md_Dollar 26.33036110603998 ns/iter 28.545744248134266 ns/iter 0.92
Regex_Caret_Slash_Period_Asterisk 6.216829555317829 ns/iter 6.223125504991132 ns/iter 1.00
Regex_Caret_Period_Range_Dollar 4.219987105443785 ns/iter 4.360585733425543 ns/iter 0.97
Regex_Nested_Backtrack 38.678100062724084 ns/iter 39.03166151338046 ns/iter 0.99
JSON_Array_Of_Objects_Unique 445.76021259292895 ns/iter 397.0865942952036 ns/iter 1.12
JSON_Parse_1 4785.173427784671 ns/iter 4864.634537484209 ns/iter 0.98
JSON_Parse_Real 5390.7295040723975 ns/iter 5491.6151876726335 ns/iter 0.98
JSON_Parse_Decimal 7619.517451276349 ns/iter 7568.910113461747 ns/iter 1.01
JSON_Parse_Schema_ISO_Language 3604584.304123809 ns/iter 3480308.1044777115 ns/iter 1.04
JSON_Parse_Integer 3965.4115700601274 ns/iter 3632.635128679152 ns/iter 1.09
JSON_Parse_String_NonSSO_Plain 5431.241620864181 ns/iter 5226.206583242651 ns/iter 1.04
JSON_Parse_String_SSO_Plain 2865.87093988399 ns/iter 2776.517396251063 ns/iter 1.03
JSON_Parse_String_Escape_Heavy 15586.592736995035 ns/iter 14679.575713255406 ns/iter 1.06
JSON_Parse_Object_Short_Keys 8268.484963647912 ns/iter 11403.818358069368 ns/iter 0.73
JSON_Parse_Object_Scalar_Properties 4198.399823609861 ns/iter 4318.340125541919 ns/iter 0.97
JSON_Parse_Object_Array_Properties 5725.2385838893615 ns/iter 5714.799310729664 ns/iter 1.00
JSON_Parse_Object_Object_Properties 5732.035255105896 ns/iter 5534.534543181721 ns/iter 1.04
JSON_Parse_Nested_Containers 45932.340246229614 ns/iter 45461.44458981651 ns/iter 1.01
JSON_From_String_Copy 20.831949502351854 ns/iter 22.93746599670268 ns/iter 0.91
JSON_From_String_Temporary 18.729260469508812 ns/iter 19.266035629793496 ns/iter 0.97
JSON_Number_To_Double 22.858305761757784 ns/iter 23.29034804888776 ns/iter 0.98
JSON_Object_At_Last_Key/8 4.107678006955204 ns/iter 3.8770518169316293 ns/iter 1.06
JSON_Object_At_Last_Key/32 13.451310757043695 ns/iter 12.325050961445902 ns/iter 1.09
JSON_Object_At_Last_Key/128 55.96501362788525 ns/iter 49.07459901466207 ns/iter 1.14
JSON_Object_At_Last_Key/512 372.85623440454515 ns/iter 393.2833377680529 ns/iter 0.95
JSON_Fast_Hash_Helm_Chart_Lock 74.9026180502033 ns/iter 58.20546778873356 ns/iter 1.29
JSON_Equality_Helm_Chart_Lock 160.63781367858311 ns/iter 151.9574914567795 ns/iter 1.06
JSON_Divisible_By_Decimal 248.860118720314 ns/iter 244.81844616836216 ns/iter 1.02
JSON_String_Equal/10 5.628818863046905 ns/iter 5.607531231597118 ns/iter 1.00
JSON_String_Equal/100 6.330870036416224 ns/iter 6.235988969853319 ns/iter 1.02
JSON_String_Equal_Small_By_Perfect_Hash/10 1.0558355109679067 ns/iter 0.9360117145254214 ns/iter 1.13
JSON_String_Equal_Small_By_Runtime_Perfect_Hash/10 12.475765350181641 ns/iter 10.581913215977398 ns/iter 1.18
JSON_String_Fast_Hash/10 2.814338736118542 ns/iter 2.4906697920258045 ns/iter 1.13
JSON_String_Fast_Hash/100 2.8140737341002047 ns/iter 2.499678749829614 ns/iter 1.13
JSON_String_Key_Hash/10 2.461662765923671 ns/iter 2.180809339870137 ns/iter 1.13
JSON_String_Key_Hash/100 8.193694186766283 ns/iter 6.539938916773623 ns/iter 1.25
JSON_Object_Defines_Miss_Same_Length 3.868732088863561 ns/iter 3.4524891313927815 ns/iter 1.12
JSON_Object_Defines_Miss_Too_Small 3.256837071647755 ns/iter 2.9584537889746665 ns/iter 1.10
JSON_Object_Defines_Miss_Too_Large 2.9306592545195187 ns/iter 2.653572610963156 ns/iter 1.10
Pointer_Object_Traverse 33.823369981572185 ns/iter 30.136653345422555 ns/iter 1.12
Pointer_Object_Try_Traverse 36.974200170119296 ns/iter 31.91152691082956 ns/iter 1.16
Pointer_Push_Back_Pointer_To_Weak_Pointer 184.21577679478406 ns/iter 152.06627451954654 ns/iter 1.21
Pointer_Walker_Schema_ISO_Language 2722095.3190663867 ns/iter 2607702.817164436 ns/iter 1.04
Pointer_Maybe_Tracked_Deeply_Nested/0 1295864.4436229307 ns/iter 1241307.9946809101 ns/iter 1.04
Pointer_Maybe_Tracked_Deeply_Nested/1 1624534.8403754819 ns/iter 1597440.108490791 ns/iter 1.02
Pointer_Position_Tracker_Get_Deeply_Nested 735.6324041201838 ns/iter 660.7188810307703 ns/iter 1.11
JSONPath_Descendant_Filter_Nested 1593.927563162759 ns/iter 1642.0362167739827 ns/iter 0.97
URITemplateRouter_Create 31619.73223796674 ns/iter 32977.8477232687 ns/iter 0.96
URITemplateRouter_Match 180.72089973137867 ns/iter 189.48312325308183 ns/iter 0.95
URITemplateRouter_Match_BasePath 214.26138147758758 ns/iter 209.3659067055763 ns/iter 1.02
URITemplateRouterView_Restore 9888.894884460382 ns/iter 8275.288272357175 ns/iter 1.19
URITemplateRouterView_Match 147.83265374621223 ns/iter 144.22389197386104 ns/iter 1.03
URITemplateRouterView_Match_BasePath 168.37541280636938 ns/iter 166.54683344182004 ns/iter 1.01
URITemplateRouterView_Arguments 456.02527205641 ns/iter 430.41970082700726 ns/iter 1.06
JSONL_Parse_Large 9227722.49999962 ns/iter 9748508.291666426 ns/iter 0.95
JSONL_Parse_Large_GZIP 11001089.546875065 ns/iter 11326387.419354623 ns/iter 0.97
JSONLD_Catalog_Annotation_List_Populate 1295645.234750407 ns/iter 1255824.381461599 ns/iter 1.03
JSONLD_Catalog_Materialize 4405436.911392366 ns/iter 4201377.401197457 ns/iter 1.05
HTML_Build_Table_100000 69183139.30000295 ns/iter 68129011.8999982 ns/iter 1.02
HTML_Render_Table_100000 4998354.164285956 ns/iter 5479537.130081257 ns/iter 0.91
GZIP_Compress_ISO_Language_Set_3_Locations 35471521.90000133 ns/iter 33883803.142852485 ns/iter 1.05
GZIP_Decompress_ISO_Language_Set_3_Locations 4280395.365853798 ns/iter 4082210.7719302373 ns/iter 1.05
GZIP_Compress_ISO_Language_Set_3_Schema 2123087.142857315 ns/iter 1901567.6902173061 ns/iter 1.12
GZIP_Decompress_ISO_Language_Set_3_Schema 279011.9135654561 ns/iter 354095.3050505226 ns/iter 0.79
JOSE_VerifySignature_RS256 63729.26239518675 ns/iter 60373.7463431444 ns/iter 1.06
JOSE_VerifySignature_ES512 2679641.1187740127 ns/iter 2450256.7323944615 ns/iter 1.09

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

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Benchmark (windows/msvc)

Details
Benchmark suite Current: a1e0b0d Previous: 1c2c0f1 Ratio
Regex_Lower_S_Or_Upper_S_Asterisk 5.37065800000164 ns/iter 5.386759821429824 ns/iter 1.00
Regex_Caret_Lower_S_Or_Upper_S_Asterisk_Dollar 5.082138000000214 ns/iter 5.023406261213267 ns/iter 1.01
Regex_Period_Asterisk 5.011974999999893 ns/iter 5.019426785714082 ns/iter 1.00
Regex_Group_Period_Asterisk_Group 5.112062999999125 ns/iter 5.1016820000018015 ns/iter 1.00
Regex_Period_Plus 5.020503999999164 ns/iter 5.033688392856562 ns/iter 1.00
Regex_Period 5.329243999999562 ns/iter 5.352449000001798 ns/iter 1.00
Regex_Caret_Period_Plus_Dollar 5.015138999999635 ns/iter 5.040701000000354 ns/iter 0.99
Regex_Caret_Group_Period_Plus_Group_Dollar 5.3264741071440564 ns/iter 5.329360999999153 ns/iter 1.00
Regex_Caret_Period_Asterisk_Dollar 5.325412499999516 ns/iter 5.33251799999789 ns/iter 1.00
Regex_Caret_Group_Period_Asterisk_Group_Dollar 5.0193785714286925 ns/iter 5.096023000000969 ns/iter 0.98
Regex_Caret_X_Hyphen 8.47331915859983 ns/iter 8.501572729902803 ns/iter 1.00
Regex_Period_Md_Dollar 44.65498749999597 ns/iter 44.57177970917245 ns/iter 1.00
Regex_Caret_Slash_Period_Asterisk 7.8411272321434105 ns/iter 7.84601339285881 ns/iter 1.00
Regex_Caret_Period_Range_Dollar 5.963637499998445 ns/iter 5.959042857142549 ns/iter 1.00
Regex_Nested_Backtrack 55.15249000000039 ns/iter 55.1570357142899 ns/iter 1.00
JSON_Array_Of_Objects_Unique 620.4830357142604 ns/iter 602.1700000001066 ns/iter 1.03
JSON_Parse_1 8868.267105951787 ns/iter 9053.395089286503 ns/iter 0.98
JSON_Parse_Real 16212.328125000397 ns/iter 16213.779556557856 ns/iter 1.00
JSON_Parse_Decimal 11743.541071427087 ns/iter 11779.639062503122 ns/iter 1.00
JSON_Parse_Schema_ISO_Language 7555087.500000874 ns/iter 7205309.999999877 ns/iter 1.05
JSON_Parse_Integer 6153.286607144537 ns/iter 6141.302678571493 ns/iter 1.00
JSON_Parse_String_NonSSO_Plain 7868.768973214709 ns/iter 7777.719866070804 ns/iter 1.01
JSON_Parse_String_SSO_Plain 3681.225926383051 ns/iter 3607.533511651512 ns/iter 1.02
JSON_Parse_String_Escape_Heavy 21773.565624997107 ns/iter 21578.109374999596 ns/iter 1.01
JSON_Parse_Object_Short_Keys 13237.133928571762 ns/iter 13401.63749999793 ns/iter 0.99
JSON_Parse_Object_Scalar_Properties 6820.149553569925 ns/iter 6884.620535712673 ns/iter 0.99
JSON_Parse_Object_Array_Properties 11466.745312500138 ns/iter 11255.589062500349 ns/iter 1.02
JSON_Parse_Object_Object_Properties 11689.35892857397 ns/iter 11444.410714286083 ns/iter 1.02
JSON_Parse_Nested_Containers 80158.10267857202 ns/iter 78775.99330356081 ns/iter 1.02
JSON_From_String_Copy 64.00609821428459 ns/iter 64.0103124999923 ns/iter 1.00
JSON_From_String_Temporary 58.82892857144383 ns/iter 59.184330357148994 ns/iter 0.99
JSON_Number_To_Double 121.87198214283917 ns/iter 123.81098214283222 ns/iter 0.98
JSON_Object_At_Last_Key/8 7.230017857141137 ns/iter 7.266455357142527 ns/iter 0.99
JSON_Object_At_Last_Key/32 23.28132898123473 ns/iter 23.42133456002793 ns/iter 0.99
JSON_Object_At_Last_Key/128 89.39925940183915 ns/iter 89.28625047831488 ns/iter 1.00
JSON_Object_At_Last_Key/512 424.4987069528422 ns/iter 422.4411619884812 ns/iter 1.00
JSON_Fast_Hash_Helm_Chart_Lock 102.32923203887194 ns/iter 102.37540624999042 ns/iter 1.00
JSON_Equality_Helm_Chart_Lock 235.3993598885006 ns/iter 237.4558571428257 ns/iter 0.99
JSON_Divisible_By_Decimal 297.14181505117654 ns/iter 297.80689979830817 ns/iter 1.00
JSON_String_Equal/10 10.34977629308003 ns/iter 10.379414062498427 ns/iter 1.00
JSON_String_Equal/100 11.633923214284486 ns/iter 11.933780357143828 ns/iter 0.97
JSON_String_Equal_Small_By_Perfect_Hash/10 2.515506694182624 ns/iter 2.5176559798950864 ns/iter 1.00
JSON_String_Equal_Small_By_Runtime_Perfect_Hash/10 14.355723150198239 ns/iter 14.273336989847355 ns/iter 1.01
JSON_String_Fast_Hash/10 6.70923303571515 ns/iter 6.724958035714426 ns/iter 1.00
JSON_String_Fast_Hash/100 6.615142857143549 ns/iter 6.749149553572562 ns/iter 0.98
JSON_String_Key_Hash/10 5.374782999999752 ns/iter 5.464437000000544 ns/iter 0.98
JSON_String_Key_Hash/100 11.873454687499674 ns/iter 11.92121964285369 ns/iter 1.00
JSON_Object_Defines_Miss_Same_Length 3.786405284262503 ns/iter 3.7831257306965407 ns/iter 1.00
JSON_Object_Defines_Miss_Too_Small 4.09590130195676 ns/iter 4.104877498166922 ns/iter 1.00
JSON_Object_Defines_Miss_Too_Large 3.775843386114545 ns/iter 3.769479100411857 ns/iter 1.00
Pointer_Object_Traverse 71.17132812502241 ns/iter 70.630142857157 ns/iter 1.01
Pointer_Object_Try_Traverse 71.67927455355994 ns/iter 71.46206473215447 ns/iter 1.00
Pointer_Push_Back_Pointer_To_Weak_Pointer 184.5435700485245 ns/iter 181.0459983076937 ns/iter 1.02
Pointer_Walker_Schema_ISO_Language 12567082.142859524 ns/iter 10944017.187501486 ns/iter 1.15
Pointer_Maybe_Tracked_Deeply_Nested/0 2515146.590909443 ns/iter 2432018.875502164 ns/iter 1.03
Pointer_Maybe_Tracked_Deeply_Nested/1 3690856.149731987 ns/iter 3741732.3076927764 ns/iter 0.99
Pointer_Position_Tracker_Get_Deeply_Nested 565.0626116070003 ns/iter 566.5955138180142 ns/iter 1.00
JSONPath_Descendant_Filter_Nested 2443.181201806723 ns/iter 2415.4464285719055 ns/iter 1.01
URITemplateRouter_Create 41051.73265835228 ns/iter 40344.52440368456 ns/iter 1.02
URITemplateRouter_Match 234.72318808897953 ns/iter 234.2816926025044 ns/iter 1.00
URITemplateRouter_Match_BasePath 265.09816362047246 ns/iter 265.24406764488464 ns/iter 1.00
URITemplateRouterView_Restore 31296.545258515645 ns/iter 33999.24376350565 ns/iter 0.92
URITemplateRouterView_Match 180.43327503864882 ns/iter 180.16881563633393 ns/iter 1.00
URITemplateRouterView_Match_BasePath 205.3658219076672 ns/iter 205.01913147235814 ns/iter 1.00
URITemplateRouterView_Arguments 534.8564000000806 ns/iter 531.9394999999076 ns/iter 1.01
JSONL_Parse_Large 32956490.476191815 ns/iter 32803823.809531637 ns/iter 1.00
JSONL_Parse_Large_GZIP 33565225.000006646 ns/iter 33386214.28571016 ns/iter 1.01
JSONLD_Catalog_Annotation_List_Populate 2762988.636363568 ns/iter 2681240.5303024375 ns/iter 1.03
JSONLD_Catalog_Materialize 8031701.111111842 ns/iter 7731357.777775984 ns/iter 1.04
HTML_Build_Table_100000 88777299.99997948 ns/iter 88843022.2222117 ns/iter 1.00
HTML_Render_Table_100000 7724851.111109071 ns/iter 7590938.888888053 ns/iter 1.02
GZIP_Compress_ISO_Language_Set_3_Locations 36566210.526320666 ns/iter 36222884.21052202 ns/iter 1.01
GZIP_Decompress_ISO_Language_Set_3_Locations 10079120.00000033 ns/iter 9805549.33333527 ns/iter 1.03
GZIP_Compress_ISO_Language_Set_3_Schema 2138460.937500497 ns/iter 2112936.5624993565 ns/iter 1.01
GZIP_Decompress_ISO_Language_Set_3_Schema 636756.6071428347 ns/iter 619523.571428512 ns/iter 1.03
JOSE_VerifySignature_RS256 21339.60013928787 ns/iter 21234.593750001808 ns/iter 1.00
JOSE_VerifySignature_ES512 1532460.8433735215 ns/iter 1545233.9285713735 ns/iter 0.99

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

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant