Skip to content

Conversation

@PavelKopyl
Copy link
Contributor

Code Review Checklist

Purpose

Ticket Number

Requirements

  • Have the requirements been met?
  • Have stakeholder(s) approved the change?

Implementation

  • Does this code change accomplish what it is supposed to do?
  • Can this solution be simplified?
  • Does this change add unwanted compile-time or run-time dependencies?
  • Could an additional framework, API, library, or service improve the solution?
  • Could we reuse part of LLVM instead of implementing the patch or a part of it?
  • Is the code at the right abstraction level?
  • Is the code modular enough?
  • Can a better solution be found in terms of maintainability, readability, performance, or security?
  • Does similar functionality already exist in the codebase? If yes, why isn’t it reused?
  • Are there any best practices, design patterns or language-specific patterns that could substantially improve this code?

Logic Errors and Bugs

  • Can you think of any use case in which the
    code does not behave as intended?
  • Can you think of any inputs or external events
    that could break the code?

Error Handling and Logging

  • Is error handling done the correct way?
  • Should any logging or debugging information
    be added or removed?
  • Are error messages user-friendly?
  • Are there enough log events and are they
    written in a way that allows for easy
    debugging?

Maintainability

  • Is the code easy to read?
  • Is the code not repeated (DRY Principle)?
  • Is the code method/class not too long?

Dependencies

  • Were updates to documentation, configuration, or readme files made as required by this change?
  • Are there any potential impacts on other parts of the system or backward compatibility?

Security

  • Does the code introduce any security vulnerabilities?

Performance

  • Do you think this code change decreases
    system performance?
  • Do you see any potential to improve the
    performance of the code significantly?

Testing and Testability

  • Is the code testable?
  • Have automated tests been added, or have related ones been updated to cover the change?
    • For changes to mutable state
  • Do tests reasonably cover the code change (unit/integration/system tests)?
    • Line Coverage
    • Region Coverage
    • Branch Coverage
  • Are there some test cases, input or edge cases
    that should be tested in addition?

Readability

  • Is the code easy to understand?
  • Which parts were confusing to you and why?
  • Can the readability of the code be improved by
    smaller methods?
  • Can the readability of the code be improved by
    different function, method or variable names?
  • Is the code located in the right
    file/folder/package?
  • Do you think certain methods should be
    restructured to have a more intuitive control
    flow?
  • Is the data flow understandable?
  • Are there redundant or outdated comments?
  • Could some comments convey the message
    better?
  • Would more comments make the code more
    understandable?
  • Could some comments be removed by making the code itself more readable?
  • Is there any commented-out code?
  • Have you run a spelling and grammar checker?

Documentation

  • Is there sufficient documentation?
  • Is the ReadMe.md file up to date?

Best Practices

  • Follow Single Responsibility principle?
  • Are different errors handled correctly?
  • Are errors and warnings logged?
  • Magic values avoided?
  • No unnecessary comments?
  • Minimal nesting used?

Experts' Opinion

  • Do you think a specific expert, like a security
    expert or a usability expert, should look over
    the code before it can be accepted?
  • Will this code change impact different teams, and should they review the change as well?

@PavelKopyl PavelKopyl marked this pull request as draft September 2, 2025 11:17
@github-actions
Copy link

github-actions bot commented Sep 2, 2025

Results for: evm ir-llvm EVMInterpreter
╔═╡ Size (-%) ╞═══════════════════════╡ All E +M3B3 ╞═╗
║ Best                                          6.096 ║
║ Worst                                        -0.364 ║
║ Total                                         0.058 ║
╠═╡ Cycles (-%) ╞═════════════════════╡ All E +M3B3 ╞═╣
║ Best                                          3.580 ║
║ Worst                                        -3.572 ║
║ Total                                        -0.003 ║
╠═╡ Ergs (-%) ╞═══════════════════════╡ All E +M3B3 ╞═╣
║ Best                                          4.326 ║
║ Worst                                        -3.351 ║
║ Total                                        -0.001 ║
╠══╡ Gas (-%) ╞═══════════════════════╡ All E +M3B3 ╞═╣
║ Best                                          6.137 ║
║ Worst                                        -2.757 ║
║ Total                                         0.000 ║
╚═════════════════════════════════════════════════════╝

