Skip to content

Support powering the Crypto logic by a system OpenSSL#2248

Merged
jviotti merged 1 commit intomainfrom
system-openssl
Feb 16, 2026
Merged

Support powering the Crypto logic by a system OpenSSL#2248
jviotti merged 1 commit intomainfrom
system-openssl

Conversation

@jviotti
Copy link
Copy Markdown
Member

@jviotti jviotti commented Feb 16, 2026

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

Copy link
Copy Markdown

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

Choose a reason for hiding this comment

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

2 issues found across 6 files

Prompt for AI agents (all issues)

Check if these issues are valid — if so, understand the root cause of each and fix them. If appropriate, use sub-agents to investigate and fix each issue separately.


<file name="src/core/crypto/crypto_uuid.cc">

<violation number="1" location="src/core/crypto/crypto_uuid.cc:27">
P1: The return value of `RAND_bytes()` is not checked. According to the OpenSSL documentation, "it is important to always check the error return value of `RAND_bytes()`". If the call fails (returns 0 or -1), `random_bytes` stays zero-initialized, producing a deterministic UUID which could cause collisions and security issues.</violation>
</file>

<file name="src/core/crypto/crypto_sha256.cc">

<violation number="1" location="src/core/crypto/crypto_sha256.cc:23">
P1: Missing NULL check on `EVP_MD_CTX_new()` — will cause a null-pointer dereference if allocation fails. Additionally, the return values of `EVP_DigestInit_ex`, `EVP_DigestUpdate`, and `EVP_DigestFinal_ex` (which return 0 on failure) are all ignored, silently producing incorrect output on error. Consider using RAII (e.g., `std::unique_ptr` with a custom deleter) for exception safety and checking return values.</violation>
</file>

Reply with feedback, questions, or to request a fix. Tag @cubic-dev-ai to re-run a review.

@augmentcode
Copy link
Copy Markdown

augmentcode bot commented Feb 16, 2026

🤖 Augment PR Summary

Summary: Adds an opt-in build mode to power core::crypto via the system OpenSSL instead of the internal implementations.

Changes:

  • Introduced SOURCEMETA_CORE_CRYPTO_USE_SYSTEM_OPENSSL and added CI coverage for it
  • When enabled, locates OpenSSL during the build and declares it as a package dependency
  • Links sourcemeta::core::crypto against OpenSSL::Crypto and toggles compilation via a preprocessor define
  • Implements sha256() using OpenSSL EVP and uuidv4() using RAND_bytes under the new mode

🤖 Was this summary useful? React with 👍 or 👎

Copy link
Copy Markdown

@augmentcode augmentcode bot left a comment

Choose a reason for hiding this comment

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

Review completed. 5 suggestions posted.

Fix All in Augment

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

if(SOURCEMETA_CORE_CRYPTO_USE_SYSTEM_OPENSSL)
target_compile_definitions(sourcemeta_core_crypto
PRIVATE SOURCEMETA_CORE_CRYPTO_USE_SYSTEM_OPENSSL)
target_link_libraries(sourcemeta_core_crypto PRIVATE OpenSSL::Crypto)
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

When building as a static library, linking OpenSSL::Crypto as PRIVATE won’t propagate to dependents, so consumers/tests linking only sourcemeta::core::crypto may hit unresolved OpenSSL symbols. Consider whether this dependency needs to be part of the target’s link interface when SOURCEMETA_CORE_CRYPTO_USE_SYSTEM_OPENSSL is enabled.

Severity: high

Fix This in Augment

🤖 Was this useful? React with 👍 or 👎, or 🚀 if it prevented an incident/outage.


#ifdef SOURCEMETA_CORE_CRYPTO_USE_SYSTEM_OPENSSL
std::array<unsigned char, 16> random_bytes{};
RAND_bytes(random_bytes.data(), static_cast<int>(random_bytes.size()));
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

RAND_bytes(...) return value is ignored; if it fails, random_bytes remains all-zero and UUIDs become predictable/colliding. Consider checking the return and handling failure explicitly (error out or fall back).

Severity: high

Fix This in Augment

🤖 Was this useful? React with 👍 or 👎, or 🚀 if it prevented an incident/outage.

