nimbus-eth1/tools/evmstate
Jordan Hrycaj b623909c44
Ledger activate unified accounts cache wrapper (#1939)
* Activate `LedgerRef` wrapper for `AccountsCache`

details:
  `accounts_cache.nim` methods are indirectly processed by the wrapper
  methods from `ledger.nim`.

  This works for all sources except `test_state_db.nim` where the source
  `accounts_cache.nim` is included (rather than imported) in order to
  access objects privy to the very source.

* Provide facility to switch to a preselected `LedgerRef` type

details:
  Can be set as suggestion when initialising `CommonRef`

* Update `CoreDb` test suite for better time tracking

details:
+ Allow time logging by pre-defined block intervals
+ Print `CoreDb`/`Ledger`profiling results (if enabled)
2023-12-12 19:12:56 +00:00
..
testdata modexp precompile allow arbitrary input length 2023-05-11 07:21:03 +07:00
config.nim Implement plugable EVM tracer 2023-08-03 16:45:39 +07:00
config.nims Add check copyright year linter to CI 2023-11-01 10:41:20 +07:00
evmstate.nim Ledger activate unified accounts cache wrapper (#1939) 2023-12-12 19:12:56 +00:00
evmstate_test.nim Fix blobGas fields handling in evmstate 2023-09-22 07:42:58 +07:00
helpers.nim Ledger activate unified accounts cache wrapper (#1939) 2023-12-12 19:12:56 +00:00
readme.md update tools build instruction 2023-08-01 09:25:18 +07:00

readme.md

EVM state test tool

The evmstate tool to execute state test.

Build instructions

There are few options to build evmstate tool like any other nimbus tools.

  1. Use your system Nim compiler(v1.6.12) and git to install dependencies.
    $> git submodule update --init --recursive
    $> ./env.sh (run once to generate nimbus-build-system.paths)
    $> nim c -d:release tools/evmstate/evmstate
    $> nim c -r -d:release tools/evmstate/evmstate_test
    
  2. Use nimbus shipped Nim compiler and dependencies.
    $> make update deps
    $> ./env.sh nim c -d:release tools/evmstate/evmstate
    $> ./env.sh nim c -r -d:release tools/evmstate/evmstate_test
    
  3. Use nimbus makefile.
    $> make update
    $> make evmstate
    $> make evmstate_test
    

Command line params

Available command line params

Usage:

evmstate [OPTIONS]... <inputFile>

 <inputFile>         json file contains state test data.

The following options are available:

 --dump              dumps the state after the run [=false].
 --json              output trace logs in machine readable format (json) [=false].
 --debug             output full trace logs [=false].
 --nomemory          disable memory output [=true].
 --nostack           disable stack output [=false].
 --nostorage         disable storage output [=false].
 --noreturndata      enable return data output [=true].
 --fork              choose which fork to be tested.
 --index             if index is unset, all subtest in the fork will be tested [=none(int)].
 --pretty            pretty print the trace result [=false].
 --verbosity         sets the verbosity level [=0].
                        0 = silent, 1 = error, 2 = warn, 3 = info, 4 = debug, 5 = detail.