╔═╡ Size (-%) ╞═══════════════════════╡ All E +MzB3 ╞═╗
║ Best                                          1.435 ║
║ Worst                                        -0.400 ║
║ Total                                         0.011 ║
╠═╡ Cycles (-%) ╞═════════════════════╡ All E +MzB3 ╞═╣
║ Best                                          0.964 ║
║ Worst                                        -3.686 ║
║ Total                                        -0.000 ║
╠═╡ Ergs (-%) ╞═══════════════════════╡ All E +MzB3 ╞═╣
║ Best                                          1.255 ║
║ Worst                                        -0.913 ║
║ Total                                         0.000 ║
╠══╡ Gas (-%) ╞═══════════════════════╡ All E +MzB3 ╞═╣
║ Best                                          1.447 ║
║ Worst                                        -2.809 ║
║ Total                                         0.000 ║
╚═════════════════════════════════════════════════════╝

╔═╡ Size (-%) ╞═══════════════════════╡ All Y +M3B3 ╞═╗
║ Best                                         26.819 ║
║ Worst                                         0.000 ║
║ Total                                         0.293 ║
╠═╡ Cycles (-%) ╞═════════════════════╡ All Y +M3B3 ╞═╣
║ Best                                         11.017 ║
║ Worst                                        -7.271 ║
║ Total                                        -0.005 ║
╠═╡ Ergs (-%) ╞═══════════════════════╡ All Y +M3B3 ╞═╣
║ Best                                         14.421 ║
║ Worst                                        -6.264 ║
║ Total                                         0.003 ║
╠══╡ Gas (-%) ╞═══════════════════════╡ All Y +M3B3 ╞═╣
║ Best                                         27.183 ║
║ Worst                                        -6.383 ║
║ Total                                         0.000 ║
╚═════════════════════════════════════════════════════╝

╔═╡ Size (-%) ╞═══════════════════════╡ All Y +MzB3 ╞═╗
║ Best                                          4.644 ║
║ Worst                                         0.000 ║
║ Total                                         0.061 ║
╠═╡ Cycles (-%) ╞═════════════════════╡ All Y +MzB3 ╞═╣
║ Best                                          4.968 ║
║ Worst                                        -3.610 ║
║ Total                                         0.003 ║
╠═╡ Ergs (-%) ╞═══════════════════════╡ All Y +MzB3 ╞═╣
║ Best                                          4.617 ║
║ Worst                                        -0.792 ║
║ Total                                         0.004 ║
╠══╡ Gas (-%) ╞═══════════════════════╡ All Y +MzB3 ╞═╣
║ Best                                          5.626 ║
║ Worst                                        -2.174 ║
║ Total                                         0.000 ║
╚═════════════════════════════════════════════════════╝

╔═╡ Size (-%) ╞═════════════════╡ Real life E +M3B3 ╞═╗
║ Best                                          1.751 ║
║ Worst                                         0.000 ║
║ Total                                         0.416 ║
╠═╡ Cycles (-%) ╞═══════════════╡ Real life E +M3B3 ╞═╣
║ Best                                          0.995 ║
║ Worst                                         0.000 ║
║ Total                                         0.071 ║
╠═╡ Ergs (-%) ╞═════════════════╡ Real life E +M3B3 ╞═╣
║ Best                                          1.258 ║
║ Worst                                         0.000 ║
║ Total                                         0.198 ║
╠══╡ Gas (-%) ╞═════════════════╡ Real life E +M3B3 ╞═╣
║ Best                                          1.879 ║
║ Worst                                         0.000 ║
║ Total                                         0.552 ║
╚═════════════════════════════════════════════════════╝

╔═╡ Size (-%) ╞═════════════════╡ Real life E +MzB3 ╞═╗
║ Best                                          0.773 ║
║ Worst                                         0.000 ║
║ Total                                         0.169 ║
╠═╡ Cycles (-%) ╞═══════════════╡ Real life E +MzB3 ╞═╣
║ Best                                          0.718 ║
║ Worst                                         0.000 ║
║ Total                                         0.074 ║
╠═╡ Ergs (-%) ╞═════════════════╡ Real life E +MzB3 ╞═╣
║ Best                                          0.933 ║
║ Worst                                         0.000 ║
║ Total                                         0.141 ║
╠══╡ Gas (-%) ╞═════════════════╡ Real life E +MzB3 ╞═╣
║ Best                                          0.814 ║
║ Worst                                         0.000 ║
║ Total                                         0.220 ║
╚═════════════════════════════════════════════════════╝

