aboutsummaryrefslogtreecommitdiffstats
path: root/core/bench_test.go
diff options
context:
space:
mode:
Diffstat (limited to 'core/bench_test.go')
-rw-r--r--core/bench_test.go7
1 files changed, 3 insertions, 4 deletions
diff --git a/core/bench_test.go b/core/bench_test.go
index 59b5ad758..353d217fd 100644
--- a/core/bench_test.go
+++ b/core/bench_test.go
@@ -92,7 +92,6 @@ func genValueTx(nbytes int) func(int, *BlockGen) {
var (
ringKeys = make([]*ecdsa.PrivateKey, 1000)
ringAddrs = make([]common.Address, len(ringKeys))
- bigTxGas = new(big.Int).SetUint64(params.TxGas)
)
func init() {
@@ -112,8 +111,8 @@ func genTxRing(naccounts int) func(int, *BlockGen) {
return func(i int, gen *BlockGen) {
gas := CalcGasLimit(gen.PrevBlock(i - 1))
for {
- gas.Sub(gas, bigTxGas)
- if gas.Cmp(bigTxGas) < 0 {
+ gas.Sub(gas, params.TxGas)
+ if gas.Cmp(params.TxGas) < 0 {
break
}
to := (from + 1) % naccounts
@@ -121,7 +120,7 @@ func genTxRing(naccounts int) func(int, *BlockGen) {
gen.TxNonce(ringAddrs[from]),
ringAddrs[to],
benchRootFunds,
- bigTxGas,
+ params.TxGas,
nil,
nil,
)