Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TM2 iavl BenchmarkLarge panicking #2714

Closed
sw360cab opened this issue Aug 20, 2024 · 2 comments
Closed

TM2 iavl BenchmarkLarge panicking #2714

sw360cab opened this issue Aug 20, 2024 · 2 comments
Labels
🐞 bug Something isn't working ⭐️ could have ⭐️ Optional work needed to complete a project 🤝 open for contributors 🤝 Work available to external contributors

Comments

@sw360cab
Copy link
Contributor

BenchmarkLarge faling

A benchmark case for the package github.com/gnolang/gno/tm2/pkg/iavl/benchmarks
is panicking.

It is not clear if this is due to a bug or to a hardware / memory leak.

Your environment

  • go1.22.4
  • darwin/amd64
  • Gno commit: 8bd07c971e7ed9ee94af03d7145f247224683694

Steps to reproduce

  • running the given benchmark test case
go test -benchmem -run=^$ -bench ^BenchmarkLarge$ github.com/gnolang/gno/tm2/pkg/iavl/benchmarks -tags=wireinject

Logs

Running tool: /usr/local/bin/go test -benchmem -run=^$ -bench ^BenchmarkLarge$ github.com/gnolang/gno/tm2/pkg/iavl/benchmarks -tags=wireinject

goos: darwin
goarch: amd64
pkg: github.com/gnolang/gno/tm2/pkg/iavl/benchmarks
cpu: Intel(R) Core(TM) i7-8850H CPU @ 2.60GHz
=== RUN   BenchmarkLarge
BenchmarkLarge
=== RUN   BenchmarkLarge/boltdb-1000000-100-16-40
BenchmarkLarge/boltdb-1000000-100-16-40
SIGQUIT: quit
PC=0x7ff803ac7f7a m=0 sigcode=0

goroutine 0 gp=0x525b240 m=0 mp=0x525c280 [idle]:
runtime.pthread_cond_wait(0x525c8c8, 0x525c888)
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/sys_darwin.go:507 +0x2e fp=0x7ff7bc3a6b30 sp=0x7ff7bc3a6b08 pc=0x4bb3a6e
runtime.semasleep(0xffffffffffffffff)
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/os_darwin.go:71 +0xaf fp=0x7ff7bc3a6b88 sp=0x7ff7bc3a6b30 pc=0x4b8f10f
runtime.notesleep(0x525c3c0)
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/lock_sema.go:183 +0x92 fp=0x7ff7bc3a6bc0 sp=0x7ff7bc3a6b88 pc=0x4b659b2
runtime.mPark(...)
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/proc.go:1761
runtime.stopm()
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/proc.go:2782 +0x8c fp=0x7ff7bc3a6bf0 sp=0x7ff7bc3a6bc0 pc=0x4b9908c
runtime.findRunnable()
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/proc.go:3512 +0xd5f fp=0x7ff7bc3a6d68 sp=0x7ff7bc3a6bf0 pc=0x4b9abff
runtime.schedule()
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/proc.go:3868 +0xb1 fp=0x7ff7bc3a6da0 sp=0x7ff7bc3a6d68 pc=0x4b9bcd1
runtime.park_m(0xc000112000)
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/proc.go:4036 +0x1ec fp=0x7ff7bc3a6df8 sp=0x7ff7bc3a6da0 pc=0x4b9c2ac
runtime.mcall()
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/asm_amd64.s:458 +0x4e fp=0x7ff7bc3a6e10 sp=0x7ff7bc3a6df8 pc=0x4bca0ce