╔═╡ Size (-%) ╞═════════════════╡ Real life Y +M3B3 ╞═╗
║ Best                                          1.904 ║
║ Worst                                         0.000 ║
║ Total                                         0.816 ║
╠═╡ Cycles (-%) ╞═══════════════╡ Real life Y +M3B3 ╞═╣
║ Best                                          1.395 ║
║ Worst                                        -3.338 ║
║ Total                                         0.057 ║
╠═╡ Ergs (-%) ╞═════════════════╡ Real life Y +M3B3 ╞═╣
║ Best                                          1.521 ║
║ Worst                                        -0.772 ║
║ Total                                         0.385 ║
╠══╡ Gas (-%) ╞═════════════════╡ Real life Y +M3B3 ╞═╣
║ Best                                          1.977 ║
║ Worst                                        -0.656 ║
║ Total                                         0.902 ║
╚═════════════════════════════════════════════════════╝

╔═╡ Size (-%) ╞═════════════════╡ Real life Y +MzB3 ╞═╗
║ Best                                          1.321 ║
║ Worst                                         0.000 ║
║ Total                                         0.646 ║
╠═╡ Cycles (-%) ╞═══════════════╡ Real life Y +MzB3 ╞═╣
║ Best                                          0.775 ║
║ Worst                                        -3.610 ║
║ Total                                         0.059 ║
╠═╡ Ergs (-%) ╞═════════════════╡ Real life Y +MzB3 ╞═╣
║ Best                                          0.972 ║
║ Worst                                        -0.792 ║
║ Total                                         0.259 ║
╠══╡ Gas (-%) ╞═════════════════╡ Real life Y +MzB3 ╞═╣
║ Best                                          1.305 ║
║ Worst                                        -0.650 ║
║ Total                                         0.651 ║
╚═════════════════════════════════════════════════════╝

@codecov
Copy link

codecov bot commented Sep 2, 2025

Codecov Report

❌ Patch coverage is 93.44262% with 8 lines in your changes missing coverage. Please review.
✅ Project coverage is 30.01%. Comparing base (f26f9ce) to head (3a2fa00).

Files with missing lines Patch % Lines
llvm/lib/Target/EVM/EVMCalculateModuleSize.cpp 0.00% 1 Missing and 1 partial ⚠️
llvm/lib/Target/EVM/EVMConstantUnfolding.cpp 96.61% 0 Missing and 2 partials ⚠️
llvm/lib/Target/EVM/EVMFinalizeStackFrames.cpp 85.71% 1 Missing and 1 partial ⚠️
llvm/lib/Target/EVM/EVMConstantSpiller.cpp 97.67% 0 Missing and 1 partial ⚠️
llvm/lib/Target/EVM/EVMTargetMachine.cpp 75.00% 0 Missing and 1 partial ⚠️
Additional details and impacted files
@@             Coverage Diff             @@
##             main     #885       +/-   ##
===========================================
- Coverage   30.94%   30.01%    -0.94%     
===========================================
  Files        2430     2431        +1     
  Lines      806322   704192   -102130     
  Branches   176496   176519       +23     
===========================================
- Hits       249490   211330    -38160     
+ Misses     512928   448950    -63978     
- Partials    43904    43912        +8     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@PavelKopyl PavelKopyl force-pushed the kpv-spill-big-constants branch 2 times, most recently from f14e6fc to 293b9ef Compare September 2, 2025 22:55
@github-actions
Copy link

github-actions bot commented Sep 3, 2025

📊 Excel Report Available

Benchmarks measured for:

  • solx candidate version: solx, LLVM-based Solidity compiler for the EVM v0.1.3, LLVM revision: v1.0.2, LLVM build: 3a2fa000f08d4c51a993d73797b679a1ea3f6ab6
  • solx ToT version: solx, LLVM-based Solidity compiler for the EVM v0.1.3, LLVM revision: v1.0.2, LLVM build: f26f9cea62dc5a8e228c0c211309ae222704ded4
  • solx latest release version: solx, LLVM-based Solidity compiler for the EVM v0.1.2, LLVM revision: v1.0.2, LLVM build: aec023355f43d8ece02249360ba84e749fb5cb3f
  • solc version: 0.8.30

➡️ Download Excel Report

@PavelKopyl PavelKopyl force-pushed the kpv-spill-big-constants branch from 293b9ef to fc6d80a Compare September 3, 2025 00:26
@github-actions
Copy link

