1. 02 Jun, 2020 1 commit
    • Greg Colvin's avatar
      core/vm: EIP-2315, JUMPSUB for the EVM (#20619) · cd57d5cd
      Greg Colvin authored
      * core/vm: implement EIP 2315, subroutines for the EVM
      
      * core/vm: eip 2315 - lintfix + check jump dest validity + check ret stack size constraints
      
        logger: markdown-friendly traces, validate jumpdest, more testcase, correct opcodes
      
      * core/vm: update subroutines acc to eip: disallow walk-into
      
      * core/vm/eips: gas cost changes for subroutines
      
      * core/vm: update opcodes for EIP-2315
      
      * core/vm: define RETURNSUB as a 'jumping' operation + review concerns
      Co-authored-by: 's avatarMartin Holst Swende <martin@swende.se>
      cd57d5cd
  2. 22 Apr, 2020 1 commit
    • gary rong's avatar
      all: seperate consensus error and evm internal error (#20830) · b9df7ecd
      gary rong authored
      * all: seperate consensus error and evm internal error
      
      There are actually two types of error will be returned when
      a tranaction/message call is executed: (a) consensus error
      (b) evm internal error. The former should be converted to
      a consensus issue, e.g. The sender doesn't enough asset to
      purchase the gas it specifies. The latter is allowed since
      evm itself is a blackbox and internal error is allowed to happen.
      
      This PR emphasizes the difference by introducing a executionResult
      structure. The evm error is embedded inside. So if any error
      returned, it indicates consensus issue happens.
      
      And also this PR improve the `EstimateGas` API to return the concrete
      revert reason if the transaction always fails
      
      * all: polish
      
      * accounts/abi/bind/backends: add tests
      
      * accounts/abi/bind/backends, internal: cleanup error message
      
      * all: address comments
      
      * core: fix lint
      
      * accounts, core, eth, internal: address comments
      
      * accounts, internal: resolve revert reason if possible
      
      * accounts, internal: address comments
      b9df7ecd
  3. 25 Jul, 2018 1 commit
  4. 26 Jun, 2018 1 commit
  5. 25 Aug, 2017 1 commit
  6. 05 Jan, 2017 1 commit
    • Jeffrey Wilcke's avatar
      core/vm: improved EVM run loop & instruction calling (#3378) · bbc4ea4a
      Jeffrey Wilcke authored
      The run loop, which previously contained custom opcode executes have been
      removed and has been simplified to a few checks.
      
      Each operation consists of 4 elements: execution function, gas cost function,
      stack validation function and memory size function. The execution function
      implements the operation's runtime behaviour, the gas cost function implements
      the operation gas costs function and greatly depends on the memory and stack,
      the stack validation function validates the stack and makes sure that enough
      items can be popped off and pushed on and the memory size function calculates
      the memory required for the operation and returns it.
      
      This commit also allows the EVM to go unmetered. This is helpful for offline
      operations such as contract calls.
      bbc4ea4a
  7. 06 Dec, 2016 1 commit
    • Jeffrey Wilcke's avatar
      core, core/vm: implemented a generic environment (#3348) · 3fc7c978
      Jeffrey Wilcke authored
      Environment is now a struct (not an interface). This
      reduces a lot of tech-debt throughout the codebase where a virtual
      machine environment had to be implemented in order to test or run it.
      
      The new environment is suitable to be used en the json tests, core
      consensus and light client.
      3fc7c978
  8. 30 Sep, 2016 1 commit
    • Yoichi Hirai's avatar
      vm, ethapi: add `limit` option to traceTransaction · bb6115b7
      Yoichi Hirai authored
      that specifies the maximum number of elements in the `structLogs`
      output.  This option is useful for debugging a transaction that
      involves a large number of repetition.
      
      For example,
      ```
      debug.traceTransaction(tx, {disableStorage: true, limit: 2})
      ```
      shows at most the first two steps in the `structLogs`.
      bb6115b7
  9. 18 Feb, 2016 1 commit
  10. 10 Sep, 2015 1 commit
  11. 23 Jul, 2015 1 commit
  12. 22 Jul, 2015 1 commit
  13. 07 Jul, 2015 1 commit
  14. 06 Jul, 2015 1 commit
  15. 04 Jul, 2015 1 commit
  16. 12 Jun, 2015 1 commit
  17. 02 Apr, 2015 1 commit
    • Gustav Simonsson's avatar
      Read most protocol params from common/params.json · c26c8d3a
      Gustav Simonsson authored
      * Add params package with exported variables generated from
        github.com/ethereum/common/blob/master/params.json
      * Use params package variables in applicable places
      * Add check for minimum gas limit in validation of block's gas limit
      * Remove common/params.json from go-ethereum to avoid
        outdated version of it
      c26c8d3a
  18. 23 Mar, 2015 1 commit
  19. 23 Oct, 2014 1 commit