goroutine 1 gp=0xc0000061c0 m=nil [chan receive, 10 minutes]:
runtime.gopark(0x80000000000?, 0xc0001918a0?, 0xe5?, 0x7a?, 0xb8060?)
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/proc.go:402 +0xce fp=0xc000191880 sp=0xc000191860 pc=0x4b94bee
runtime.chanrecv(0xc0000980c0, 0x0, 0x1)
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/chan.go:583 +0x3bf fp=0xc0001918f8 sp=0xc000191880 pc=0x4b5ff1f
runtime.chanrecv1(0xc0000b8080?, 0xc0000b4000?)
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/chan.go:442 +0x12 fp=0xc000191920 sp=0xc0001918f8 pc=0x4b5fb32
testing.(*B).run1(0xc0000e4288)
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/testing/benchmark.go:217 +0xa6 fp=0xc000191a10 sp=0xc000191920 pc=0x4c4c366
testing.(*B).Run(0xc0000e4c88, {0x4e3b098?, 0x4be600f?}, 0x5014ae8)
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/testing/benchmark.go:682 +0x497 fp=0xc000191b10 sp=0xc000191a10 pc=0x4c4ee77
testing.runBenchmarks.func1(0xc0000e4c88)
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/testing/benchmark.go:543 +0x37 fp=0xc000191b50 sp=0xc000191b10 pc=0x4c4df77
testing.(*B).runN(0xc0000e4c88, 0x1)
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/testing/benchmark.go:193 +0xf8 fp=0xc000191ba0 sp=0xc000191b50 pc=0x4c4c198
testing.runBenchmarks({0x4e48d0d, 0x2e}, 0x0?, {0x5253dc0, 0x7, 0x4b6f53b?})
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/testing/benchmark.go:552 +0x605 fp=0xc000191ca0 sp=0xc000191ba0 pc=0x4c4dec5
testing.(*M).Run(0xc0001da000)
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/testing/testing.go:2043 +0x9f6 fp=0xc000191ed0 sp=0xc000191ca0 pc=0x4c59b76
main.main()
        _testmain.go:59 +0x16c fp=0xc000191f50 sp=0xc000191ed0 pc=0x4e377ec
runtime.main()
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/proc.go:271 +0x29d fp=0xc000191fe0 sp=0xc000191f50 pc=0x4b9479d
runtime.goexit({})
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/asm_amd64.s:1695 +0x1 fp=0xc000191fe8 sp=0xc000191fe0 pc=0x4bcc121

goroutine 2 gp=0xc000006c40 m=nil [force gc (idle), 2 minutes]:
runtime.gopark(0x125bfbcaad14?, 0x0?, 0x0?, 0x0?, 0x0?)
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/proc.go:402 +0xce fp=0xc000058fa8 sp=0xc000058f88 pc=0x4b94bee
runtime.goparkunlock(...)
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/proc.go:408
runtime.forcegchelper()
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/proc.go:326 +0xb3 fp=0xc000058fe0 sp=0xc000058fa8 pc=0x4b94a53
runtime.goexit({})
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/asm_amd64.s:1695 +0x1 fp=0xc000058fe8 sp=0xc000058fe0 pc=0x4bcc121
created by runtime.init.6 in goroutine 1
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/proc.go:314 +0x1a

goroutine 3 gp=0xc000007180 m=nil [GC sweep wait]:
runtime.gopark(0x1?, 0x0?, 0x0?, 0x0?, 0x0?)
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/proc.go:402 +0xce fp=0xc000059780 sp=0xc000059760 pc=0x4b94bee
runtime.goparkunlock(...)
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/proc.go:408
runtime.bgsweep(0xc00007c000)
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/mgcsweep.go:318 +0xdf fp=0xc0000597c8 sp=0xc000059780 pc=0x4b7f35f
runtime.gcenable.gowrap1()
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/mgc.go:203 +0x25 fp=0xc0000597e0 sp=0xc0000597c8 pc=0x4b73c65
runtime.goexit({})
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/asm_amd64.s:1695 +0x1 fp=0xc0000597e8 sp=0xc0000597e0 pc=0x4bcc121
created by runtime.gcenable in goroutine 1
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/mgc.go:203 +0x66