github-actions bot commented Sep 3, 2025

✅ With the latest revision this PR passed the C/C++ code formatter.

@PavelKopyl PavelKopyl force-pushed the kpv-spill-big-constants branch 2 times, most recently from 2dd2ebb to c4fb743 Compare September 7, 2025 17:01
@PavelKopyl PavelKopyl force-pushed the kpv-spill-big-constants branch from c4fb743 to a5d2fa1 Compare September 15, 2025 08:48
@PavelKopyl PavelKopyl force-pushed the kpv-spill-big-constants branch from a5d2fa1 to 91de0ee Compare October 3, 2025 18:34
@github-actions
Copy link

github-actions bot commented Oct 3, 2025

📊 evm compiler-tester excel report

Benchmarks measured for:

  • target machine: evm
  • toolchain: ir-llvm
  • environment: REVM

➡️ Download Excel Report

@github-actions
Copy link

github-actions bot commented Oct 3, 2025

Project Mode Compiled (solc / solx / Total) Passed (solc / solx / Total)
openzeppelin default 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 382 / 382 / 382 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 328 / 328 / 330
viaIR 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 382 / 382 / 382 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 328 / 328 / 330
lil-web3 default 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 20 / 20 / 20 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 68 / 68 / 68
viaIR 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 20 / 20 / 20 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 66 / 68 / 68
maple-erc20 default 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 28 / 28 / 28 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 29 / 29 / 29
viaIR 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 28 / 28 / 28 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 29 / 29 / 29
diamonds default 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 17 / 17 / 17 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 1 / 1 / 1
viaIR 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 17 / 17 / 17 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 1 / 1 / 1
rollcall default 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 64 / 64 / 64 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 14 / 14 / 14
viaIR 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 64 / 64 / 64 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 14 / 14 / 14
playpen default 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 43 / 43 / 43 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 6 / 6 / 9
viaIR 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 43 / 43 / 43 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 6 / 6 / 9
solmate default 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 60 / 60 / 60 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 55 / 55 / 69
viaIR 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 60 / 60 / 60 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 55 / 55 / 69
prb-math default 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 106 / 106 / 106 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 323 / 323 / 323
viaIR 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 106 / 106 / 106 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 323 / 323 / 323
solady default 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 208 / 208 / 208 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 1571 / 1571 / 1571
viaIR 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 208 / 208 / 208 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 1571 / 1571 / 1571
unix default 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 21 / 21 / 21 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 2 / 2 / 3
viaIR 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 21 / 21 / 21 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 0 / 2 / 0
foundry-upgrades default 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 22 / 22 / 22 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 3 / 3 / 3
viaIR 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 22 / 22 / 22 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 3 / 3 / 3
art-gobblers default 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 56 / 56 / 56 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 127 / 127 / 127
viaIR 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 56 / 56 / 56 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 121 / 121 / 127
lens-core default 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 320 / 320 / 320 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 0 / 1876 / 0
viaIR 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 320 / 320 / 320 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 0 / 1877 / 0
balance-snapshot default 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 20 / 20 / 20 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 5 / 5 / 5
viaIR 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 20 / 20 / 20 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 5 / 5 / 5
diamond-foundry default 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 26 / 26 / 26 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 40 / 40 / 44
viaIR 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 26 / 26 / 26 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 40 / 40 / 44
forge-std default 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 50 / 50 / 50 ⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜ 194 / 0 / 194
viaIR 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 50 / 50 / 50 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 194 / 194 / 194
tokenlon default 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 121 / 121 / 121 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 53 / 53 / 67
viaIR 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 121 / 121 / 121 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 53 / 53 / 67
uniswap-v4 default 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 160 / 160 / 160 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 598 / 598 / 598
viaIR 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 160 / 160 / 160 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 598 / 598 / 598
beefy default 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 164 / 164 / 164 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 2 / 2 / 34
viaIR 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 164 / 164 / 164 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 2 / 2 / 34
gov-of-venice default 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 25 / 25 / 25 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 25 / 25 / 26
viaIR 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 25 / 25 / 25 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 24 / 25 / 26
cicada default 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 23 / 23 / 23 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 0 / 546 / 0
viaIR 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 23 / 23 / 23 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 0 / 546 / 0
lens-v3 default 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 240 / 240 / 240 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 656 / 656 / 657
viaIR 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 240 / 240 / 240 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 0 / 656 / 0
morpho-blue default 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 74 / 74 / 74 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 145 / 145 / 145
viaIR 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 74 / 74 / 74 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 145 / 145 / 145
aave-v3 default 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 473 / 473 / 473 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 980 / 980 / 980
viaIR 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 473 / 473 / 473 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 979 / 980 / 980

