Commit Graph
15 Commits
Author SHA1 Message Date
kvpanchandLJ 1308b446f1 Update LLVM 22 to ca0698598261 and remove LLVM patches (#510)
Co-authored-by: LJ <81748770+elle-j@users.noreply.github.com>
2026-04-29 13:47:34 -04:00
kvpanch 8326aa3aed Update LLVM from 21 to 22 (#505) 2026-04-28 14:28:14 -04:00
kvpanch b3cd402549 Append optnone and noinline for -O0 optlevel (#502)
This appears to be NFC change as new pass manager handles
--passes=default<O0> correctly. Still must be useful as a safeguard and
possibly for the old pass manager that is still used by backend.

```
Contract                        Without (bytes)   With noinline+optnone (bytes)
─────────────────────────────── ───────────────── ────────────────────────────
contract.sol:C                            1,266                          1,266
Fibonacci:Iterative                       2,506                          2,506
Storage                                   3,671                          3,671
Fibonacci:Recursive                       3,794                          3,794
Computation                               5,776                          5,776
Fibonacci:Binet                           8,786                          8,786
large_div_rem                            10,705                          10,705
DivisionArithmetics                      14,831                          14,831
ERC20                                    32,288                          32,288
ERC20Tester                              34,589                          34,589
```
2026-04-09 22:33:21 -04:00
kvpanch 8d60b6f2ad Re-enable large contracts for WASM builds (#492)
The issue can not be reproduced. Enable test to track regressions

#149
2026-03-12 08:03:14 -04:00
kvpanchandLJ 61ac247135 Provide unique name from closures with same name (#488)
In YUL it's possible to declare closure with a same name, but in
different scope, which previously resulted to func name conflict during
LLVM IR construction.
To solve this, track YUL scope when building LLVM IR and a special
counter that increments every time function with the same name exists in
LLVM module.
There's still assert if somehow within the same scope there 2 functions
with the same name, which should be forbidden by Yul

Fixes: #474

---------

Co-authored-by: LJ <81748770+elle-j@users.noreply.github.com>
2026-03-10 10:55:42 -04:00
kvpanch 5aebcc76ab Disable LLVM warnings and enable LTO in emscripten build (#487)
Fixed #148 and last task of #156
2026-03-04 09:41:38 -05:00
kvpanch 810a36b18b Update EMSDK to 5.0.0 (#479)
Emscripten 4.0.12 introduced breaking change by changing module factory
to always return promise even if `WASM_ASYNC_COMPILATION=0`. To overcome this, build emscripten compiler without MODULARIZE with custom export of `createRevive`.
2026-02-23 15:48:07 -05:00
0cd949aa66 Update code base to use LLVM 21 (#434)
Signed-off-by: Cyrill Leutwiler <bigcyrill@hotmail.com>
Co-authored-by: LJ <81748770+elle-j@users.noreply.github.com>
Co-authored-by: xermicus <cyrill@parity.io>
2026-02-06 12:23:48 -05:00
kvpanchandxermicus 540ec03cd7 Added 2 options to control expected result to revive-runner (#438)
Added 2 options to control expected result to `revive-runner`:
```
      --verify-failure <VERIFY_FAILURE>
          The expected call result of the contract execution

          Possible values:
          - instantiate: The contract instantiation must fail
          - call:        The contract execution must fail

      --verify-call-gas-consumed <VERIFY_CALL_GAS_CONSUMED>
          The expected amount of consumed gas by the contract execution
```

---------

Co-authored-by: xermicus <bigcyrill@hotmail.com>
2026-01-07 21:36:33 -05:00
kvpanch f549a6b031 Infer full LLVM release version from git's tags (#437)
The helps to remove special casing from actions and will make future
LLVM updates smoother.
2025-12-22 16:23:29 -05:00
kvpanch d0c10e6d5c Update ubuntu's source list to use nobel (#425)
This helps to install clang-18 and not clang-15. Latter cannot be used
anymore to build new LLVM due to some missed clang option.
2025-12-03 21:28:48 -05:00
kvpanch 8cd10a6136 Clone emsdk for release-llvm CI action (#423)
Cloning of emsdk has been accidentally removed, that caused inability to
build LLVM release with current main.
The change adds this cloning back before emsdk script is sourced.
2025-11-27 21:36:28 -05:00
kvpanch b6a19c97b1 Fetch LLVM release according to branch in llvm submodule (#418)
This change is essential first step to unblock gracefully enable LLVM 21
in revive compiler as current action blindly fetched latest LLVM binary
from the list of releases on our page.
The change queries release version from the submodule and uses it. Next
step: build LLVM 21 release binary
Next next step: switch revive compile to LLVM 21 after all issues are
fixed
2025-11-21 11:12:00 -05:00
kvpanch e78f3cc419 add LLVM 18.x as a git submodule (#399)
This changeset is based on https://github.com/paritytech/revive/pull/346
2025-11-18 16:10:15 -05:00
kvpanch 6549a4f825 Strip minsize attribute from functions with large div/rem (#390)
That's a workaround to avoid LLVM backend crash while selecting
instruction for 256-bit integer division.
The workaround needs to be removed after we switch to newest inkwell
that has a fix in RISC-V backend

---------

Signed-off-by: kvp <mammal_windier8j@icloud.com>
2025-10-21 10:35:40 +02:00