aboutsummaryrefslogtreecommitdiffstats
path: root/ethvm/debugger.go
diff options
context:
space:
mode:
authorobscuren <geffobscura@gmail.com>2014-10-14 17:48:52 +0800
committerobscuren <geffobscura@gmail.com>2014-10-14 17:48:52 +0800
commitc5bd32b0ad1a3d0fd20a3d1014cc8a97d889dc28 (patch)
tree5588276a932ac88daaaf9ca1858106ba3ff007b1 /ethvm/debugger.go
parent2e894b668a2bde3eb83418cfd9128f3a571e0026 (diff)
downloadgo-tangerine-c5bd32b0ad1a3d0fd20a3d1014cc8a97d889dc28.tar.gz
go-tangerine-c5bd32b0ad1a3d0fd20a3d1014cc8a97d889dc28.tar.zst
go-tangerine-c5bd32b0ad1a3d0fd20a3d1014cc8a97d889dc28.zip
Refactored VM to two separate VMs; std & debug
Standard VM should be about 10x faster than the debug VM. Some error checking has been removed, all of the log statements and therefor quite some unnecessary if-statements.
Diffstat (limited to 'ethvm/debugger.go')
-rw-r--r--ethvm/debugger.go10
1 files changed, 10 insertions, 0 deletions
diff --git a/ethvm/debugger.go b/ethvm/debugger.go
new file mode 100644
index 000000000..6144b5d6a
--- /dev/null
+++ b/ethvm/debugger.go
@@ -0,0 +1,10 @@
+package ethvm
+
+import "github.com/ethereum/eth-go/ethstate"
+
+type Debugger interface {
+ BreakHook(step int, op OpCode, mem *Memory, stack *Stack, object *ethstate.StateObject) bool
+ StepHook(step int, op OpCode, mem *Memory, stack *Stack, object *ethstate.StateObject) bool
+ BreakPoints() []int64
+ SetCode(byteCode []byte)
+}