@github-actions
Copy link

github-actions bot commented Oct 3, 2025

Project Mode Compile (solx/solc/Δs/Δ%) Run (solx/solc/Δs/Δ%) Size warnings (solx/solc)
openzeppelin default 14.17s / 18.58s / -4.40s / -24% 📉 2.51s / 2.84s / -0.32s / -11% 📉 2 / 3
viaIR 15.12s / 59.66s / -44.55s / -75% 📉 2.48s / 3.23s / -0.75s / -23% 📉 2 / 3
lil-web3 default 2.56s / 2.36s / +0.20s / +9% 📈 0.15s / 0.15s / -0.00s / -1% ➖ 0 / 0
viaIR 2.16s / 10.50s / -8.34s / -79% 📉 0.15s / 0.15s / +0.00s / +1% ➖ 1 / 1
maple-erc20 default 2.19s / 1.75s / +0.44s / +25% 📈 0.16s / 0.16s / +0.00s / +1% ➖ 0 / 0
viaIR 1.83s / 5.02s / -3.19s / -64% 📉 0.16s / 0.16s / +0.00s / +2% ➖ 0 / 0
diamonds default 2.05s / 0.99s / +1.05s / +106% 📈 0.52s / 0.48s / +0.04s / +7% 📈 0 / 0
viaIR 1.62s / 2.71s / -1.09s / -40% 📉 0.50s / 0.49s / +0.02s / +3% ➖ 0 / 0
rollcall default 2.65s / 2.83s / -0.18s / -6% 📉 0.15s / 0.15s / +0.01s / +4% ➖ 0 / 2
viaIR 2.37s / 10.23s / -7.86s / -77% 📉 0.15s / 0.15s / +0.00s / +1% ➖ 1 / 2
playpen default 2.55s / 1.84s / +0.71s / +39% 📈 0.17s / 0.17s / +0.00s / +0% ➖ 0 / 6
viaIR 2.11s / 7.28s / -5.18s / -71% 📉 0.17s / 0.17s / +0.00s / +2% ➖ 0 / 6
solmate default 8.67s / 5.73s / +2.94s / +51% 📈 0.13s / 0.13s / +0.00s / +2% ➖ 2 / 7
viaIR 5.30s / 32.60s / -27.29s / -84% 📉 0.13s / 0.13s / +0.00s / +3% ➖ 4 / 9
prb-math default 6.22s / 6.66s / -0.44s / -7% 📉 0.16s / 0.15s / +0.01s / +7% 📈 0 / 0
viaIR 7.62s / 31.08s / -23.46s / -75% 📉 0.16s / 0.15s / +0.00s / +1% ➖ 0 / 0
solady default 21.17s / 26.38s / -5.21s / -20% 📉 0.66s / 0.68s / -0.02s / -3% ➖ 19 / 21
viaIR 20.31s / 159.30s / -138.99s / -87% 📉 0.67s / 0.68s / -0.01s / -1% ➖ 25 / 23
unix default 2.56s / 1.60s / +0.96s / +60% 📈 0.19s / 0.19s / +0.00s / +1% ➖ 0 / 1
viaIR 2.00s / 4.31s / -2.31s / -54% 📉 0.18s / 0.23s / -0.05s / -23% 📉 0 / 0
foundry-upgrades default 1.24s / 0.94s / +0.30s / +31% 📈 0.16s / 0.16s / +0.01s / +3% ➖ 0 / 0
viaIR 1.04s / 2.68s / -1.65s / -61% 📉 0.16s / 0.16s / -0.00s / -1% ➖ 0 / 0
art-gobblers default 8.34s / 4.70s / +3.64s / +77% 📈 0.62s / 0.72s / -0.09s / -13% 📉 1 / 19
viaIR 6.44s / 26.48s / -20.04s / -76% 📉 0.61s / 0.69s / -0.08s / -12% 📉 1 / 22
lens-core default 110.42s / 11.69s / +98.73s / +845% 📈 3.33s / 14.19s / -10.87s / -77% 📉 85 / 0
viaIR 73.08s / 524.10s / -451.02s / -86% 📉 3.36s / 525.96s / -522.60s / -99% 📉 83 / 0
balance-snapshot default 2.26s / 0.92s / +1.33s / +144% 📈 0.14s / 0.13s / +0.01s / +9% 📈 0 / 0
viaIR 1.86s / 2.86s / -1.00s / -35% 📉 0.14s / 0.14s / +0.01s / +5% 📈 0 / 0
diamond-foundry default 3.27s / 2.36s / +0.92s / +39% 📈 0.16s / 0.15s / +0.01s / +5% ➖ 0 / 1
viaIR 2.00s / 6.90s / -4.90s / -71% 📉 0.16s / 0.14s / +0.02s / +11% 📈 0 / 0
forge-std default 10.47s / 8.34s / +2.13s / +26% 📈 23.38s / 31.79s / -8.41s / -26% 📉 7 / 7
viaIR 7.28s / 41.78s / -34.50s / -83% 📉 22.71s / 22.74s / -0.03s / -0% ➖ 8 / 8
tokenlon default 18.70s / 20.27s / -1.58s / -8% 📉 0.27s / 0.28s / -0.01s / -3% ➖ 9 / 26
viaIR 12.51s / 102.46s / -89.95s / -88% 📉 0.26s / 0.26s / -0.00s / -1% ➖ 11 / 28
uniswap-v4 default 22.66s / 18.92s / +3.74s / +20% 📈 2.76s / 2.78s / -0.02s / -1% ➖ 4 / 33
viaIR 16.96s / 107.88s / -90.92s / -84% 📉 2.79s / 2.77s / +0.02s / +1% ➖ 7 / 35
beefy default 15.50s / 20.00s / -4.49s / -22% 📉 0.20s / 0.19s / +0.01s / +4% ➖ 14 / 27
viaIR 13.04s / 99.75s / -86.70s / -87% 📉 0.21s / 0.20s / +0.01s / +6% 📈 15 / 26
gov-of-venice default 5.11s / 3.57s / +1.54s / +43% 📈 0.46s / 0.59s / -0.14s / -23% 📉 2 / 10
viaIR 3.48s / 25.78s / -22.30s / -87% 📉 0.49s / 0.58s / -0.09s / -16% 📉 2 / 10
lens-v3 default 75.22s / 47.85s / +27.37s / +57% 📈 0.40s / 0.42s / -0.02s / -5% ➖ 32 / 60
viaIR 45.44s / 10.22s / +35.22s / +345% 📈 0.39s / 9.98s / -9.59s / -96% 📉 33 / 0
morpho-blue default 9.47s / 11.60s / -2.13s / -18% 📉 0.20s / 0.20s / +0.00s / +1% ➖ 6 / 34
viaIR 7.77s / 65.88s / -58.11s / -88% 📉 0.19s / 0.19s / -0.00s / -2% ➖ 9 / 33
aave-v3 default 237.42s / 128.82s / +108.60s / +84% 📈 0.73s / 0.74s / -0.00s / -0% ➖ 80 / 164
viaIR 139.19s / 1087.16s / -947.98s / -87% 📉 0.80s / 0.84s / -0.05s / -5% 📉 84 / 164

