Skip to content

Commit

Permalink
Fix benchmarks that were failing
Browse files Browse the repository at this point in the history
Signed-off-by: Antonio Navarro <antnavper@gmail.com>
  • Loading branch information
ajnavarro committed Sep 26, 2024
1 parent a58bb00 commit 097b954
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 1 deletion.
7 changes: 6 additions & 1 deletion gnovm/pkg/gnolang/machine.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,11 @@ import (
"sync"
"testing"

"github.com/gnolang/overflow"

"github.com/gnolang/gno/tm2/pkg/errors"
"github.com/gnolang/gno/tm2/pkg/std"
"github.com/gnolang/gno/tm2/pkg/store"
"github.com/gnolang/overflow"
)

// Exception represents a panic that originates from a gno program.
Expand Down Expand Up @@ -2216,6 +2217,10 @@ func (m *Machine) String() string {

for i := len(m.Blocks) - 1; i > 0; i-- {
b := m.Blocks[i]
if b == nil {
continue
}

gen := builder.Len()/3 + 1
gens := "@" // strings.Repeat("@", gen)

Expand Down
5 changes: 5 additions & 0 deletions tm2/pkg/iavl/benchmarks/bench_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -170,9 +170,14 @@ func BenchmarkMedium(b *testing.B) {
}

func BenchmarkLarge(b *testing.B) {
b.Skip("large is too large")

ls := db.BackendList()
bs := make([]benchmark, 0, len(ls))
for _, backend := range ls {
if backend == db.BoltDBBackend {
continue
}
bs = append(bs, benchmark{backend, 1_000_000, 100, 16, 40})
}
runBenchmarks(b, bs)
Expand Down

0 comments on commit 097b954

Please sign in to comment.