goroutine 4 gp=0xc000007340 m=nil [GC scavenge wait]:
runtime.gopark(0x1e4bc4af?, 0x1e466505?, 0x0?, 0x0?, 0x0?)
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/proc.go:402 +0xce fp=0xc000059f78 sp=0xc000059f58 pc=0x4b94bee
runtime.goparkunlock(...)
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/proc.go:408
runtime.(*scavengerState).park(0x525b0c0)
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/mgcscavenge.go:425 +0x49 fp=0xc000059fa8 sp=0xc000059f78 pc=0x4b7cd09
runtime.bgscavenge(0xc00007c000)
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/mgcscavenge.go:658 +0x59 fp=0xc000059fc8 sp=0xc000059fa8 pc=0x4b7d2b9
runtime.gcenable.gowrap2()
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/mgc.go:204 +0x25 fp=0xc000059fe0 sp=0xc000059fc8 pc=0x4b73c05
runtime.goexit({})
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/asm_amd64.s:1695 +0x1 fp=0xc000059fe8 sp=0xc000059fe0 pc=0x4bcc121
created by runtime.gcenable in goroutine 1
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/mgc.go:204 +0xa5

goroutine 18 gp=0xc00008c700 m=nil [finalizer wait, 10 minutes]:
runtime.gopark(0xc000058648?, 0x4b67725?, 0xa8?, 0x1?, 0xc0000061c0?)
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/proc.go:402 +0xce fp=0xc000058620 sp=0xc000058600 pc=0x4b94bee
runtime.runfinq()
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/mfinal.go:194 +0x107 fp=0xc0000587e0 sp=0xc000058620 pc=0x4b72ca7
runtime.goexit({})
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/asm_amd64.s:1695 +0x1 fp=0xc0000587e8 sp=0xc0000587e0 pc=0x4bcc121
created by runtime.createfing in goroutine 1
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/mfinal.go:164 +0x3d

goroutine 19 gp=0xc0001d0540 m=nil [GC worker (idle)]:
runtime.gopark(0x1269884ce34b?, 0x3?, 0x47?, 0x37?, 0x0?)
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/proc.go:402 +0xce fp=0xc000054750 sp=0xc000054730 pc=0x4b94bee
runtime.gcBgMarkWorker()
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/mgc.go:1310 +0xe5 fp=0xc0000547e0 sp=0xc000054750 pc=0x4b75d45
runtime.goexit({})
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/asm_amd64.s:1695 +0x1 fp=0xc0000547e8 sp=0xc0000547e0 pc=0x4bcc121
created by runtime.gcBgMarkStartWorkers in goroutine 1
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/mgc.go:1234 +0x1c

goroutine 34 gp=0xc000200000 m=nil [GC worker (idle)]:
runtime.gopark(0x1269887eaf56?, 0x3?, 0x18?, 0xc0?, 0x0?)
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/proc.go:402 +0xce fp=0xc000206750 sp=0xc000206730 pc=0x4b94bee
runtime.gcBgMarkWorker()
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/mgc.go:1310 +0xe5 fp=0xc0002067e0 sp=0xc000206750 pc=0x4b75d45
runtime.goexit({})
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/asm_amd64.s:1695 +0x1 fp=0xc0002067e8 sp=0xc0002067e0 pc=0x4bcc121
created by runtime.gcBgMarkStartWorkers in goroutine 1
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/mgc.go:1234 +0x1c

goroutine 35 gp=0xc0002001c0 m=nil [GC worker (idle)]:
runtime.gopark(0x126988498fcb?, 0x3?, 0x42?, 0xc?, 0x0?)
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/proc.go:402 +0xce fp=0xc000206f50 sp=0xc000206f30 pc=0x4b94bee
runtime.gcBgMarkWorker()
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/mgc.go:1310 +0xe5 fp=0xc000206fe0 sp=0xc000206f50 pc=0x4b75d45
runtime.goexit({})
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/asm_amd64.s:1695 +0x1 fp=0xc000206fe8 sp=0xc000206fe0 pc=0x4bcc121
created by runtime.gcBgMarkStartWorkers in goroutine 1
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/mgc.go:1234 +0x1c

goroutine 36 gp=0xc000200380 m=nil [GC worker (idle)]:
runtime.gopark(0x1269885399db?, 0x3?, 0x2b?, 0x47?, 0x0?)
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/proc.go:402 +0xce fp=0xc000207750 sp=0xc000207730 pc=0x4b94bee
runtime.gcBgMarkWorker()
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/mgc.go:1310 +0xe5 fp=0xc0002077e0 sp=0xc000207750 pc=0x4b75d45
runtime.goexit({})
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/asm_amd64.s:1695 +0x1 fp=0xc0002077e8 sp=0xc0002077e0 pc=0x4bcc121
created by runtime.gcBgMarkStartWorkers in goroutine 1
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/mgc.go:1234 +0x1c

goroutine 20 gp=0xc0001d0700 m=nil [GC worker (idle)]:
runtime.gopark(0x1269884f15be?, 0x3?, 0x1b?, 0xdc?, 0x0?)
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/proc.go:402 +0xce fp=0xc000054f50 sp=0xc000054f30 pc=0x4b94bee
runtime.gcBgMarkWorker()
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/mgc.go:1310 +0xe5 fp=0xc000054fe0 sp=0xc000054f50 pc=0x4b75d45
runtime.goexit({})
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/asm_amd64.s:1695 +0x1 fp=0xc000054fe8 sp=0xc000054fe0 pc=0x4bcc121
created by runtime.gcBgMarkStartWorkers in goroutine 1
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/mgc.go:1234 +0x1c

goroutine 5 gp=0xc000007c00 m=nil [GC worker (idle)]:
runtime.gopark(0x12693c7a1aab?, 0x1?, 0x68?, 0xd3?, 0x0?)
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/proc.go:402 +0xce fp=0xc00005a750 sp=0xc00005a730 pc=0x4b94bee
runtime.gcBgMarkWorker()
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/mgc.go:1310 +0xe5 fp=0xc00005a7e0 sp=0xc00005a750 pc=0x4b75d45
runtime.goexit({})
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/asm_amd64.s:1695 +0x1 fp=0xc00005a7e8 sp=0xc00005a7e0 pc=0x4bcc121
created by runtime.gcBgMarkStartWorkers in goroutine 1
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/mgc.go:1234 +0x1c

goroutine 21 gp=0xc0001d08c0 m=nil [GC worker (idle)]:
runtime.gopark(0x1269887bdd2e?, 0x3?, 0x43?, 0x6d?, 0x0?)
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/proc.go:402 +0xce fp=0xc000055750 sp=0xc000055730 pc=0x4b94bee
runtime.gcBgMarkWorker()
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/mgc.go:1310 +0xe5 fp=0xc0000557e0 sp=0xc000055750 pc=0x4b75d45
runtime.goexit({})
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/asm_amd64.s:1695 +0x1 fp=0xc0000557e8 sp=0xc0000557e0 pc=0x4bcc121
created by runtime.gcBgMarkStartWorkers in goroutine 1
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/mgc.go:1234 +0x1c

goroutine 6 gp=0xc000007dc0 m=nil [GC worker (idle)]:
runtime.gopark(0x12698853007a?, 0x3?, 0x7?, 0xad?, 0x0?)
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/proc.go:402 +0xce fp=0xc00005af50 sp=0xc00005af30 pc=0x4b94bee
runtime.gcBgMarkWorker()
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/mgc.go:1310 +0xe5 fp=0xc00005afe0 sp=0xc00005af50 pc=0x4b75d45
runtime.goexit({})
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/asm_amd64.s:1695 +0x1 fp=0xc00005afe8 sp=0xc00005afe0 pc=0x4bcc121
created by runtime.gcBgMarkStartWorkers in goroutine 1
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/mgc.go:1234 +0x1c

goroutine 22 gp=0xc0001d0a80 m=nil [GC worker (idle)]:
runtime.gopark(0x126988516053?, 0x3?, 0xe8?, 0xc6?, 0x0?)
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/proc.go:402 +0xce fp=0xc000055f50 sp=0xc000055f30 pc=0x4b94bee
runtime.gcBgMarkWorker()
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/mgc.go:1310 +0xe5 fp=0xc000055fe0 sp=0xc000055f50 pc=0x4b75d45
runtime.goexit({})
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/asm_amd64.s:1695 +0x1 fp=0xc000055fe8 sp=0xc000055fe0 pc=0x4bcc121
created by runtime.gcBgMarkStartWorkers in goroutine 1
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/mgc.go:1234 +0x1c

goroutine 7 gp=0xc000112000 m=nil [GC worker (idle)]:
runtime.gopark(0x126988526211?, 0x3?, 0x91?, 0x6e?, 0x0?)
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/proc.go:402 +0xce fp=0xc00005b750 sp=0xc00005b730 pc=0x4b94bee
runtime.gcBgMarkWorker()
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/mgc.go:1310 +0xe5 fp=0xc00005b7e0 sp=0xc00005b750 pc=0x4b75d45
runtime.goexit({})
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/asm_amd64.s:1695 +0x1 fp=0xc00005b7e8 sp=0xc00005b7e0 pc=0x4bcc121
created by runtime.gcBgMarkStartWorkers in goroutine 1
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/mgc.go:1234 +0x1c

goroutine 8 gp=0xc0001121c0 m=nil [GC worker (idle)]:
runtime.gopark(0x52bd040?, 0x1?, 0x3e?, 0x15?, 0x0?)
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/proc.go:402 +0xce fp=0xc00005bf50 sp=0xc00005bf30 pc=0x4b94bee
runtime.gcBgMarkWorker()
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/mgc.go:1310 +0xe5 fp=0xc00005bfe0 sp=0xc00005bf50 pc=0x4b75d45
runtime.goexit({})
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/asm_amd64.s:1695 +0x1 fp=0xc00005bfe8 sp=0xc00005bfe0 pc=0x4bcc121
created by runtime.gcBgMarkStartWorkers in goroutine 1
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/mgc.go:1234 +0x1c

goroutine 37 gp=0xc000200540 m=nil [GC worker (idle)]:
runtime.gopark(0x52bd040?, 0x1?, 0xbe?, 0xdd?, 0x0?)
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/proc.go:402 +0xce fp=0xc000207f50 sp=0xc000207f30 pc=0x4b94bee
runtime.gcBgMarkWorker()
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/mgc.go:1310 +0xe5 fp=0xc000207fe0 sp=0xc000207f50 pc=0x4b75d45
runtime.goexit({})
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/asm_amd64.s:1695 +0x1 fp=0xc000207fe8 sp=0xc000207fe0 pc=0x4bcc121
created by runtime.gcBgMarkStartWorkers in goroutine 1
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/mgc.go:1234 +0x1c

goroutine 9 gp=0xc0001d0380 m=nil [chan receive]:
runtime.gopark(0x80000000000?, 0xc000197ac8?, 0xe5?, 0x7a?, 0xb8060?)
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/proc.go:402 +0xce fp=0xc000197aa8 sp=0xc000197a88 pc=0x4b94bee
runtime.chanrecv(0xc000098120, 0x0, 0x1)
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/chan.go:583 +0x3bf fp=0xc000197b20 sp=0xc000197aa8 pc=0x4b5ff1f
runtime.chanrecv1(0xc0000b8080?, 0xc0000b4080?)
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/chan.go:442 +0x12 fp=0xc000197b48 sp=0xc000197b20 pc=0x4b5fb32
testing.(*B).run1(0xc0000e4788)
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/testing/benchmark.go:217 +0xa6 fp=0xc000197c38 sp=0xc000197b48 pc=0x4c4c366
testing.(*B).Run(0xc0000e4288, {0xc0000b6000?, 0x0?}, 0xc0000e00f0)
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/testing/benchmark.go:682 +0x497 fp=0xc000197d38 sp=0xc000197c38 pc=0x4c4ee77
github.com/gnolang/gno/tm2/pkg/iavl/benchmarks.runBenchmarks(0xc0000e4288, {0xc000128000, 0x3, 0xc0002086d8?})
        gno/tm2/pkg/iavl/benchmarks/bench_test.go:228 +0x89 fp=0xc000197e88 sp=0xc000197d38 pc=0x4e363e9
github.com/gnolang/gno/tm2/pkg/iavl/benchmarks.BenchmarkLarge(0xc0000e4288)
        gno/tm2/pkg/iavl/benchmarks/bench_test.go:178 +0x1bb fp=0xc000197f50 sp=0xc000197e88 pc=0x4e3601b
testing.(*B).runN(0xc0000e4288, 0x1)
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/testing/benchmark.go:193 +0xf8 fp=0xc000197fa0 sp=0xc000197f50 pc=0x4c4c198
testing.(*B).run1.func1()
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/testing/benchmark.go:215 +0x4e fp=0xc000197fe0 sp=0xc000197fa0 pc=0x4c4c7ce
runtime.goexit({})
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/asm_amd64.s:1695 +0x1 fp=0xc000197fe8 sp=0xc000197fe0 pc=0x4bcc121
created by testing.(*B).run1 in goroutine 1
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/testing/benchmark.go:208 +0x90

goroutine 23 gp=0xc000200a80 m=nil [runnable]:
github.com/gnolang/gno/tm2/pkg/iavl.(*nodeDB).SaveNode.deferwrap1()
        gno/tm2/pkg/iavl/nodedb.go:96 +0x3a fp=0xc02d017ab0 sp=0xc02d017aa8 pc=0x4e2c5ba
github.com/gnolang/gno/tm2/pkg/iavl.(*nodeDB).SaveNode(0xc0000e0140, 0xc02b578b00)
        gno/tm2/pkg/iavl/nodedb.go:115 +0x197 fp=0xc02d017b38 sp=0xc02d017ab0 pc=0x4e2c4f7
github.com/gnolang/gno/tm2/pkg/iavl.(*nodeDB).SaveBranch(0xc0000e0140, 0xc02b578b00)
        gno/tm2/pkg/iavl/nodedb.go:140 +0xd6 fp=0xc02d017b58 sp=0xc02d017b38 pc=0x4e2c6b6
github.com/gnolang/gno/tm2/pkg/iavl.(*nodeDB).SaveBranch(0xc0000e0140, 0xc02b578a50)
        gno/tm2/pkg/iavl/nodedb.go:136 +0x85 fp=0xc02d017b78 sp=0xc02d017b58 pc=0x4e2c665
github.com/gnolang/gno/tm2/pkg/iavl.(*nodeDB).SaveBranch(0xc0000e0140, 0xc02b5789a0)
        gno/tm2/pkg/iavl/nodedb.go:133 +0x3a fp=0xc02d017b98 sp=0xc02d017b78 pc=0x4e2c61a
github.com/gnolang/gno/tm2/pkg/iavl.(*nodeDB).SaveBranch(0xc0000e0140, 0xc02b5788f0)
        gno/tm2/pkg/iavl/nodedb.go:136 +0x85 fp=0xc02d017bb8 sp=0xc02d017b98 pc=0x4e2c665
github.com/gnolang/gno/tm2/pkg/iavl.(*nodeDB).SaveBranch(0xc0000e0140, 0xc02b578840)
        gno/tm2/pkg/iavl/nodedb.go:133 +0x3a fp=0xc02d017bd8 sp=0xc02d017bb8 pc=0x4e2c61a
github.com/gnolang/gno/tm2/pkg/iavl.(*nodeDB).SaveBranch(0xc0000e0140, 0xc02b578790)
        gno/tm2/pkg/iavl/nodedb.go:136 +0x85 fp=0xc02d017bf8 sp=0xc02d017bd8 pc=0x4e2c665
github.com/gnolang/gno/tm2/pkg/iavl.(*nodeDB).SaveBranch(0xc0000e0140, 0xc02b845600)
        gno/tm2/pkg/iavl/nodedb.go:133 +0x3a fp=0xc02d017c18 sp=0xc02d017bf8 pc=0x4e2c61a
github.com/gnolang/gno/tm2/pkg/iavl.(*nodeDB).SaveBranch(0xc0000e0140, 0xc02b8a58c0)
        gno/tm2/pkg/iavl/nodedb.go:136 +0x85 fp=0xc02d017c38 sp=0xc02d017c18 pc=0x4e2c665
github.com/gnolang/gno/tm2/pkg/iavl.(*nodeDB).SaveBranch(0xc0000e0140, 0xc028b6ba20)
        gno/tm2/pkg/iavl/nodedb.go:133 +0x3a fp=0xc02d017c58 sp=0xc02d017c38 pc=0x4e2c61a
github.com/gnolang/gno/tm2/pkg/iavl.(*nodeDB).SaveBranch(0xc0000e0140, 0xc028b8af20)
        gno/tm2/pkg/iavl/nodedb.go:133 +0x3a fp=0xc02d017c78 sp=0xc02d017c58 pc=0x4e2c61a
github.com/gnolang/gno/tm2/pkg/iavl.(*nodeDB).SaveBranch(0xc0000e0140, 0xc028b9d4a0)
        gno/tm2/pkg/iavl/nodedb.go:136 +0x85 fp=0xc02d017c98 sp=0xc02d017c78 pc=0x4e2c665
github.com/gnolang/gno/tm2/pkg/iavl.(*nodeDB).SaveBranch(0xc0000e0140, 0xc028ba9a20)
        gno/tm2/pkg/iavl/nodedb.go:133 +0x3a fp=0xc02d017cb8 sp=0xc02d017c98 pc=0x4e2c61a
github.com/gnolang/gno/tm2/pkg/iavl.(*nodeDB).SaveBranch(0xc0000e0140, 0xc028ba9970)
        gno/tm2/pkg/iavl/nodedb.go:133 +0x3a fp=0xc02d017cd8 sp=0xc02d017cb8 pc=0x4e2c61a
github.com/gnolang/gno/tm2/pkg/iavl.(*nodeDB).SaveBranch(0xc0000e0140, 0xc028ba98c0)
        gno/tm2/pkg/iavl/nodedb.go:136 +0x85 fp=0xc02d017cf8 sp=0xc02d017cd8 pc=0x4e2c665
github.com/gnolang/gno/tm2/pkg/iavl.(*MutableTree).SaveVersion(0xc0001c6040)
        gno/tm2/pkg/iavl/mutable_tree.go:402 +0x9f fp=0xc02d017db8 sp=0xc02d017cf8 pc=0x4e28a3f
github.com/gnolang/gno/tm2/pkg/iavl/benchmarks.commitTree(0xc0000e4788, 0xc0001c6040)
        gno/tm2/pkg/iavl/benchmarks/bench_test.go:48 +0x39 fp=0xc02d017e10 sp=0xc02d017db8 pc=0x4e351d9
github.com/gnolang/gno/tm2/pkg/iavl/benchmarks.prepareTree(0xc0000e4788, {0x501d458, 0xc000000018}, 0xf4240, 0x10, 0x28)
        gno/tm2/pkg/iavl/benchmarks/bench_test.go:38 +0x19d fp=0xc02d017e88 sp=0xc02d017e10 pc=0x4e3511d
github.com/gnolang/gno/tm2/pkg/iavl/benchmarks.runSuite(0xc0000e4788, {0x501d458, 0xc000000018}, 0xf4240, 0x64, 0x10, 0x28)
        gno/tm2/pkg/iavl/benchmarks/bench_test.go:250 +0xa7 fp=0xc02d017f08 sp=0xc02d017e88 pc=0x4e36a67
github.com/gnolang/gno/tm2/pkg/iavl/benchmarks.runBenchmarks.func2(0xc0000e4788?)
        gno/tm2/pkg/iavl/benchmarks/bench_test.go:229 +0x2b fp=0xc02d017f50 sp=0xc02d017f08 pc=0x4e3680b
testing.(*B).runN(0xc0000e4788, 0x1)
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/testing/benchmark.go:193 +0xf8 fp=0xc02d017fa0 sp=0xc02d017f50 pc=0x4c4c198
testing.(*B).run1.func1()
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/testing/benchmark.go:215 +0x4e fp=0xc02d017fe0 sp=0xc02d017fa0 pc=0x4c4c7ce
runtime.goexit({})
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/runtime/asm_amd64.s:1695 +0x1 fp=0xc02d017fe8 sp=0xc02d017fe0 pc=0x4bcc121
created by testing.(*B).run1 in goroutine 9
        /Users/sergio/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.darwin-amd64/src/testing/benchmark.go:208 +0x90

rax    0x104
rbx    0x16
rcx    0x7ff7bc3a69f8
rdx    0x8c400
rdi    0x525c8c8
rsi    0x8c4010008c500
rbp    0x7ff7bc3a6a90
rsp    0x7ff7bc3a69f8
r8     0x0
r9     0xa0
r10    0x0
r11    0x246
r12    0x0
r13    0x8c4010008c500
r14    0x7ff847045fc0
r15    0x8c400
rip    0x7ff803ac7f7a
rflags 0x247
cs     0x7
fs     0x0
gs     0x0
*** Test killed with quit: ran too long (11m0s).
exit status 2
@zivkovicmilos zivkovicmilos added 🐞 bug Something isn't working ⭐️ could have ⭐️ Optional work needed to complete a project 🤝 open for contributors 🤝 Work available to external contributors labels Sep 11, 2024
@thehowl
Copy link
Member

thehowl commented Sep 13, 2024

This seems to be a timeout judging by the final lines. In practice, I think it's just that especially for the bad usage we make of it, using Boltdb is extremely slow for this benchmark. A simple solution is to skip boltdb as a backend:

diff --git a/tm2/pkg/iavl/benchmarks/bench_test.go b/tm2/pkg/iavl/benchmarks/bench_test.go
index 88de3634..7bada156 100644
--- a/tm2/pkg/iavl/benchmarks/bench_test.go
+++ b/tm2/pkg/iavl/benchmarks/bench_test.go
@@ -173,6 +173,9 @@ func BenchmarkLarge(b *testing.B) {
 	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)

Maybe add this in #2716, with an explanatory comment linking to this issue.

goleveldb seems to run fine; took less than a minute on my laptop.

sw360cab added a commit that referenced this issue Sep 26, 2024
## Things changes

* using new action plugin:
[benchmark-action/github-action-benchmark](https://github.com/benchmark-action/github-action-benchmark)
* previous library was
[bobheadxi/gobenchdata](https://github.com/bobheadxi/gobenchdata)
* creating alerts when benchmarks results are worse

## Things unchanged

* Pushing benchmarks results onto a local branch, then `benchmark`
repository will fetch from this into his own `gh-pages`
  * direct push is possible but requires PAT token to be used 

## Things TODO (before merging)

* restore benchmarks actions which were manually disabled directly in
the `Action` menu in Github
* drop and recreate branch  `gh-repository`
* fix benchmark tests in Gno repo (see #2711 and #2714)
* Evaluate alternative configuration possibilities
[here](https://github.com/benchmark-action/github-action-benchmark?tab=readme-ov-file#action-inputs)

## Things to consider (performance)

* Should solve #2432 
* are resources available in the Github basic runners enough for
benchmarks?
* are multiple runs spawned in the same hw conditions?
* consider using [Larger
Runner](https://docs.github.com/en/actions/using-github-hosted-runners/using-larger-runners/managing-larger-runners#adding-a-larger-runner-to-an-organization)
or restoring a [Self-Hosted
Runner](https://docs.github.com/en/actions/hosting-your-own-runners/managing-self-hosted-runners/adding-self-hosted-runners#adding-a-self-hosted-runner-to-an-organization)
@ajnavarro
Copy link
Contributor

Fixed at #2854

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🐞 bug Something isn't working ⭐️ could have ⭐️ Optional work needed to complete a project 🤝 open for contributors 🤝 Work available to external contributors
Development

No branches or pull requests

4 participants