@PavelKopyl PavelKopyl force-pushed the kpv-spill-big-constants branch 6 times, most recently from 5a40615 to 7098b6d Compare October 20, 2025 19:05
@PavelKopyl PavelKopyl force-pushed the kpv-spill-big-constants branch from 7098b6d to 9c8da3c Compare October 27, 2025 10:33
…pipeline

This allows other passes to modify or adjust frame indexes before finalization.
The constant spilling mechanism is divided between two components:

  - ConstantUnfolder
    Determines which constants are profitable to spill. For these constants,
    it emits codegen-only 'IMM_RELOAD Imm' instructions.
  - ConstantSpiller
    Inserts spills at the beginning of the entry machine function and replaces
    IMM_RELOAD instructions with the actual reloads. It also calculates the
    required size of the constants’ spill area in the heap. ConstantSpiller
    is called from EVMFinalizeStackFrames so that the actual offsets to the
    spill area can be computed.
@PavelKopyl PavelKopyl force-pushed the kpv-spill-big-constants branch from 9c8da3c to 3a2fa00 Compare October 27, 2025 12:42
@PavelKopyl PavelKopyl requested a review from akiramenai October 27, 2025 12:42
@PavelKopyl PavelKopyl marked this pull request as ready for review October 27, 2025 14:49
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