namespace sourcemeta::core {

auto sha256(const std::string_view input, std::ostream &output) -> void {
auto *context = EVP_MD_CTX_new();
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

The OpenSSL EVP calls here don’t check for failures (e.g., EVP_MD_CTX_new() returning null or EVP_Digest* returning 0), which could lead to crashes or emitting an incorrect digest. Consider validating the return codes and length from EVP_DigestFinal_ex before writing output.

Severity: medium

Fix This in Augment

🤖 Was this useful? React with 👍 or 👎, or 🚀 if it prevented an incident/outage.


if(SOURCEMETA_CORE_CRYPTO)
if(SOURCEMETA_CORE_CRYPTO_USE_SYSTEM_OPENSSL)
find_package(OpenSSL REQUIRED)
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Since the implementation links only OpenSSL::Crypto, consider requesting just the Crypto component in find_package(OpenSSL ...) to avoid unnecessarily requiring the SSL part of OpenSSL on platforms that split packages.

Severity: low

Fix This in Augment

🤖 Was this useful? React with 👍 or 👎, or 🚀 if it prevented an incident/outage.

include("${CMAKE_CURRENT_LIST_DIR}/sourcemeta_core_time.cmake")
elseif(component STREQUAL "crypto")
if(@SOURCEMETA_CORE_CRYPTO_USE_SYSTEM_OPENSSL@)
find_dependency(OpenSSL)
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

For consistency with the actual link dependency (OpenSSL::Crypto), consider having the package config request only the Crypto component when calling find_dependency(OpenSSL ...) under SOURCEMETA_CORE_CRYPTO_USE_SYSTEM_OPENSSL.

Severity: low

Fix This in Augment

🤖 Was this useful? React with 👍 or 👎, or 🚀 if it prevented an incident/outage.

Signed-off-by: Juan Cruz Viotti <jv@jviotti.com>
Copy link
Copy Markdown

@github-actions github-actions bot left a comment

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: e6a0f12 Previous: 0a1cda9 Ratio
Regex_Lower_S_Or_Upper_S_Asterisk 3.126109140895566 ns/iter 3.1144364206959274 ns/iter 1.00
Regex_Caret_Lower_S_Or_Upper_S_Asterisk_Dollar 3.1082820424249675 ns/iter 3.107383005795474 ns/iter 1.00
Regex_Period_Asterisk 3.1110055674787898 ns/iter 3.1111263710902124 ns/iter 1.00
Regex_Group_Period_Asterisk_Group 3.109439350214684 ns/iter 3.109470325926987 ns/iter 1.00
Regex_Period_Plus 2.876822243767504 ns/iter 2.892788548336251 ns/iter 0.99
Regex_Period 3.1005406006357057 ns/iter 3.095564693460697 ns/iter 1.00
Regex_Caret_Period_Plus_Dollar 2.891561189027771 ns/iter 2.941431338971866 ns/iter 0.98
Regex_Caret_Group_Period_Plus_Group_Dollar 2.8788129555820894 ns/iter 2.894437777306607 ns/iter 0.99
Regex_Caret_Period_Asterisk_Dollar 3.1091868333952375 ns/iter 3.1102344648955462 ns/iter 1.00
Regex_Caret_Group_Period_Asterisk_Group_Dollar 3.419421940226541 ns/iter 3.4216735484654826 ns/iter 1.00
Regex_Caret_X_Hyphen 7.469434640021827 ns/iter 13.061284009397099 ns/iter 0.57
Regex_Period_Md_Dollar 27.383666712756504 ns/iter 27.374069321264354 ns/iter 1.00
Regex_Caret_Slash_Period_Asterisk 6.223656812881598 ns/iter 5.911646747759837 ns/iter 1.05
Regex_Caret_Period_Range_Dollar 4.044197137764264 ns/iter 3.1109709238249237 ns/iter 1.30
Regex_Nested_Backtrack 48.894100860198535 ns/iter 48.78814536584081 ns/iter 1.00
JSON_Array_Of_Objects_Unique 444.1846630008095 ns/iter 445.84896072842577 ns/iter 1.00
JSON_Parse_1 8036.763309569469 ns/iter 8303.221517908381 ns/iter 0.97
JSON_Parse_Real 11881.3675923725 ns/iter 12091.31670587417 ns/iter 0.98
JSON_Parse_Decimal 81917.80334190035 ns/iter 83372.71018519303 ns/iter 0.98
JSON_Parse_Schema_ISO_Language 8091179.356321699 ns/iter 7980247.659090041 ns/iter 1.01
JSON_Fast_Hash_Helm_Chart_Lock 62.50512395003912 ns/iter 62.5183650748659 ns/iter 1.00
JSON_Equality_Helm_Chart_Lock 175.18401333129637 ns/iter 166.66227343343957 ns/iter 1.05
JSON_String_Equal/10 7.466796743835761 ns/iter 6.568418315777037 ns/iter 1.14
JSON_String_Equal/100 8.097194914111315 ns/iter 7.166594295269675 ns/iter 1.13
JSON_String_Equal_Small_By_Perfect_Hash/10 0.9360674361452336 ns/iter 0.9357542452044129 ns/iter 1.00
JSON_String_Equal_Small_By_Runtime_Perfect_Hash/10 14.606644807829104 ns/iter 14.613644957583887 ns/iter 1.00
JSON_String_Fast_Hash/10 2.8004410688744814 ns/iter 2.801548296058515 ns/iter 1.00
JSON_String_Fast_Hash/100 2.8064110878173567 ns/iter 2.809319790981033 ns/iter 1.00
JSON_String_Key_Hash/10 2.648181955234342 ns/iter 2.6426625627427507 ns/iter 1.00
JSON_String_Key_Hash/100 9.014914431695237 ns/iter 9.02102721604545 ns/iter 1.00
JSON_Object_Defines_Miss_Same_Length 3.7371735359935547 ns/iter 3.7370114123903106 ns/iter 1.00
JSON_Object_Defines_Miss_Too_Small 3.738806708346011 ns/iter 3.7404400870075234 ns/iter 1.00
JSON_Object_Defines_Miss_Too_Large 3.7379430060117933 ns/iter 3.741063571711801 ns/iter 1.00
Pointer_Object_Traverse 46.48639074738452 ns/iter 43.6514146940791 ns/iter 1.06
Pointer_Object_Try_Traverse 53.56398551939803 ns/iter 53.63899740258868 ns/iter 1.00
Pointer_Push_Back_Pointer_To_Weak_Pointer 304.39342909007684 ns/iter 304.57884427376166 ns/iter 1.00
Pointer_Walker_Schema_ISO_Language 3178851.8738738294 ns/iter 3190178.934272287 ns/iter 1.00
Schema_Frame_WoT_References 4805745.2275864715 ns/iter 4815549.386206651 ns/iter 1.00
Schema_Frame_OMC_References 19842364.000000346 ns/iter 21868113.272727314 ns/iter 0.91
Schema_Frame_OMC_Locations 18321055.052632276 ns/iter 19656843.61764756 ns/iter 0.93
Schema_Frame_ISO_Language_Locations 101115769.33333784 ns/iter 104082923.66668093 ns/iter 0.97
Schema_Frame_KrakenD_References 37369920.526316494 ns/iter 41391323.05882038 ns/iter 0.90
Schema_Frame_KrakenD_Reachable 576043771.9999346 ns/iter 614517541.9999305 ns/iter 0.94
Schema_Iterator_ISO_Language 2316010.2541806432 ns/iter 2336668.8127091806 ns/iter 0.99
Schema_Frame_ISO_Language_Locations_To_JSON 127830023.2499987 ns/iter 130813664.25001307 ns/iter 0.98
Schema_Tracker_ISO_Language 28783354.25000008 ns/iter 29762517.521738157 ns/iter 0.97
Schema_Tracker_ISO_Language_To_JSON 22818240.322580565 ns/iter 23358804.0689679 ns/iter 0.98
Schema_Format_ISO_Language_To_JSON 106107578.33330809 ns/iter 105880690.33332203 ns/iter 1.00
Schema_Bundle_Meta_2020_12 1676695.7961676747 ns/iter 1673323.0668275473 ns/iter 1.00
Schema_Frame_Many_Resources_References 358927351.0000339 ns/iter 359828983.99998933 ns/iter 1.00
Alterschema_Check_Readibility_ISO_Language_Set_3 215707876.99999985 ns/iter 215173651.66664603 ns/iter 1.00
Alterschema_Check_Readibility_OMC 32110627.63636557 ns/iter 31980485.99999869 ns/iter 1.00
Alterschema_Apply_Readibility_KrakenD 598810138.0000899 ns/iter 589124738.9999989 ns/iter 1.02
EditorSchema_ForEditor_EmbeddedResources 13503842.346142828 ns/iter 13292939.509427633 ns/iter 1.02
URITemplateRouter_Create 16664.12578661536 ns/iter 16506.69425081172 ns/iter 1.01
URITemplateRouter_Match 181.27729231585033 ns/iter 175.4070635738449 ns/iter 1.03
URITemplateRouterView_Restore 9420.497410956616 ns/iter 9414.860825418225 ns/iter 1.00
URITemplateRouterView_Match 123.49671626528374 ns/iter 127.59206646926617 ns/iter 0.97

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

@jviotti jviotti merged commit a82a1db into main Feb 16, 2026
12 checks passed
@jviotti jviotti deleted the system-openssl branch February 16, 2026 16:40
Copy link
Copy Markdown

@github-actions github-actions bot left a comment

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: e6a0f12 Previous: 0a1cda9 Ratio
Regex_Lower_S_Or_Upper_S_Asterisk 4.422626875000191 ns/iter 4.436171874999673 ns/iter 1.00
Regex_Caret_Lower_S_Or_Upper_S_Asterisk_Dollar 4.087267230318252 ns/iter 4.098704261562979 ns/iter 1.00
Regex_Period_Asterisk 3.859776824327082 ns/iter 3.8019487432112604 ns/iter 1.02
Regex_Group_Period_Asterisk_Group 3.773176064690589 ns/iter 3.7791760646805606 ns/iter 1.00
Regex_Period_Plus 3.8613069573905707 ns/iter 3.783899457528245 ns/iter 1.02
Regex_Period 3.7890241003768192 ns/iter 3.7829129464280897 ns/iter 1.00
Regex_Caret_Period_Plus_Dollar 4.169001956841878 ns/iter 3.8499433859827223 ns/iter 1.08
Regex_Caret_Group_Period_Plus_Group_Dollar 3.9084447544647714 ns/iter 3.776293386113823 ns/iter 1.03
Regex_Caret_Period_Asterisk_Dollar 4.092946064120299 ns/iter 3.813123207476397 ns/iter 1.07
Regex_Caret_Group_Period_Asterisk_Group_Dollar 3.971204241071748 ns/iter 3.7869198146669754 ns/iter 1.05
Regex_Caret_X_Hyphen 7.267444196428536 ns/iter 7.264772321427922 ns/iter 1.00
Regex_Period_Md_Dollar 35.49010869092104 ns/iter 35.45167096795088 ns/iter 1.00
Regex_Caret_Slash_Period_Asterisk 6.973848214286704 ns/iter 6.9359116071439075 ns/iter 1.01
Regex_Caret_Period_Range_Dollar 4.780202768925056 ns/iter 4.734223671281176 ns/iter 1.01
Regex_Nested_Backtrack 107.1430781250271 ns/iter 107.1543124999863 ns/iter 1.00
JSON_Array_Of_Objects_Unique 458.4121558955132 ns/iter 454.6630433937562 ns/iter 1.01
JSON_Parse_1 11041.264285714598 ns/iter 11177.043749999171 ns/iter 0.99
JSON_Parse_Real 16275.841579297596 ns/iter 16337.920789649315 ns/iter 1.00
JSON_Parse_Decimal 186210.5629715855 ns/iter 185254.70110274715 ns/iter 1.01
JSON_Parse_Schema_ISO_Language 8347251.111111594 ns/iter 8695052.222222129 ns/iter 0.96
JSON_Fast_Hash_Helm_Chart_Lock 59.55017857142967 ns/iter 63.07073214285553 ns/iter 0.94
JSON_Equality_Helm_Chart_Lock 249.65542857143777 ns/iter 243.4941022886103 ns/iter 1.03
JSON_String_Equal/10 12.298583928575065 ns/iter 12.268319642856795 ns/iter 1.00
JSON_String_Equal/100 13.015683928569745 ns/iter 12.899914285713164 ns/iter 1.01
JSON_String_Equal_Small_By_Perfect_Hash/10 2.2266353124997806 ns/iter 2.205500000000171 ns/iter 1.01
JSON_String_Equal_Small_By_Runtime_Perfect_Hash/10 12.927435210145775 ns/iter 12.879863781788064 ns/iter 1.00
JSON_String_Fast_Hash/10 3.462834302625039 ns/iter 3.446264458131935 ns/iter 1.00
JSON_String_Fast_Hash/100 3.472361847252652 ns/iter 3.4519055741928875 ns/iter 1.01
JSON_String_Key_Hash/10 4.406776551680111 ns/iter 4.398906292679571 ns/iter 1.00
JSON_String_Key_Hash/100 14.099787660268529 ns/iter 14.039216455180103 ns/iter 1.00
JSON_Object_Defines_Miss_Same_Length 3.780738743248847 ns/iter 3.764202314706309 ns/iter 1.00
JSON_Object_Defines_Miss_Too_Small 3.7931030289402883 ns/iter 3.763996093749508 ns/iter 1.01
JSON_Object_Defines_Miss_Too_Large 3.787542410714297 ns/iter 3.7640442789924 ns/iter 1.01
Pointer_Object_Traverse 54.13284999999633 ns/iter 54.23638392857454 ns/iter 1.00
Pointer_Object_Try_Traverse 75.71212053572347 ns/iter 72.93561383929465 ns/iter 1.04
Pointer_Push_Back_Pointer_To_Weak_Pointer 147.45603359573684 ns/iter 150.0408816946242 ns/iter 0.98
Pointer_Walker_Schema_ISO_Language 9754434.374997346 ns/iter 10080129.333330963 ns/iter 0.97
Schema_Frame_WoT_References 9320550.00000176 ns/iter 9534166.666665744 ns/iter 0.98
Schema_Frame_OMC_References 40997888.235297605 ns/iter 41847311.76471413 ns/iter 0.98
Schema_Frame_OMC_Locations 38785268.42105968 ns/iter 37872426.31579159 ns/iter 1.02
Schema_Frame_ISO_Language_Locations 194660975.00003344 ns/iter 191471766.66668507 ns/iter 1.02
Schema_Frame_KrakenD_References 88191088.88888472 ns/iter 86150214.28571318 ns/iter 1.02
Schema_Frame_KrakenD_Reachable 525928400.00011164 ns/iter 491818800.0000327 ns/iter 1.07
Schema_Iterator_ISO_Language 4273899.999999964 ns/iter 4213465.662650631 ns/iter 1.01
Schema_Frame_ISO_Language_Locations_To_JSON 254858933.33332872 ns/iter 251879966.66666853 ns/iter 1.01
Schema_Tracker_ISO_Language 49629573.33333786 ns/iter 48408235.71428895 ns/iter 1.03
Schema_Tracker_ISO_Language_To_JSON 52302990.90908375 ns/iter 52831320.000018425 ns/iter 0.99
Schema_Format_ISO_Language_To_JSON 193135399.99984643 ns/iter 188920549.99997753 ns/iter 1.02
Schema_Bundle_Meta_2020_12 2844749.1525462363 ns/iter 2774604.8192822277 ns/iter 1.03
Schema_Frame_Many_Resources_References 1433152500.0000055 ns/iter 1423517200.0001056 ns/iter 1.01
Alterschema_Check_Readibility_ISO_Language_Set_3 317558350.000013 ns/iter 315983500.00001574 ns/iter 1.00
Alterschema_Check_Readibility_OMC 58701600.0000114 ns/iter 57005909.090900205 ns/iter 1.03
Alterschema_Apply_Readibility_KrakenD 966808099.9999802 ns/iter 957285599.9999775 ns/iter 1.01
EditorSchema_ForEditor_EmbeddedResources 26580538.46152178 ns/iter 26374526.923063967 ns/iter 1.01
URITemplateRouter_Create 22402.35376837512 ns/iter 22273.231325545792 ns/iter 1.01
URITemplateRouter_Match 206.80737500001098 ns/iter 206.0185934812978 ns/iter 1.00
URITemplateRouterView_Restore 31972.81696427824 ns/iter 31453.89285713967 ns/iter 1.02
URITemplateRouterView_Match 142.08681062110173 ns/iter 142.7889508928867 ns/iter 1.00

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

Copy link
Copy Markdown

@github-actions github-actions bot left a comment

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: e6a0f12 Previous: 0a1cda9 Ratio
Regex_Lower_S_Or_Upper_S_Asterisk 1.7740617359819308 ns/iter 1.8700754851957575 ns/iter 0.95
Regex_Caret_Lower_S_Or_Upper_S_Asterisk_Dollar 1.7475434563398855 ns/iter 1.7903983197436155 ns/iter 0.98
Regex_Period_Asterisk 1.8634503923367418 ns/iter 2.139702247000882 ns/iter 0.87
Regex_Group_Period_Asterisk_Group 1.7325061261617787 ns/iter 1.9754486494171402 ns/iter 0.88
Regex_Period_Plus 1.9958835687394034 ns/iter 2.1525736896215335 ns/iter 0.93
Regex_Period 1.9395098101783694 ns/iter 2.324582547042421 ns/iter 0.83
Regex_Caret_Period_Plus_Dollar 1.8939083397656953 ns/iter 2.69300041376837 ns/iter 0.70
Regex_Caret_Group_Period_Plus_Group_Dollar 1.890163863721082 ns/iter 2.375322643497551 ns/iter 0.80
Regex_Caret_Period_Asterisk_Dollar 1.7100392432342688 ns/iter 1.899406189208225 ns/iter 0.90
Regex_Caret_Group_Period_Asterisk_Group_Dollar 1.5904777898348401 ns/iter 1.757015511091446 ns/iter 0.91
Regex_Caret_X_Hyphen 6.259437665938389 ns/iter 7.001172684562954 ns/iter 0.89
Regex_Period_Md_Dollar 18.967020352246358 ns/iter 22.863094737138532 ns/iter 0.83
Regex_Caret_Slash_Period_Asterisk 5.454047536307844 ns/iter 6.121785128902352 ns/iter 0.89
Regex_Caret_Period_Range_Dollar 1.6434994286502893 ns/iter 1.847178243133769 ns/iter 0.89
Regex_Nested_Backtrack 27.030332899522985 ns/iter 31.4430141056819 ns/iter 0.86
JSON_Array_Of_Objects_Unique 339.4664305332509 ns/iter 407.64896734173686 ns/iter 0.83
JSON_Parse_1 5540.540275204092 ns/iter 7413.112339894146 ns/iter 0.75
JSON_Parse_Real 7206.362751799323 ns/iter 8505.777855763145 ns/iter 0.85
JSON_Parse_Decimal 237255.03058599873 ns/iter 235383.06258456895 ns/iter 1.01
JSON_Parse_Schema_ISO_Language 5155728.703704409 ns/iter 6511529.52083341 ns/iter 0.79
JSON_Fast_Hash_Helm_Chart_Lock 60.44490832142155 ns/iter 65.16202202976379 ns/iter 0.93
JSON_Equality_Helm_Chart_Lock 141.90637254744348 ns/iter 193.29552874001985 ns/iter 0.73
JSON_String_Equal/10 6.857172482560815 ns/iter 8.850655022901204 ns/iter 0.77
JSON_String_Equal/100 6.619785608108526 ns/iter 8.21075376588198 ns/iter 0.81
JSON_String_Equal_Small_By_Perfect_Hash/10 0.7553862746038522 ns/iter 0.9900833964502065 ns/iter 0.76
JSON_String_Equal_Small_By_Runtime_Perfect_Hash/10 3.272988496144051 ns/iter 4.322315305638816 ns/iter 0.76
JSON_String_Fast_Hash/10 2.3328331582849344 ns/iter 2.9931829815020263 ns/iter 0.78
JSON_String_Fast_Hash/100 2.0647971764615507 ns/iter 2.33347409098059 ns/iter 0.88
JSON_String_Key_Hash/10 1.286645943079977 ns/iter 1.7836481711983994 ns/iter 0.72
JSON_String_Key_Hash/100 2.255955349574226 ns/iter 3.059193288832978 ns/iter 0.74
JSON_Object_Defines_Miss_Same_Length 2.2391117582685047 ns/iter 3.105219980808624 ns/iter 0.72
JSON_Object_Defines_Miss_Too_Small 2.2452174726631635 ns/iter 2.9273936844677415 ns/iter 0.77
JSON_Object_Defines_Miss_Too_Large 2.263884626434333 ns/iter 3.207900555821237 ns/iter 0.71
Pointer_Object_Traverse 13.86944599327275 ns/iter 18.10107549845708 ns/iter 0.77
Pointer_Object_Try_Traverse 19.627665075961588 ns/iter 21.51311973197355 ns/iter 0.91
Pointer_Push_Back_Pointer_To_Weak_Pointer 153.9957786904729 ns/iter 157.58934008394323 ns/iter 0.98
Pointer_Walker_Schema_ISO_Language 4118671.3229813813 ns/iter 4776750.691667075 ns/iter 0.86
Schema_Frame_WoT_References 4553131.1294125235 ns/iter 4659720.911949017 ns/iter 0.98
Schema_Frame_OMC_References 25880465.78571428 ns/iter 26521900.285713077 ns/iter 0.98
Schema_Frame_OMC_Locations 23274330.645167097 ns/iter 25545527.31034368 ns/iter 0.91
Schema_Frame_ISO_Language_Locations 75345187.49997687 ns/iter 77747593.74999008 ns/iter 0.97
Schema_Frame_KrakenD_References 43766268.18749685 ns/iter 52650583.300010115 ns/iter 0.83
Schema_Frame_KrakenD_Reachable 385545625.4999581 ns/iter 463963458.00002337 ns/iter 0.83
Schema_Iterator_ISO_Language 2308002.5071634017 ns/iter 2489447.127586259 ns/iter 0.93
Schema_Frame_ISO_Language_Locations_To_JSON 88629652.83333324 ns/iter 116232108.4000041 ns/iter 0.76
Schema_Tracker_ISO_Language 30494619.047626007 ns/iter 41752999.99999425 ns/iter 0.73
Schema_Tracker_ISO_Language_To_JSON 14387898.936170228 ns/iter 27066030.083334327 ns/iter 0.53
Schema_Format_ISO_Language_To_JSON 73328229.37499373 ns/iter 110382433.59998886 ns/iter 0.66
Schema_Bundle_Meta_2020_12 1126335.5321273757 ns/iter 1992223.4373264608 ns/iter 0.57
Schema_Frame_Many_Resources_References 257646194.333347 ns/iter 372337270.5000543 ns/iter 0.69
Alterschema_Check_Readibility_ISO_Language_Set_3 141194291.60000437 ns/iter 236238041.6666762 ns/iter 0.60
Alterschema_Check_Readibility_OMC 30179936.608696472 ns/iter 39157122.52941215 ns/iter 0.77
Alterschema_Apply_Readibility_KrakenD 497821291.4999176 ns/iter 554912082.9999765 ns/iter 0.90
EditorSchema_ForEditor_EmbeddedResources 9843327.869571177 ns/iter 14609845.771935016 ns/iter 0.67
URITemplateRouter_Create 15673.347693681002 ns/iter 20261.22297024929 ns/iter 0.77
URITemplateRouter_Match 160.02725345032286 ns/iter 193.10135003498456 ns/iter 0.83
URITemplateRouterView_Restore 9830.374078948984 ns/iter 10339.089830395502 ns/iter 0.95
URITemplateRouterView_Match 112.17204763927333 ns/iter 133.1291929375155 ns/iter 0.84

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

Copy link
Copy Markdown

@github-actions github-actions bot left a comment

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: e6a0f12 Previous: 0a1cda9 Ratio
URITemplateRouter_Create 15270.368821776436 ns/iter 14719.417366530455 ns/iter 1.04
URITemplateRouter_Match 151.96795104395946 ns/iter 160.65576191785644 ns/iter 0.95
URITemplateRouterView_Restore 9387.512801611758 ns/iter 9442.407259323852 ns/iter 0.99
URITemplateRouterView_Match 140.62932529271563 ns/iter 140.9155733437928 ns/iter 1.00
EditorSchema_ForEditor_EmbeddedResources 14692262.510184914 ns/iter 14009329.460000116 ns/iter 1.05
Alterschema_Check_Readibility_ISO_Language_Set_3 224936657.33334938 ns/iter 214878863.66662678 ns/iter 1.05
Alterschema_Check_Readibility_OMC 35368163.315788 ns/iter 34925556.799998954 ns/iter 1.01
Alterschema_Apply_Readibility_KrakenD 655932363.9999093 ns/iter 605359543.999839 ns/iter 1.08
Schema_Frame_WoT_References 5401355.793893546 ns/iter 5357704.438461041 ns/iter 1.01
Schema_Frame_OMC_References 22100033.73333317 ns/iter 22104547.874995716 ns/iter 1.00
Schema_Frame_OMC_Locations 20488984.02941123 ns/iter 20480841.529406995 ns/iter 1.00
Schema_Frame_ISO_Language_Locations 105481639.49999888 ns/iter 104203631.8571523 ns/iter 1.01
Schema_Frame_KrakenD_References 43859122.64706349 ns/iter 43720787.75000432 ns/iter 1.00
Schema_Frame_KrakenD_Reachable 709923629.000059 ns/iter 624729442.9999783 ns/iter 1.14
Schema_Iterator_ISO_Language 2653849.3899610136 ns/iter 2630808.218044794 ns/iter 1.01
Schema_Frame_ISO_Language_Locations_To_JSON 335333122.5000602 ns/iter 322049217.00008523 ns/iter 1.04
Schema_Tracker_ISO_Language 33943091.05000275 ns/iter 34802490.350000426 ns/iter 0.98
Schema_Tracker_ISO_Language_To_JSON 34952880.950004324 ns/iter 37097112.100002505 ns/iter 0.94
Schema_Format_ISO_Language_To_JSON 112225107.33330183 ns/iter 114452595.50002144 ns/iter 0.98
Schema_Bundle_Meta_2020_12 1883403.8590760462 ns/iter 1908276.2322463058 ns/iter 0.99
Schema_Frame_Many_Resources_References 394926895.5000207 ns/iter 398991814.49993646 ns/iter 0.99
Pointer_Object_Traverse 47.97433937112039 ns/iter 48.17438169317119 ns/iter 1.00
Pointer_Object_Try_Traverse 24.692130133652682 ns/iter 24.6445227922046 ns/iter 1.00
Pointer_Push_Back_Pointer_To_Weak_Pointer 133.77842409984518 ns/iter 148.27685171076146 ns/iter 0.90
Pointer_Walker_Schema_ISO_Language 3922960.027322488 ns/iter 3554364.733668195 ns/iter 1.10
JSON_Array_Of_Objects_Unique 420.32823009269464 ns/iter 445.54655936606997 ns/iter 0.94
JSON_Parse_1 11806.591729918058 ns/iter 11875.043819785078 ns/iter 0.99
JSON_Parse_Real 17484.575349943392 ns/iter 17213.304914496104 ns/iter 1.02
JSON_Parse_Decimal 113761.74939719822 ns/iter 112533.86185898489 ns/iter 1.01
JSON_Parse_Schema_ISO_Language 6646982.740385546 ns/iter 6705299.952381253 ns/iter 0.99
JSON_Fast_Hash_Helm_Chart_Lock 57.293148691480894 ns/iter 63.72447073648458 ns/iter 0.90
JSON_Equality_Helm_Chart_Lock 154.54280555637627 ns/iter 154.19430122488438 ns/iter 1.00
JSON_String_Equal/10 6.286726176342279 ns/iter 6.272150354302974 ns/iter 1.00
JSON_String_Equal/100 6.891282522138038 ns/iter 6.916742737550652 ns/iter 1.00
JSON_String_Equal_Small_By_Perfect_Hash/10 0.6237924034587558 ns/iter 0.6243379417569406 ns/iter 1.00
JSON_String_Equal_Small_By_Runtime_Perfect_Hash/10 13.493689238097609 ns/iter 13.704580223185998 ns/iter 0.98
JSON_String_Fast_Hash/10 1.9461007999813795 ns/iter 1.945676341040151 ns/iter 1.00
JSON_String_Fast_Hash/100 1.9460572806252696 ns/iter 1.9437028681548065 ns/iter 1.00
JSON_String_Key_Hash/10 1.5593508645808483 ns/iter 1.5587328719367575 ns/iter 1.00
JSON_String_Key_Hash/100 12.44423638607483 ns/iter 12.433315030475883 ns/iter 1.00
JSON_Object_Defines_Miss_Same_Length 2.802352406800118 ns/iter 2.8018543393961055 ns/iter 1.00
JSON_Object_Defines_Miss_Too_Small 2.8164338214178795 ns/iter 2.8031439437943164 ns/iter 1.00
JSON_Object_Defines_Miss_Too_Large 2.8041283078340244 ns/iter 2.802935714816827 ns/iter 1.00
Regex_Lower_S_Or_Upper_S_Asterisk 3.115303747256596 ns/iter 3.11225877334634 ns/iter 1.00
Regex_Caret_Lower_S_Or_Upper_S_Asterisk_Dollar 3.1144604530448188 ns/iter 3.110888019238368 ns/iter 1.00
Regex_Period_Asterisk 3.1139470794541686 ns/iter 3.113375577471992 ns/iter 1.00
Regex_Group_Period_Asterisk_Group 3.116017212975376 ns/iter 3.110630214979844 ns/iter 1.00
Regex_Period_Plus 3.4255689949987844 ns/iter 3.426273655137044 ns/iter 1.00
Regex_Period 3.426264677078696 ns/iter 3.425260094739054 ns/iter 1.00
Regex_Caret_Period_Plus_Dollar 3.4383130179310726 ns/iter 3.4239884328931804 ns/iter 1.00
Regex_Caret_Group_Period_Plus_Group_Dollar 3.4227411069739055 ns/iter 3.4258635862296147 ns/iter 1.00
Regex_Caret_Period_Asterisk_Dollar 4.361822612467017 ns/iter 4.353494082651272 ns/iter 1.00
Regex_Caret_Group_Period_Asterisk_Group_Dollar 4.356799212949562 ns/iter 4.353625856756198 ns/iter 1.00
Regex_Caret_X_Hyphen 13.685249594172774 ns/iter 13.08301545640512 ns/iter 1.05
Regex_Period_Md_Dollar 34.84079460863527 ns/iter 36.40691027584887 ns/iter 0.96
Regex_Caret_Slash_Period_Asterisk 9.018580197961983 ns/iter 9.058819302820412 ns/iter 1.00
Regex_Caret_Period_Range_Dollar 4.356394149482165 ns/iter 3.1125145050615255 ns/iter 1.40
Regex_Nested_Backtrack 57.62736393612903 ns/iter 58.52657823860691 ns/iter 0.98

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