core/vm: Remove EnableWagon after merge

Wagon should be enabled by default when having EWASMBlock set to 0.
This commit is contained in:
Guillaume Ballet 2018-10-05 12:33:23 +02:00
parent 8054399e1b
commit ae38665a35
4 changed files with 4 additions and 5 deletions

View file

@ -85,7 +85,7 @@ func runCmd(ctx *cli.Context) error {
contract := coreVM.NewContract(coreVM.AccountRef(callerAddr), coreVM.AccountRef(contractAddr), big.NewInt(100), gas)
contract.Code = code
evm := coreVM.NewEVM(coreVM.Context{}, statedb, &params.ChainConfig{}, coreVM.Config{EnableWagon: true})
evm := coreVM.NewEVM(coreVM.Context{}, statedb, &params.ChainConfig{}, coreVM.Config{})
// &ewasm.Contract{
// StateDB: statedb,
// Gas: 100,

View file

@ -140,7 +140,7 @@ func NewEVM(ctx Context, statedb StateDB, chainConfig *params.ChainConfig, vmCon
}
if chainConfig.IsEWASM(ctx.BlockNumber) {
// to be implemented by EVM-C and Wagon PRs.
// to be implemented by EVM-C.
// if vmConfig.EWASMInterpreter != "" {
// extIntOpts := strings.Split(vmConfig.EWASMInterpreter, ":")
// path := extIntOpts[0]
@ -152,7 +152,6 @@ func NewEVM(ctx Context, statedb StateDB, chainConfig *params.ChainConfig, vmCon
// } else {
evm.interpreters = append(evm.interpreters, NewEWASMInterpreter(evm, vmConfig))
// }
panic("No supported ewasm interpreter yet.")
}
// vmConfig.EVMInterpreter will be used by EVM-C, it won't be checked here

View file

@ -36,7 +36,6 @@ func TestEWASMVM(t *testing.T) {
t.Skip("constantinople not supported yet")
}
withTrace(t, test.gasLimit(subtest), func(vmconfig vm.Config) error {
vmconfig.EnableWagon = true
_, err := test.Run(subtest, vmconfig)
return st.checkFailure(t, name, err)
})

View file

@ -52,6 +52,7 @@ var Forks = map[string]*params.ChainConfig{
EIP158Block: big.NewInt(0),
DAOForkBlock: big.NewInt(0),
ByzantiumBlock: big.NewInt(0),
EWASMBlock: big.NewInt(0),
},
"Constantinople": {
ChainID: big.NewInt(1),