aboutsummaryrefslogtreecommitdiffstats
path: root/core/vm/jit.go
Commit message (Collapse)AuthorAgeFilesLines
* core, core/state, trie: EIP158, reprice & skip empty account writeJeffrey Wilcke2016-11-131-1/+1
| | | | | | | | | | | | | | | This commit implements EIP158 part 1, 2, 3 & 4 1. If an account is empty it's no longer written to the trie. An empty account is defined as (balance=0, nonce=0, storage=0, code=0). 2. Delete an empty account if it's touched 3. An empty account is redefined as either non-existent or empty. 4. Zero value calls and zero value suicides no longer consume the 25k reation costs. params: moved core/config to params Signed-off-by: Jeffrey Wilcke <jeffrey@ethereum.org>
* core/state: rename Delete/IsDeleted to Suicide/HasSuicidedFelix Lange2016-10-061-1/+1
| | | | The delete/remove naming has caused endless confusion in the past.
* core/vm: Refactor tracing to make Tracer the main interfaceNick Johnson2016-08-221-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | This CL makes several refactors: - Define a Tracer interface, implementing the `CaptureState` method - Add the VM environment as the first argument of `Tracer.CaptureState` - Rename existing functionality `StructLogger` an make it an implementation of `Tracer` - Delete `StructLogCollector` and make `StructLogger` collect the logs directly - Change all callers to use the new `StructLogger` where necessary and extract logs from that. - Deletes the apparently obsolete and likely nonfunctional 'TraceCall' from the eth API. Callers that only wish accumulated logs can use the `StructLogger` implementation straightforwardly. Callers that wish to efficiently capture VM traces and operate on them without excessive copying can now implement the `Tracer` interface to receive VM state at each step and do with it as they wish. This CL also removes the accumulation of logs from the vm.Environment; this was necessary as part of the refactor, but also simplifies it by removing a responsibility that doesn't directly belong to the Environment.
* vm: Replace some SstoreClearGas with SstoreResetGasYoichi Hirai2016-06-221-1/+1
|
* all: update license informationFelix Lange2016-04-151-1/+1
|
* core: added basic chain configurationJeffrey Wilcke2016-04-011-13/+10
| | | | | | | | | Added chain configuration options and write out during genesis database insertion. If no "config" was found, nothing is written to the database. Configurations are written on a per genesis base. This means that any chain (which is identified by it's genesis hash) can have their own chain settings.
* core: various typosLeif Jurvetson2016-03-161-3/+3
|
* all: Rename crypto.Sha3{,Hash}() to crypto.Keccak256{,Hash}()Ricardo Catalinas Jiménez2016-02-221-1/+1
| | | | As we aren't really using the standarized SHA-3
* core, core/vm, crypto: fixes for homesteadJeffrey Wilcke2016-02-181-3/+18
| | | | | | * Removed some strange code that didn't apply state reverting properly * Refactored code setting from vm & state transition to the executioner * Updated tests
* core/vm: added JIT segmenting / optimisationsJeffrey Wilcke2015-10-171-0/+2
| | | | | * multi-push segments * static jumps segments
* core/vm: abstracted instruction execution away from JITJeffrey Wilcke2015-10-171-68/+14
| | | | | | Moved the execution of instructions to the instruction it self. This will allow for specialised instructions (e.g. segments) to be execution in the same manner as regular instructions.
* cmd/evm, core/vm, test: refactored VM and coreJeffrey Wilcke2015-10-041-53/+58
| | | | | | | | | | | | | | | | | * Moved `vm.Transfer` to `core` package and changed execution to call `env.Transfer` instead of `core.Transfer` directly. * core/vm: byte code VM moved to jump table instead of switch * Moved `vm.Transfer` to `core` package and changed execution to call `env.Transfer` instead of `core.Transfer` directly. * Byte code VM now shares the same code as the JITVM * Renamed Context to Contract * Changed initialiser of state transition & unexported methods * Removed the Execution object and refactor `Call`, `CallCode` & `Create` in to their own functions instead of being methods. * Removed the hard dep on the state for the VM. The VM now depends on a Database interface returned by the environment. In the process the core now depends less on the statedb by usage of the env * Moved `Log` from package `core/state` to package `core/vm`.
* core/vm: fixed jit error & added inline docsJeffrey Wilcke2015-08-111-0/+6
| | | | | opNumber did not create a new big int which could lead to the block's number being modified.
* core/vm: reduced big int allocationsJeffrey Wilcke2015-08-071-7/+10
| | | | | | | Reduced big int allocation by making stack items modifiable. Instead of adding items such as `common.Big0` to the stack, `new(big.Int)` is added instead. One must expect that any item that is added to the stack might change.
* core, tests: reduced state copy by N callsJeffrey Wilcke2015-08-071-1/+2
| | | | | Reduced the amount of state copied that are required by N calls by doing a balance check prior to any state modifications.
* core/vm, tests: implemented semi-jit vmJeffrey Wilcke2015-08-071-0/+537
* changed stack and removed stack ptr. Let go decide on slice reuse.