Skip to content

Conversation

@pdrobnjak
Copy link
Contributor

@pdrobnjak pdrobnjak commented Jan 15, 2026

Summary

  • Add evmone library loading infrastructure using Go build tags for platform-specific library selection
  • Include pre-built evmone 0.12.0 binaries for darwin/arm64 and linux/amd64
  • Load evmone at app startup to avoid first-block latency

Changes

New giga/executor/lib package

  • evmlib.go: InitEvmoneVM() function that loads evmone and verifies version compatibility
  • lib_darwin_arm64.go, lib_linux_amd64.go: Build tag files defining platform-specific library names
  • Pre-built evmone 0.12.0 binaries (~300KB darwin, ~490KB linux)

App integration

  • EvmoneVM field added to EvmKeeper to store pre-loaded VM
  • evmone loaded at app initialization when GigaExecutor is enabled

pdrobnjak and others added 14 commits December 23, 2025 18:15
## Describe your changes and provide context
- adds new config for process block
- instruments scripts to use new executor if flag is passed 
- adds 

## Testing performed to validate your change
```
# run giga with OCC
GIGA_EXECUTOR=true GIGA_OCC=true ./scripts/benchmark.sh

# run giga without OCC (direct sequential execution with no scheduler)
GIGA_EXECUTOR=true GIGA_OCC=false ./scripts/benchmark.sh

# run non-giga 
GIGA_EXECUTOR=false ./scripts/benchmark.sh
```

---------

Co-authored-by: pdrobnjak <drobnjakpavle95@gmail.com>
## Describe your changes and provide context

Refactor of the `evmc` and `geth` VM.

First an improvement on the abstraction - we're working on transaction
executor level, not on the VM level.

Second, we can leverage the same executor implementation to cover both
`evmone` and `geth` cases.

Removing everything that's redundant since second point holds true.

## Testing performed to validate your change

Ran `giga/tests`.
## Describe your changes and provide context
- adds giga occ flag to initialize_local_chain

## Testing performed to validate your change
- funds account after init local chain successfully
@github-actions
Copy link

github-actions bot commented Jan 15, 2026

The latest Buf updates on your PR. Results from workflow Buf / buf (pull_request).

BuildFormatLintBreakingUpdated (UTC)
✅ passed✅ passed✅ passed✅ passedJan 16, 2026, 2:12 PM

pdrobnjak

This comment was marked as outdated.

@codecov
Copy link

codecov bot commented Jan 15, 2026

Codecov Report

❌ Patch coverage is 0% with 16 lines in your changes missing coverage. Please review.
✅ Project coverage is 43.76%. Comparing base (ac2fc61) to head (cb6d34e).
⚠️ Report is 1 commits behind head on main.

Files with missing lines Patch % Lines
giga/executor/lib/evmlib.go 0.00% 9 Missing ⚠️
app/app.go 0.00% 5 Missing ⚠️
giga/executor/executor.go 0.00% 2 Missing ⚠️
Additional details and impacted files

Impacted file tree graph

@@           Coverage Diff           @@
##             main    #2705   +/-   ##
=======================================
  Coverage   43.76%   43.76%           
=======================================
  Files        1913     1914    +1     
  Lines      159491   159504   +13     
=======================================
+ Hits        69797    69805    +8     
- Misses      83271    83277    +6     
+ Partials     6423     6422    -1     
Flag Coverage Δ
sei-chain 45.75% <0.00%> (-0.01%) ⬇️
sei-cosmos 38.20% <ø> (-0.01%) ⬇️
sei-db 68.72% <ø> (ø)
sei-tendermint 47.31% <ø> (+0.03%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files with missing lines Coverage Δ
x/evm/keeper/keeper.go 48.95% <ø> (ø)
giga/executor/executor.go 0.00% <0.00%> (ø)
app/app.go 56.88% <0.00%> (-0.19%) ⬇️
giga/executor/lib/evmlib.go 0.00% <0.00%> (ø)

... and 19 files with indirect coverage changes

🚀 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.

pdrobnjak and others added 5 commits January 15, 2026 13:43
- Add bootstrap script to download pre-built evmone from GitHub releases
- Add LoadEvmone() to load shared library from EVMONE_PATH env var
- Update NewEvmoneExecutor to accept evmc.VM and pass to HostContext
- Wire up evmone loading in app.go executeEVMTxWithGigaExecutor

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- Add EvmoneVM field to EvmKeeper to store pre-loaded VM
- Load evmone at app initialization when GigaExecutor is enabled
- Remove LoadEvmone call from block execution path
- Pass EvmKeeper.EvmoneVM directly to NewEvmoneExecutor

This avoids the first block being bottlenecked by VM initialization.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- Add giga/executor/lib package with InitVM() and version verification
- Use runtime/debug.ReadBuildInfo to infer expected evmone version from EVMC
- Add build tag files for darwin/arm64 and linux/amd64
- Include pre-built evmone 0.12.0 binaries for both platforms
- Remove LoadEvmone() from executor.go (no longer needed)
- Update app.go to use lib.InitVM()
- Update bootstrap script with correct output filenames

The version check ensures the committed binary matches the EVMC dependency
in go.mod, preventing accidental version mismatches.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
@pdrobnjak pdrobnjak force-pushed the pd/bootstrap-evmone branch from 40f80b3 to f315862 Compare January 15, 2026 12:54
pdrobnjak and others added 2 commits January 15, 2026 14:01
Add three new tests that verify contract deployment and execution
produce identical results between Geth and Giga executors:

- TestGigaVsGeth_ContractDeployAndCall: Deploy SimpleStorage contract
- TestGigaVsGeth_ContractCallsSequential: Deploy + multiple calls in same block
- TestAllModes_ContractExecution: Test across all three executor modes

Also adds:
- CompareResultsNoGas helper for comparing results without strict gas checks
  (Geth and evmone may have different gas accounting)
- CreateContractDeployTxs and CreateContractCallTxs helpers
- SimpleStorage bytecode from example/contracts/simplestorage

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
import (
"fmt"
"path/filepath"
"runtime"

Check notice

Code scanning / CodeQL

Sensitive package import Note

Certain system packages contain functions which may be a possible source of non-determinism
@pdrobnjak pdrobnjak changed the title Bootstrap evmone integration with build tags Bootstrap evmone integration with build tags Jan 15, 2026
When building on an unsupported OS/architecture combination,
the build now fails with a descriptive error message instead
of the unclear "undefined: libName" error.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
@pdrobnjak pdrobnjak self-assigned this Jan 15, 2026
Base automatically changed from pd/evmc-vm to main January 15, 2026 14:36
@pdrobnjak pdrobnjak enabled auto-merge (squash) January 15, 2026 14:38
@pdrobnjak pdrobnjak merged commit 91ef5cb into main Jan 16, 2026
49 of 52 checks passed
@pdrobnjak pdrobnjak deleted the pd/bootstrap-evmone branch January 16, 2026 15:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants