Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Compile out assertions that would never run anyway #1099

Merged
merged 1 commit into from
Sep 2, 2024

Conversation

jviotti
Copy link
Member

@jviotti jviotti commented Sep 2, 2024

Signed-off-by: Juan Cruz Viotti [email protected]

@jviotti jviotti marked this pull request as draft September 2, 2024 22:09
@jviotti jviotti marked this pull request as ready for review September 2, 2024 22:12
Copy link

@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)

Benchmark suite Current: d2cfc25 Previous: b29de65 Ratio
JSONSchema_Compile_Basic 196918.2077308039 ns/iter 204049.65753429395 ns/iter 0.97
JSONSchema_Validate_Draft4_Meta_1_No_Callback 1606.859773199492 ns/iter 1599.5496768072023 ns/iter 1.00
JSONSchema_Validate_Draft4_Required_Properties 2395.498357870798 ns/iter 2401.6238914099445 ns/iter 1.00
JSONSchema_Validate_Draft4_Optional_Properties_Minimal_Match 167.17768345687884 ns/iter 165.32197851504478 ns/iter 1.01
JSONSchema_Validate_Draft4_Items_Schema 9088.450663087695 ns/iter 8964.991558762851 ns/iter 1.01

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

Copy link

@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)

Benchmark suite Current: d2cfc25 Previous: b29de65 Ratio
JSONSchema_Compile_Basic 396216.75084937195 ns/iter 391864.60775620455 ns/iter 1.01
JSONSchema_Validate_Draft4_Meta_1_No_Callback 16654.83669645464 ns/iter 16650.35405617414 ns/iter 1.00
JSONSchema_Validate_Draft4_Required_Properties 8183.919376224563 ns/iter 8208.450116630971 ns/iter 1.00
JSONSchema_Validate_Draft4_Optional_Properties_Minimal_Match 1572.4884692315559 ns/iter 1563.5008376216072 ns/iter 1.01
JSONSchema_Validate_Draft4_Items_Schema 105409.17920985755 ns/iter 109444.21641678351 ns/iter 0.96

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

Copy link

@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)

Benchmark suite Current: d2cfc25 Previous: b29de65 Ratio
JSONSchema_Validate_Draft4_Meta_1_No_Callback 2198.8636934553 ns/iter 2285.514874075199 ns/iter 0.96
JSONSchema_Validate_Draft4_Required_Properties 2744.6906085371575 ns/iter 2846.202824670392 ns/iter 0.96
JSONSchema_Validate_Draft4_Optional_Properties_Minimal_Match 205.14976737143937 ns/iter 212.87328586916013 ns/iter 0.96
JSONSchema_Validate_Draft4_Items_Schema 11876.08085733133 ns/iter 11551.45066766161 ns/iter 1.03
JSONSchema_Compile_Basic 385607.1988950376 ns/iter 386650.7541436813 ns/iter 1.00

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

Copy link

@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)

Benchmark suite Current: d2cfc25 Previous: b29de65 Ratio
JSONSchema_Compile_Basic 801974.2187500409 ns/iter 787890.9598212199 ns/iter 1.02
JSONSchema_Validate_Draft4_Meta_1_No_Callback 4689.305357142563 ns/iter 4647.183832524478 ns/iter 1.01
JSONSchema_Validate_Draft4_Required_Properties 3985.6635044647046 ns/iter 3760.838284216279 ns/iter 1.06
JSONSchema_Validate_Draft4_Optional_Properties_Minimal_Match 772.943749999858 ns/iter 780.9710937500824 ns/iter 0.99
JSONSchema_Validate_Draft4_Items_Schema 25129.442857137616 ns/iter 26074.427958865337 ns/iter 0.96

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

@jviotti jviotti changed the title Compile out assertions that are obviously invalid Compile out assertions that would never run anyway Sep 2, 2024
@jviotti jviotti merged commit 1abf1db into main Sep 2, 2024
12 checks passed
@jviotti jviotti deleted the impossible-type-assertions branch September 2, 2024 22:22
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