Merge pull request #2141 from obscuren/evm-init

core, core/vm, tests: changed the initialisation behaviour of the EVM
This commit is contained in:
Jeffrey Wilcke
2016-03-23 23:20:51 +01:00
36 changed files with 669 additions and 346 deletions

View File

@ -203,11 +203,6 @@ var (
Value: "",
}
// vm flags
VMDebugFlag = cli.BoolFlag{
Name: "vmdebug",
Usage: "Virtual Machine debug output",
}
VMForceJitFlag = cli.BoolFlag{
Name: "forcejit",
Usage: "Force the JIT VM to take precedence",
@ -673,6 +668,8 @@ func MakeSystemNode(name, version string, extra []byte, ctx *cli.Context) *node.
ExtraData: MakeMinerExtra(extra, ctx),
NatSpec: ctx.GlobalBool(NatspecEnabledFlag.Name),
DocRoot: ctx.GlobalString(DocRootFlag.Name),
EnableJit: ctx.GlobalBool(VMEnableJitFlag.Name),
ForceJit: ctx.GlobalBool(VMForceJitFlag.Name),
GasPrice: common.String2Big(ctx.GlobalString(GasPriceFlag.Name)),
GpoMinGasPrice: common.String2Big(ctx.GlobalString(GpoMinGasPriceFlag.Name)),
GpoMaxGasPrice: common.String2Big(ctx.GlobalString(GpoMaxGasPriceFlag.Name)),
@ -728,9 +725,6 @@ func MakeSystemNode(name, version string, extra []byte, ctx *cli.Context) *node.
if !ctx.GlobalIsSet(WhisperEnabledFlag.Name) {
shhEnable = true
}
if !ctx.GlobalIsSet(VMDebugFlag.Name) {
vm.Debug = true
}
ethConf.PowTest = true
}
// Assemble and return the protocol stack
@ -771,9 +765,6 @@ func SetupVM(ctx *cli.Context) {
vm.EnableJit = ctx.GlobalBool(VMEnableJitFlag.Name)
vm.ForceJit = ctx.GlobalBool(VMForceJitFlag.Name)
vm.SetJITCacheSize(ctx.GlobalInt(VMJitCacheFlag.Name))
if ctx.GlobalIsSet(VMDebugFlag.Name) {
vm.Debug = ctx.GlobalBool(VMDebugFlag.Name)
}
}
// MakeChain creates a chain manager from set command line flags.