Skip to content

Commit

Permalink
fix resolve
Browse files Browse the repository at this point in the history
  • Loading branch information
mmsqe committed Nov 21, 2023
1 parent ae8dd60 commit e0c0539
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
8 changes: 4 additions & 4 deletions core/vm/contracts.go
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ import (
"github.com/ethereum/go-ethereum/crypto/bls12381"
"github.com/ethereum/go-ethereum/crypto/bn256"
"github.com/ethereum/go-ethereum/params"
big2 "github.com/holiman/big"
"golang.org/x/crypto/ripemd160"
)

Expand Down Expand Up @@ -412,7 +413,6 @@ type bigModExp struct {
var (
big0 = big.NewInt(0)
big1 = big.NewInt(1)
big2 = big.NewInt(2)
big3 = big.NewInt(3)
big4 = big.NewInt(4)
big7 = big.NewInt(7)
Expand Down Expand Up @@ -550,9 +550,9 @@ func (c *bigModExp) Run(evm *EVM, contract *Contract, readonly bool) ([]byte, er
}
// Retrieve the operands and execute the exponentiation
var (
base = new(big.Int).SetBytes(getData(contract.Input, 0, baseLen))
exp = new(big.Int).SetBytes(getData(contract.Input, baseLen, expLen))
mod = new(big.Int).SetBytes(getData(contract.Input, baseLen+expLen, modLen))
base = new(big2.Int).SetBytes(getData(contract.Input, 0, baseLen))
exp = new(big2.Int).SetBytes(getData(contract.Input, baseLen, expLen))
mod = new(big2.Int).SetBytes(getData(contract.Input, baseLen+expLen, modLen))
v []byte
)
switch {
Expand Down
2 changes: 1 addition & 1 deletion tests/state_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -239,7 +239,7 @@ func runBenchmark(b *testing.B, t *StateTest) {
b.ResetTimer()
for n := 0; n < b.N; n++ {
snapshot := statedb.Snapshot()
statedb.Prepare(rules, msg.From(), context.Coinbase, msg.To(), vm.ActivePrecompiles(rules), msg.AccessList())
statedb.Prepare(rules, msg.From(), context.Coinbase, msg.To(), evm.ActivePrecompiles(rules), msg.AccessList())
b.StartTimer()
start := time.Now()

Expand Down

0 comments on commit e0c0539

Please sign in to comment.