Bump LLVM #1381
Closed
FrancoGiachetta wants to merge 19 commits intomainfrom
Closed
Conversation
|
✅ Code is now correctly formatted. |
Benchmarking resultsBenchmark for program
|
| Command | Mean [s] | Min [s] | Max [s] | Relative |
|---|---|---|---|---|
Cairo-vm (Rust, Cairo 1) |
10.336 ± 0.058 | 10.265 | 10.450 | 4.27 ± 0.05 |
cairo-native (embedded AOT) |
2.418 ± 0.027 | 2.386 | 2.458 | 1.00 |
cairo-native (embedded JIT using LLVM's ORC Engine) |
2.481 ± 0.015 | 2.467 | 2.508 | 1.03 ± 0.01 |
Benchmark for program dict_snapshot
Open benchmarks
| Command | Mean [ms] | Min [ms] | Max [ms] | Relative |
|---|---|---|---|---|
Cairo-vm (Rust, Cairo 1) |
512.5 ± 6.5 | 505.1 | 525.6 | 1.00 |
cairo-native (embedded AOT) |
2109.5 ± 17.0 | 2093.9 | 2145.6 | 4.12 ± 0.06 |
cairo-native (embedded JIT using LLVM's ORC Engine) |
2208.5 ± 20.7 | 2197.6 | 2266.1 | 4.31 ± 0.07 |
Benchmark for program factorial_2M
Open benchmarks
| Command | Mean [s] | Min [s] | Max [s] | Relative |
|---|---|---|---|---|
Cairo-vm (Rust, Cairo 1) |
4.615 ± 0.033 | 4.580 | 4.681 | 1.82 ± 0.02 |
cairo-native (embedded AOT) |
2.530 ± 0.024 | 2.497 | 2.575 | 1.00 |
cairo-native (embedded JIT using LLVM's ORC Engine) |
2.560 ± 0.010 | 2.542 | 2.575 | 1.01 ± 0.01 |
Benchmark for program fib_2M
Open benchmarks
| Command | Mean [s] | Min [s] | Max [s] | Relative |
|---|---|---|---|---|
Cairo-vm (Rust, Cairo 1) |
4.527 ± 0.086 | 4.465 | 4.753 | 2.19 ± 0.04 |
cairo-native (embedded AOT) |
2.069 ± 0.015 | 2.058 | 2.108 | 1.00 |
cairo-native (embedded JIT using LLVM's ORC Engine) |
2.113 ± 0.011 | 2.090 | 2.127 | 1.02 ± 0.01 |
Benchmark for program linear_search
Open benchmarks
| Command | Mean [ms] | Min [ms] | Max [ms] | Relative |
|---|---|---|---|---|
Cairo-vm (Rust, Cairo 1) |
558.0 ± 7.9 | 550.5 | 575.3 | 1.00 |
cairo-native (embedded AOT) |
2154.9 ± 40.7 | 2111.9 | 2243.2 | 3.86 ± 0.09 |
cairo-native (embedded JIT using LLVM's ORC Engine) |
2270.4 ± 25.8 | 2247.3 | 2337.5 | 4.07 ± 0.07 |
Benchmark for program logistic_map
Open benchmarks
| Command | Mean [ms] | Min [ms] | Max [ms] | Relative |
|---|---|---|---|---|
Cairo-vm (Rust, Cairo 1) |
369.9 ± 6.3 | 363.8 | 382.7 | 1.00 |
cairo-native (embedded AOT) |
2218.2 ± 7.9 | 2205.9 | 2230.1 | 6.00 ± 0.10 |
cairo-native (embedded JIT using LLVM's ORC Engine) |
2402.1 ± 24.3 | 2371.0 | 2446.9 | 6.49 ± 0.13 |
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Bump LLVM
Closes #1378
This PR bumps LLVM to LLVM 20. To do this, the following crates updated:
Many of this changes are due to some refactors in melior. It seems to have split some block and region operation into the traits:
BlockLike,RegionLike,AttributLikeandOperationLike.LLVM 20 introduces a breaking change. Operations which take more than one group of variadic operands then the user to specify the amount of operands (for each group) it is receiving through the attribute
operandSegmentSizes. Due to this, ourllvm.calloperations started to fail. You may want to check its TableGen definition here.To avoid having to specify in each of these operations this new attribute by hand, I created a new function
llvm_callinsideutils/operation_ext.rs. It wraps theOperationBuilderand calculates the operandSegmentSizes based on the arguments length.Lastly, the firm of the function
mlirLLVMDISubprogramAttrGetchanged a little:There were added 6 new parameters:
The first two are for specifying that the
DISubprogramAttrsupports recursive reference to itself. The last four are to specify metadata for the subprogram.PR for sequencer: lambdaclass/sequencer#76
PR for starknet-replay: starkware-libs/starknet-replay#189
PD: the benches comparison workflow will fail since main still uses llvm 19.
Introduces Breaking Changes?
Yes
starknet-blocks.ymlworkflow to use these PRs.These PRs should be merged after this one right away, in that order.
Checklist