-
Notifications
You must be signed in to change notification settings - Fork 156
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add
MathError
for math operations (#855)
* Use only option for Memory.get * Fix some tests + refactor range_check validation * use proper error for get_memory_holes * Move MaybeRelocatable methods get_int_ref & get_reloctable to Option * Fix tests * Clippy * Fix `CairoRunner::write_output` so that it prints missing and relocatable values (#853) * Print relocatables & missing members in write_output * Add test * Move errors outputed by math_utils to MathError * Start moving relocatable operations to MathError * Fix tests * Remove math-related errors from vm error * Move conversion errors to MathError * Move type conversions to MathError * Remove unused errors * Clippy * Clippy * Simplify addition * Simplify addition * Clippy * Add math_errors.rs * Check for overflows in relocatable operations (#859) * Catch possible overflows in Relocatable::add * Move sub implementations to trait impl * Swap sub_usize for - operator * Vheck possible overflows in Add<i32> * Fix should_panic test * remove referenced add * Replace Relocatable methods for trait implementations * Catch overflows in mayberelocatable operations * Fix keccak * Clippy
- Loading branch information
Showing
37 changed files
with
446 additions
and
466 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
1de3e2b
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Possible performance regression was detected for benchmark.
Benchmark result of this commit is worse than the previous benchmark result exceeding threshold
1.30
.cairo_run(cairo_programs/benchmarks/compare_arrays_200000.json)
884503786
ns/iter (± 28972997
)637231489
ns/iter (± 1969874
)1.39
cairo_run(cairo_programs/benchmarks/factorial_multirun.json)
329271401
ns/iter (± 12461198
)240630877
ns/iter (± 664836
)1.37
cairo_run(cairo_programs/benchmarks/fibonacci_1000_multirun.json)
139728837
ns/iter (± 7714931
)101045574
ns/iter (± 351582
)1.38
cairo_run(cairo_programs/benchmarks/integration_builtins.json)
537004106
ns/iter (± 23605098
)386937505
ns/iter (± 1718909
)1.39
cairo_run(cairo_programs/benchmarks/linear_search.json)
103559057
ns/iter (± 6181470
)79573059
ns/iter (± 5279566
)1.30
cairo_run(cairo_programs/benchmarks/keccak_integration_benchmark.json)
1682060789
ns/iter (± 48924206
)1240800087
ns/iter (± 8607617
)1.36
cairo_run(cairo_programs/benchmarks/secp_integration_benchmark.json)
1869022503
ns/iter (± 80441664
)1348564409
ns/iter (± 2660517
)1.39
cairo_run(cairo_programs/benchmarks/blake2s_integration_benchmark.json)
1534652558
ns/iter (± 71555462
)1082080349
ns/iter (± 8505744
)1.42
cairo_run(cairo_programs/benchmarks/dict_integration_benchmark.json)
1000563302
ns/iter (± 32632253
)757723182
ns/iter (± 8971950
)1.32
cairo_run(cairo_programs/benchmarks/math_integration_benchmark.json)
493033960
ns/iter (± 24944368
)377129902
ns/iter (± 871064
)1.31
cairo_run(cairo_programs/benchmarks/math_cmp_and_pow_integration_benchmark.json)
23903260
ns/iter (± 1455740
)18089601
ns/iter (± 107357
)1.32
cairo_run(cairo_programs/benchmarks/operations_with_data_structures_benchmarks.json)
2213835247
ns/iter (± 67634907
)1610375764
ns/iter (± 30312668
)1.37
cairo_run(cairo_programs/benchmarks/uint256_integration_benchmark.json)
1502525606
ns/iter (± 61358205
)1081656715
ns/iter (± 3755716
)1.39
cairo_run(cairo_programs/benchmarks/set_integration_benchmark.json)
169453151
ns/iter (± 10920855
)121522873
ns/iter (± 418889
)1.39
This comment was automatically generated by workflow using github-action-benchmark.
CC: @unbalancedparentheses