ferranbt / fastssz

Fast Ethereum2.0 SSZ encoder/decoder
MIT License
74 stars 44 forks source link

bug(generator): Type Alias on byteslice causes generator to panic #158

Open itsdevbear opened 5 months ago

itsdevbear commented 5 months ago

for instance hexutil.Bytes from geth

Works:

type MyType struct {
    MyField []byte
}

Panics

import "github.com/ethereum/go-ethereum/common/hexutil"

type MyType struct {
    MyField []hexutil.Bytes
}

Callstack

runtime: goroutine stack exceeds 1000000000-byte limit
runtime: sp=0x14020680380 stack=[0x14020680000, 0x14040680000]
fatal error: stack overflow

runtime stack:
runtime.throw({0x1001a26b8?, 0x100072e74?})
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/panic.go:1023 +0x40 fp=0x16ffe6d20 sp=0x16ffe6cf0 pc=0x10007ae90
runtime.newstack()
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/stack.go:1103 +0x460 fp=0x16ffe6ed0 sp=0x16ffe6d20 pc=0x100095e90
runtime.morestack()
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/asm_arm64.s:341 +0x70 fp=0x16ffe6ed0 sp=0x16ffe6ed0 pc=0x1000abac0

goroutine 1 gp=0x140000021c0 m=4 mp=0x14000088008 [running]:
runtime.deductAssistCredit(0x70?)
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/malloc.go:1337 +0x7c fp=0x14020680380 sp=0x14020680380 pc=0x10005380c
runtime.mallocgc(0x70, 0x1001f3d40, 0x1)
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/malloc.go:1025 +0xe8 fp=0x14020680410 sp=0x14020680380 pc=0x100052f78
runtime.makeslice(0x140001cd141?, 0x0?, 0x1001e16e8?)
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/slice.go:107 +0x50 fp=0x14020680440 sp=0x14020680410 pc=0x100093bb0
strings.genSplit({0x140001cd141, 0x37}, {0x1001e16e8, 0x1}, 0x0, 0x0?)
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/strings/strings.go:249 +0x6c fp=0x140206804a0 sp=0x14020680440 pc=0x10012280c
strings.Split(...)
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/strings/strings.go:307
github.com/ferranbt/fastssz/sszgen/generator.getTags({0x140001cd140?, 0x18?}, {0x1001a07b3, 0x3})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:1209 +0x4c fp=0x14020680520 sp=0x140206804a0 pc=0x1001979ac
github.com/ferranbt/fastssz/sszgen/generator.(*env).parseASTFieldType(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39}, {0x1002274d0, 0x1400010ad98})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:994 +0x54 fp=0x14020680680 sp=0x14020680520 pc=0x100196a14
github.com/ferranbt/fastssz/sszgen/generator.(*env).encodeItem(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:898 +0x150 fp=0x14020680740 sp=0x14020680680 pc=0x100196000
github.com/ferranbt/fastssz/sszgen/generator.(*env).parseASTFieldType(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39}, {0x1002274d0, 0x1400010ad98})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:1175 +0x7f8 fp=0x140206808a0 sp=0x14020680740 pc=0x1001971b8
github.com/ferranbt/fastssz/sszgen/generator.(*env).encodeItem(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:898 +0x150 fp=0x14020680960 sp=0x140206808a0 pc=0x100196000
github.com/ferranbt/fastssz/sszgen/generator.(*env).parseASTFieldType(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39}, {0x1002274d0, 0x1400010ad98})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:1175 +0x7f8 fp=0x14020680ac0 sp=0x14020680960 pc=0x1001971b8
github.com/ferranbt/fastssz/sszgen/generator.(*env).encodeItem(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:898 +0x150 fp=0x14020680b80 sp=0x14020680ac0 pc=0x100196000
github.com/ferranbt/fastssz/sszgen/generator.(*env).parseASTFieldType(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39}, {0x1002274d0, 0x1400010ad98})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:1175 +0x7f8 fp=0x14020680ce0 sp=0x14020680b80 pc=0x1001971b8
github.com/ferranbt/fastssz/sszgen/generator.(*env).encodeItem(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:898 +0x150 fp=0x14020680da0 sp=0x14020680ce0 pc=0x100196000
github.com/ferranbt/fastssz/sszgen/generator.(*env).parseASTFieldType(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39}, {0x1002274d0, 0x1400010ad98})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:1175 +0x7f8 fp=0x14020680f00 sp=0x14020680da0 pc=0x1001971b8
github.com/ferranbt/fastssz/sszgen/generator.(*env).encodeItem(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:898 +0x150 fp=0x14020680fc0 sp=0x14020680f00 pc=0x100196000
github.com/ferranbt/fastssz/sszgen/generator.(*env).parseASTFieldType(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39}, {0x1002274d0, 0x1400010ad98})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:1175 +0x7f8 fp=0x14020681120 sp=0x14020680fc0 pc=0x1001971b8
github.com/ferranbt/fastssz/sszgen/generator.(*env).encodeItem(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:898 +0x150 fp=0x140206811e0 sp=0x14020681120 pc=0x100196000
github.com/ferranbt/fastssz/sszgen/generator.(*env).parseASTFieldType(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39}, {0x1002274d0, 0x1400010ad98})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:1175 +0x7f8 fp=0x14020681340 sp=0x140206811e0 pc=0x1001971b8
github.com/ferranbt/fastssz/sszgen/generator.(*env).encodeItem(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:898 +0x150 fp=0x14020681400 sp=0x14020681340 pc=0x100196000
github.com/ferranbt/fastssz/sszgen/generator.(*env).parseASTFieldType(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39}, {0x1002274d0, 0x1400010ad98})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:1175 +0x7f8 fp=0x14020681560 sp=0x14020681400 pc=0x1001971b8
github.com/ferranbt/fastssz/sszgen/generator.(*env).encodeItem(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:898 +0x150 fp=0x14020681620 sp=0x14020681560 pc=0x100196000
github.com/ferranbt/fastssz/sszgen/generator.(*env).parseASTFieldType(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39}, {0x1002274d0, 0x1400010ad98})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:1175 +0x7f8 fp=0x14020681780 sp=0x14020681620 pc=0x1001971b8
github.com/ferranbt/fastssz/sszgen/generator.(*env).encodeItem(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:898 +0x150 fp=0x14020681840 sp=0x14020681780 pc=0x100196000
github.com/ferranbt/fastssz/sszgen/generator.(*env).parseASTFieldType(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39}, {0x1002274d0, 0x1400010ad98})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:1175 +0x7f8 fp=0x140206819a0 sp=0x14020681840 pc=0x1001971b8
github.com/ferranbt/fastssz/sszgen/generator.(*env).encodeItem(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:898 +0x150 fp=0x14020681a60 sp=0x140206819a0 pc=0x100196000
github.com/ferranbt/fastssz/sszgen/generator.(*env).parseASTFieldType(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39}, {0x1002274d0, 0x1400010ad98})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:1175 +0x7f8 fp=0x14020681bc0 sp=0x14020681a60 pc=0x1001971b8
github.com/ferranbt/fastssz/sszgen/generator.(*env).encodeItem(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:898 +0x150 fp=0x14020681c80 sp=0x14020681bc0 pc=0x100196000
github.com/ferranbt/fastssz/sszgen/generator.(*env).parseASTFieldType(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39}, {0x1002274d0, 0x1400010ad98})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:1175 +0x7f8 fp=0x14020681de0 sp=0x14020681c80 pc=0x1001971b8
github.com/ferranbt/fastssz/sszgen/generator.(*env).encodeItem(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:898 +0x150 fp=0x14020681ea0 sp=0x14020681de0 pc=0x100196000
github.com/ferranbt/fastssz/sszgen/generator.(*env).parseASTFieldType(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39}, {0x1002274d0, 0x1400010ad98})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:1175 +0x7f8 fp=0x14020682000 sp=0x14020681ea0 pc=0x1001971b8
github.com/ferranbt/fastssz/sszgen/generator.(*env).encodeItem(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:898 +0x150 fp=0x140206820c0 sp=0x14020682000 pc=0x100196000
github.com/ferranbt/fastssz/sszgen/generator.(*env).parseASTFieldType(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39}, {0x1002274d0, 0x1400010ad98})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:1175 +0x7f8 fp=0x14020682220 sp=0x140206820c0 pc=0x1001971b8
github.com/ferranbt/fastssz/sszgen/generator.(*env).encodeItem(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:898 +0x150 fp=0x140206822e0 sp=0x14020682220 pc=0x100196000
github.com/ferranbt/fastssz/sszgen/generator.(*env).parseASTFieldType(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39}, {0x1002274d0, 0x1400010ad98})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:1175 +0x7f8 fp=0x14020682440 sp=0x140206822e0 pc=0x1001971b8
github.com/ferranbt/fastssz/sszgen/generator.(*env).encodeItem(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:898 +0x150 fp=0x14020682500 sp=0x14020682440 pc=0x100196000
github.com/ferranbt/fastssz/sszgen/generator.(*env).parseASTFieldType(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39}, {0x1002274d0, 0x1400010ad98})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:1175 +0x7f8 fp=0x14020682660 sp=0x14020682500 pc=0x1001971b8
github.com/ferranbt/fastssz/sszgen/generator.(*env).encodeItem(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:898 +0x150 fp=0x14020682720 sp=0x14020682660 pc=0x100196000
github.com/ferranbt/fastssz/sszgen/generator.(*env).parseASTFieldType(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39}, {0x1002274d0, 0x1400010ad98})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:1175 +0x7f8 fp=0x14020682880 sp=0x14020682720 pc=0x1001971b8
github.com/ferranbt/fastssz/sszgen/generator.(*env).encodeItem(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:898 +0x150 fp=0x14020682940 sp=0x14020682880 pc=0x100196000
github.com/ferranbt/fastssz/sszgen/generator.(*env).parseASTFieldType(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39}, {0x1002274d0, 0x1400010ad98})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:1175 +0x7f8 fp=0x14020682aa0 sp=0x14020682940 pc=0x1001971b8
github.com/ferranbt/fastssz/sszgen/generator.(*env).encodeItem(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:898 +0x150 fp=0x14020682b60 sp=0x14020682aa0 pc=0x100196000
github.com/ferranbt/fastssz/sszgen/generator.(*env).parseASTFieldType(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39}, {0x1002274d0, 0x1400010ad98})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:1175 +0x7f8 fp=0x14020682cc0 sp=0x14020682b60 pc=0x1001971b8
github.com/ferranbt/fastssz/sszgen/generator.(*env).encodeItem(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:898 +0x150 fp=0x14020682d80 sp=0x14020682cc0 pc=0x100196000
github.com/ferranbt/fastssz/sszgen/generator.(*env).parseASTFieldType(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39}, {0x1002274d0, 0x1400010ad98})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:1175 +0x7f8 fp=0x14020682ee0 sp=0x14020682d80 pc=0x1001971b8
github.com/ferranbt/fastssz/sszgen/generator.(*env).encodeItem(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:898 +0x150 fp=0x14020682fa0 sp=0x14020682ee0 pc=0x100196000
github.com/ferranbt/fastssz/sszgen/generator.(*env).parseASTFieldType(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39}, {0x1002274d0, 0x1400010ad98})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:1175 +0x7f8 fp=0x14020683100 sp=0x14020682fa0 pc=0x1001971b8
github.com/ferranbt/fastssz/sszgen/generator.(*env).encodeItem(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:898 +0x150 fp=0x140206831c0 sp=0x14020683100 pc=0x100196000
github.com/ferranbt/fastssz/sszgen/generator.(*env).parseASTFieldType(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39}, {0x1002274d0, 0x1400010ad98})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:1175 +0x7f8 fp=0x14020683320 sp=0x140206831c0 pc=0x1001971b8
github.com/ferranbt/fastssz/sszgen/generator.(*env).encodeItem(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:898 +0x150 fp=0x140206833e0 sp=0x14020683320 pc=0x100196000
...1973691 frames elided...
github.com/ferranbt/fastssz/sszgen/generator.(*env).encodeItem(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:898 +0x150 fp=0x1404067cba0 sp=0x1404067cae0 pc=0x100196000
github.com/ferranbt/fastssz/sszgen/generator.(*env).parseASTFieldType(0x1400011bcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39}, {0x1002274d0, 0x1400010ad98})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:1175 +0x7f8 fp=0x1404067cd00 sp=0x1404067cba0 pc=0x1001971b8
github.com/ferranbt/fastssz/sszgen/generator.(*env).encodeItem(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:898 +0x150 fp=0x1404067cdc0 sp=0x1404067cd00 pc=0x100196000
github.com/ferranbt/fastssz/sszgen/generator.(*env).parseASTFieldType(0x1400011bcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39}, {0x1002274d0, 0x1400010ad98})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:1175 +0x7f8 fp=0x1404067cf20 sp=0x1404067cdc0 pc=0x1001971b8
github.com/ferranbt/fastssz/sszgen/generator.(*env).encodeItem(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:898 +0x150 fp=0x1404067cfe0 sp=0x1404067cf20 pc=0x100196000
github.com/ferranbt/fastssz/sszgen/generator.(*env).parseASTFieldType(0x1400011bcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39}, {0x1002274d0, 0x1400010ad98})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:1175 +0x7f8 fp=0x1404067d140 sp=0x1404067cfe0 pc=0x1001971b8
github.com/ferranbt/fastssz/sszgen/generator.(*env).encodeItem(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:898 +0x150 fp=0x1404067d200 sp=0x1404067d140 pc=0x100196000
github.com/ferranbt/fastssz/sszgen/generator.(*env).parseASTFieldType(0x1400011bcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39}, {0x1002274d0, 0x1400010ad98})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:1175 +0x7f8 fp=0x1404067d360 sp=0x1404067d200 pc=0x1001971b8
github.com/ferranbt/fastssz/sszgen/generator.(*env).encodeItem(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:898 +0x150 fp=0x1404067d420 sp=0x1404067d360 pc=0x100196000
github.com/ferranbt/fastssz/sszgen/generator.(*env).parseASTFieldType(0x1400011bcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39}, {0x1002274d0, 0x1400010ad98})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:1175 +0x7f8 fp=0x1404067d580 sp=0x1404067d420 pc=0x1001971b8
github.com/ferranbt/fastssz/sszgen/generator.(*env).encodeItem(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:898 +0x150 fp=0x1404067d640 sp=0x1404067d580 pc=0x100196000
github.com/ferranbt/fastssz/sszgen/generator.(*env).parseASTFieldType(0x1400011bcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39}, {0x1002274d0, 0x1400010ad98})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:1175 +0x7f8 fp=0x1404067d7a0 sp=0x1404067d640 pc=0x1001971b8
github.com/ferranbt/fastssz/sszgen/generator.(*env).encodeItem(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:898 +0x150 fp=0x1404067d860 sp=0x1404067d7a0 pc=0x100196000
github.com/ferranbt/fastssz/sszgen/generator.(*env).parseASTFieldType(0x1400011bcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39}, {0x1002274d0, 0x1400010ad98})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:1175 +0x7f8 fp=0x1404067d9c0 sp=0x1404067d860 pc=0x1001971b8
github.com/ferranbt/fastssz/sszgen/generator.(*env).encodeItem(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:898 +0x150 fp=0x1404067da80 sp=0x1404067d9c0 pc=0x100196000
github.com/ferranbt/fastssz/sszgen/generator.(*env).parseASTFieldType(0x1400011bcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39}, {0x1002274d0, 0x1400010ad98})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:1175 +0x7f8 fp=0x1404067dbe0 sp=0x1404067da80 pc=0x1001971b8
github.com/ferranbt/fastssz/sszgen/generator.(*env).encodeItem(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:898 +0x150 fp=0x1404067dca0 sp=0x1404067dbe0 pc=0x100196000
github.com/ferranbt/fastssz/sszgen/generator.(*env).parseASTFieldType(0x1400011bcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39}, {0x1002274d0, 0x1400010ad98})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:1175 +0x7f8 fp=0x1404067de00 sp=0x1404067dca0 pc=0x1001971b8
github.com/ferranbt/fastssz/sszgen/generator.(*env).encodeItem(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:898 +0x150 fp=0x1404067dec0 sp=0x1404067de00 pc=0x100196000
github.com/ferranbt/fastssz/sszgen/generator.(*env).parseASTFieldType(0x1400011bcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39}, {0x1002274d0, 0x1400010ad98})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:1175 +0x7f8 fp=0x1404067e020 sp=0x1404067dec0 pc=0x1001971b8
github.com/ferranbt/fastssz/sszgen/generator.(*env).encodeItem(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:898 +0x150 fp=0x1404067e0e0 sp=0x1404067e020 pc=0x100196000
github.com/ferranbt/fastssz/sszgen/generator.(*env).parseASTFieldType(0x1400011bcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39}, {0x1002274d0, 0x1400010ad98})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:1175 +0x7f8 fp=0x1404067e240 sp=0x1404067e0e0 pc=0x1001971b8
github.com/ferranbt/fastssz/sszgen/generator.(*env).encodeItem(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:898 +0x150 fp=0x1404067e300 sp=0x1404067e240 pc=0x100196000
github.com/ferranbt/fastssz/sszgen/generator.(*env).parseASTFieldType(0x1400011bcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39}, {0x1002274d0, 0x1400010ad98})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:1175 +0x7f8 fp=0x1404067e460 sp=0x1404067e300 pc=0x1001971b8
github.com/ferranbt/fastssz/sszgen/generator.(*env).encodeItem(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:898 +0x150 fp=0x1404067e520 sp=0x1404067e460 pc=0x100196000
github.com/ferranbt/fastssz/sszgen/generator.(*env).parseASTFieldType(0x1400011bcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39}, {0x1002274d0, 0x1400010ad98})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:1175 +0x7f8 fp=0x1404067e680 sp=0x1404067e520 pc=0x1001971b8
github.com/ferranbt/fastssz/sszgen/generator.(*env).encodeItem(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:898 +0x150 fp=0x1404067e740 sp=0x1404067e680 pc=0x100196000
github.com/ferranbt/fastssz/sszgen/generator.(*env).parseASTFieldType(0x1400011bcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39}, {0x1002274d0, 0x1400010ad98})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:1175 +0x7f8 fp=0x1404067e8a0 sp=0x1404067e740 pc=0x1001971b8
github.com/ferranbt/fastssz/sszgen/generator.(*env).encodeItem(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:898 +0x150 fp=0x1404067e960 sp=0x1404067e8a0 pc=0x100196000
github.com/ferranbt/fastssz/sszgen/generator.(*env).parseASTFieldType(0x1400011bcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39}, {0x1002274d0, 0x1400010ad98})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:1175 +0x7f8 fp=0x1404067eac0 sp=0x1404067e960 pc=0x1001971b8
github.com/ferranbt/fastssz/sszgen/generator.(*env).encodeItem(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:898 +0x150 fp=0x1404067eb80 sp=0x1404067eac0 pc=0x100196000
github.com/ferranbt/fastssz/sszgen/generator.(*env).parseASTFieldType(0x1400011bcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39}, {0x1002274d0, 0x1400010ad98})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:1175 +0x7f8 fp=0x1404067ece0 sp=0x1404067eb80 pc=0x1001971b8
github.com/ferranbt/fastssz/sszgen/generator.(*env).encodeItem(0x1404067fcc0, {0x140000b1330, 0x5}, {0x140001cd140, 0x39})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:898 +0x150 fp=0x1404067eda0 sp=0x1404067ece0 pc=0x100196000
github.com/ferranbt/fastssz/sszgen/generator.(*env).parseASTFieldType(0x1400011bcc0, {0x1400019f7c0, 0x5}, {0x140001cd140, 0x39}, {0x1002274d0, 0x1400010ad98})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:1175 +0x7f8 fp=0x1404067ef00 sp=0x1404067eda0 pc=0x1001971b8
github.com/ferranbt/fastssz/sszgen/generator.(*env).encodeItem(0x1404067fcc0, {0x1400019f7c0, 0x5}, {0x140001cd140, 0x39})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:898 +0x150 fp=0x1404067efc0 sp=0x1404067ef00 pc=0x100196000
github.com/ferranbt/fastssz/sszgen/generator.(*env).parseASTFieldType(0x1400011bcc0, {0x1400019f7b0, 0x9}, {0x140001cd140, 0x39}, {0x1002274d0, 0x140001d65e8})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:1175 +0x7f8 fp=0x1404067f120 sp=0x1404067efc0 pc=0x1001971b8
github.com/ferranbt/fastssz/sszgen/generator.(*env).parseASTStructType(0x1404067fcc0, {0x140000b4150, 0x13})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:978 +0x1b8 fp=0x1404067f2a0 sp=0x1404067f120 pc=0x1001963c8
github.com/ferranbt/fastssz/sszgen/generator.(*env).encodeItem(0x1404067fcc0, {0x140000b4150, 0x13}, {0x0, 0x0})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:896 +0x12c fp=0x1404067f360 sp=0x1404067f2a0 pc=0x100195fdc
github.com/ferranbt/fastssz/sszgen/generator.(*env).parseASTFieldType(0x1400011bcc0, {0x140000b05b0, 0x10}, {0x0, 0x0}, {0x100227470, 0x140000c4ea0})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:1011 +0x954 fp=0x1404067f4c0 sp=0x1404067f360 pc=0x100197314
github.com/ferranbt/fastssz/sszgen/generator.(*env).parseASTStructType(0x1404067fcc0, {0x140000b4048, 0x14})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:978 +0x1b8 fp=0x1404067f640 sp=0x1404067f4c0 pc=0x1001963c8
github.com/ferranbt/fastssz/sszgen/generator.(*env).encodeItem(0x1404067fcc0, {0x140000b4048, 0x14}, {0x0, 0x0})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:896 +0x12c fp=0x1404067f700 sp=0x1404067f640 pc=0x100195fdc
github.com/ferranbt/fastssz/sszgen/generator.(*env).parseASTFieldType(0x1400011bcc0, {0x140000b0170, 0x4}, {0x0, 0x0}, {0x100227470, 0x140000c4450})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:1005 +0x9e8 fp=0x1404067f860 sp=0x1404067f700 pc=0x1001973a8
github.com/ferranbt/fastssz/sszgen/generator.(*env).parseASTStructType(0x1404067fcc0, {0x140000b00c0, 0x10})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:978 +0x1b8 fp=0x1404067f9e0 sp=0x1404067f860 pc=0x1001963c8
github.com/ferranbt/fastssz/sszgen/generator.(*env).encodeItem(0x1404067fcc0, {0x140000b00c0, 0x10}, {0x0, 0x0})
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:896 +0x12c fp=0x1404067faa0 sp=0x1404067f9e0 pc=0x100195fdc
github.com/ferranbt/fastssz/sszgen/generator.(*env).generateIR(0x1404067fcc0)
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:856 +0x53c fp=0x1404067fc40 sp=0x1404067faa0 pc=0x10019568c
github.com/ferranbt/fastssz/sszgen/generator.Encode({0x16fdbb1b3, 0x8}, {0x140000980b0, 0x1, 0x1}, {0x16fdbb315, 0xc}, {0x140000ca070, 0x7, 0x10004c84c?}, ...)
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/generator/generator.go:68 +0x200 fp=0x1404067fde0 sp=0x1404067fc40 pc=0x100192400
main.generate()
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/main.go:59 +0x4e4 fp=0x1404067fef0 sp=0x1404067fde0 pc=0x1001a0234
main.main()
        /Users/dev/go/pkg/mod/github.com/ferranbt/fastssz@v0.1.4-0.20240409113215-d6fd7ab64065/sszgen/main.go:24 +0xe0 fp=0x1404067ff40 sp=0x1404067fef0 pc=0x10019fd20
runtime.main()
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/proc.go:271 +0x28c fp=0x1404067ffd0 sp=0x1404067ff40 pc=0x10007d7cc
runtime.goexit({})
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/asm_arm64.s:1222 +0x4 fp=0x1404067ffd0 sp=0x1404067ffd0 pc=0x1000add34

goroutine 2 gp=0x14000002700 m=nil [force gc (idle)]:
runtime.gopark(0x0?, 0x0?, 0x0?, 0x0?, 0x0?)
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/proc.go:402 +0xc8 fp=0x14000062f90 sp=0x14000062f70 pc=0x10007dbf8
runtime.goparkunlock(...)
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/proc.go:408
runtime.forcegchelper()
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/proc.go:326 +0xb8 fp=0x14000062fd0 sp=0x14000062f90 pc=0x10007da88
runtime.goexit({})
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/asm_arm64.s:1222 +0x4 fp=0x14000062fd0 sp=0x14000062fd0 pc=0x1000add34
created by runtime.init.6 in goroutine 1
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/proc.go:314 +0x24

goroutine 17 gp=0x1400008c380 m=nil [GC sweep wait]:
runtime.gopark(0x1?, 0x0?, 0x0?, 0x0?, 0x0?)
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/proc.go:402 +0xc8 fp=0x1400005e760 sp=0x1400005e740 pc=0x10007dbf8
runtime.goparkunlock(...)
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/proc.go:408
runtime.bgsweep(0x14000096000)
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/mgcsweep.go:318 +0x108 fp=0x1400005e7b0 sp=0x1400005e760 pc=0x100069f08
runtime.gcenable.gowrap1()
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/mgc.go:203 +0x28 fp=0x1400005e7d0 sp=0x1400005e7b0 pc=0x10005e0a8
runtime.goexit({})
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/asm_arm64.s:1222 +0x4 fp=0x1400005e7d0 sp=0x1400005e7d0 pc=0x1000add34
created by runtime.gcenable in goroutine 1
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/mgc.go:203 +0x6c

goroutine 18 gp=0x1400008c540 m=nil [GC scavenge wait]:
runtime.gopark(0x10000?, 0x1001e06b0?, 0x0?, 0x0?, 0x0?)
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/proc.go:402 +0xc8 fp=0x1400005ef60 sp=0x1400005ef40 pc=0x10007dbf8
runtime.goparkunlock(...)
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/proc.go:408
runtime.(*scavengerState).park(0x100331e80)
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/mgcscavenge.go:425 +0x5c fp=0x1400005ef90 sp=0x1400005ef60 pc=0x10006788c
runtime.bgscavenge(0x14000096000)
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/mgcscavenge.go:658 +0xac fp=0x1400005efb0 sp=0x1400005ef90 pc=0x100067e4c
runtime.gcenable.gowrap2()
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/mgc.go:204 +0x28 fp=0x1400005efd0 sp=0x1400005efb0 pc=0x10005e048
runtime.goexit({})
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/asm_arm64.s:1222 +0x4 fp=0x1400005efd0 sp=0x1400005efd0 pc=0x1000add34
created by runtime.gcenable in goroutine 1
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/mgc.go:204 +0xac

goroutine 19 gp=0x1400008c700 m=nil [finalizer wait]:
runtime.gopark(0x0?, 0x0?, 0x35?, 0x0?, 0x10005b804?)
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/proc.go:402 +0xc8 fp=0x14000062580 sp=0x14000062560 pc=0x10007dbf8
runtime.runfinq()
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/mfinal.go:194 +0x108 fp=0x140000627d0 sp=0x14000062580 pc=0x10005d178
runtime.goexit({})
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/asm_arm64.s:1222 +0x4 fp=0x140000627d0 sp=0x140000627d0 pc=0x1000add34
created by runtime.createfing in goroutine 1
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/mfinal.go:164 +0x80

goroutine 20 gp=0x1400008c8c0 m=nil [GC worker (idle)]:
runtime.gopark(0x0?, 0x0?, 0x0?, 0x0?, 0x0?)
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/proc.go:402 +0xc8 fp=0x1400005f730 sp=0x1400005f710 pc=0x10007dbf8
runtime.gcBgMarkWorker()
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/mgc.go:1310 +0xd8 fp=0x1400005f7d0 sp=0x1400005f730 pc=0x1000601a8
runtime.goexit({})
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/asm_arm64.s:1222 +0x4 fp=0x1400005f7d0 sp=0x1400005f7d0 pc=0x1000add34
created by runtime.gcBgMarkStartWorkers in goroutine 1
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/mgc.go:1234 +0x28

goroutine 21 gp=0x1400008ca80 m=nil [GC worker (idle)]:
runtime.gopark(0x0?, 0x0?, 0x0?, 0x0?, 0x0?)
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/proc.go:402 +0xc8 fp=0x1400005ff30 sp=0x1400005ff10 pc=0x10007dbf8
runtime.gcBgMarkWorker()
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/mgc.go:1310 +0xd8 fp=0x1400005ffd0 sp=0x1400005ff30 pc=0x1000601a8
runtime.goexit({})
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/asm_arm64.s:1222 +0x4 fp=0x1400005ffd0 sp=0x1400005ffd0 pc=0x1000add34
created by runtime.gcBgMarkStartWorkers in goroutine 1
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/mgc.go:1234 +0x28

goroutine 33 gp=0x14000114000 m=nil [GC worker (idle)]:
runtime.gopark(0x5?, 0x140001cd140?, 0x39?, 0x0?, 0x1002274d0?)
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/proc.go:402 +0xc8 fp=0x14000422730 sp=0x14000422710 pc=0x10007dbf8
runtime.gcBgMarkWorker()
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/mgc.go:1310 +0xd8 fp=0x140004227d0 sp=0x14000422730 pc=0x1000601a8
runtime.goexit({})
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/asm_arm64.s:1222 +0x4 fp=0x140004227d0 sp=0x140004227d0 pc=0x1000add34
created by runtime.gcBgMarkStartWorkers in goroutine 1
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/mgc.go:1234 +0x28

goroutine 34 gp=0x140001141c0 m=nil [GC worker (idle)]:
runtime.gopark(0x0?, 0x10?, 0x78?, 0x2f?, 0x10012280c?)
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/proc.go:402 +0xc8 fp=0x14000422f30 sp=0x14000422f10 pc=0x10007dbf8
runtime.gcBgMarkWorker()
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/mgc.go:1310 +0xd8 fp=0x14000422fd0 sp=0x14000422f30 pc=0x1000601a8
runtime.goexit({})
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/asm_arm64.s:1222 +0x4 fp=0x14000422fd0 sp=0x14000422fd0 pc=0x1000add34
created by runtime.gcBgMarkStartWorkers in goroutine 1
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/mgc.go:1234 +0x28

goroutine 35 gp=0x14000114380 m=nil [GC worker (idle)]:
runtime.gopark(0x3ebb3d18decd?, 0x100093bb0?, 0x0?, 0x0?, 0x0?)
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/proc.go:402 +0xc8 fp=0x14000423730 sp=0x14000423710 pc=0x10007dbf8
runtime.gcBgMarkWorker()
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/mgc.go:1310 +0xd8 fp=0x140004237d0 sp=0x14000423730 pc=0x1000601a8
runtime.goexit({})
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/asm_arm64.s:1222 +0x4 fp=0x140004237d0 sp=0x140004237d0 pc=0x1000add34
created by runtime.gcBgMarkStartWorkers in goroutine 1
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/mgc.go:1234 +0x28

goroutine 3 gp=0x14000002fc0 m=nil [GC worker (idle)]:
runtime.gopark(0x3ebb3d19876c?, 0x3?, 0x6c?, 0x6b?, 0x0?)
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/proc.go:402 +0xc8 fp=0x14000063730 sp=0x14000063710 pc=0x10007dbf8
runtime.gcBgMarkWorker()
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/mgc.go:1310 +0xd8 fp=0x140000637d0 sp=0x14000063730 pc=0x1000601a8
runtime.goexit({})
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/asm_arm64.s:1222 +0x4 fp=0x140000637d0 sp=0x140000637d0 pc=0x1000add34
created by runtime.gcBgMarkStartWorkers in goroutine 1
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/mgc.go:1234 +0x28

goroutine 4 gp=0x14000003180 m=nil [GC worker (idle)]:
runtime.gopark(0x100398060?, 0x1?, 0x23?, 0x85?, 0x0?)
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/proc.go:402 +0xc8 fp=0x14000063f30 sp=0x14000063f10 pc=0x10007dbf8
runtime.gcBgMarkWorker()
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/mgc.go:1310 +0xd8 fp=0x14000063fd0 sp=0x14000063f30 pc=0x1000601a8
runtime.goexit({})
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/asm_arm64.s:1222 +0x4 fp=0x14000063fd0 sp=0x14000063fd0 pc=0x1000add34
created by runtime.gcBgMarkStartWorkers in goroutine 1
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/mgc.go:1234 +0x28

goroutine 5 gp=0x14000003340 m=nil [GC worker (idle)]:
runtime.gopark(0x3ebb3d19f231?, 0x1?, 0x15?, 0x49?, 0x0?)
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/proc.go:402 +0xc8 fp=0x14000064730 sp=0x14000064710 pc=0x10007dbf8
runtime.gcBgMarkWorker()
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/mgc.go:1310 +0xd8 fp=0x140000647d0 sp=0x14000064730 pc=0x1000601a8
runtime.goexit({})
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/asm_arm64.s:1222 +0x4 fp=0x140000647d0 sp=0x140000647d0 pc=0x1000add34
created by runtime.gcBgMarkStartWorkers in goroutine 1
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/mgc.go:1234 +0x28

goroutine 22 gp=0x1400008cc40 m=nil [GC worker (idle)]:
runtime.gopark(0x100398060?, 0x3?, 0x7?, 0xdf?, 0x0?)
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/proc.go:402 +0xc8 fp=0x14000060730 sp=0x14000060710 pc=0x10007dbf8
runtime.gcBgMarkWorker()
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/mgc.go:1310 +0xd8 fp=0x140000607d0 sp=0x14000060730 pc=0x1000601a8
runtime.goexit({})
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/asm_arm64.s:1222 +0x4 fp=0x140000607d0 sp=0x140000607d0 pc=0x1000add34
created by runtime.gcBgMarkStartWorkers in goroutine 1
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/mgc.go:1234 +0x28

goroutine 23 gp=0x1400008ce00 m=nil [GC worker (idle)]:
runtime.gopark(0x3ebb3d18ef3e?, 0x1?, 0x17?, 0xff?, 0x0?)
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/proc.go:402 +0xc8 fp=0x14000060f30 sp=0x14000060f10 pc=0x10007dbf8
runtime.gcBgMarkWorker()
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/mgc.go:1310 +0xd8 fp=0x14000060fd0 sp=0x14000060f30 pc=0x1000601a8
runtime.goexit({})
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/asm_arm64.s:1222 +0x4 fp=0x14000060fd0 sp=0x14000060fd0 pc=0x1000add34
created by runtime.gcBgMarkStartWorkers in goroutine 1
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/mgc.go:1234 +0x28

goroutine 6 gp=0x14000003500 m=nil [GC worker (idle)]:
runtime.gopark(0x3ebb3d18f22c?, 0x3?, 0x83?, 0xec?, 0x0?)
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/proc.go:402 +0xc8 fp=0x14000064f30 sp=0x14000064f10 pc=0x10007dbf8
runtime.gcBgMarkWorker()
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/mgc.go:1310 +0xd8 fp=0x14000064fd0 sp=0x14000064f30 pc=0x1000601a8
runtime.goexit({})
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/asm_arm64.s:1222 +0x4 fp=0x14000064fd0 sp=0x14000064fd0 pc=0x1000add34
created by runtime.gcBgMarkStartWorkers in goroutine 1
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/mgc.go:1234 +0x28

goroutine 24 gp=0x1400008cfc0 m=nil [GC worker (idle)]:
runtime.gopark(0x3ebb3d18f2d2?, 0x1?, 0xa4?, 0x2a?, 0x0?)
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/proc.go:402 +0xc8 fp=0x14000061730 sp=0x14000061710 pc=0x10007dbf8
runtime.gcBgMarkWorker()
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/mgc.go:1310 +0xd8 fp=0x140000617d0 sp=0x14000061730 pc=0x1000601a8
runtime.goexit({})
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/asm_arm64.s:1222 +0x4 fp=0x140000617d0 sp=0x140000617d0 pc=0x1000add34
created by runtime.gcBgMarkStartWorkers in goroutine 1
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/mgc.go:1234 +0x28

goroutine 7 gp=0x140000036c0 m=nil [GC worker (idle)]:
runtime.gopark(0x3ebb3d198d48?, 0x3?, 0x2a?, 0xec?, 0x0?)
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/proc.go:402 +0xc8 fp=0x14000065730 sp=0x14000065710 pc=0x10007dbf8
runtime.gcBgMarkWorker()
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/mgc.go:1310 +0xd8 fp=0x140000657d0 sp=0x14000065730 pc=0x1000601a8
runtime.goexit({})
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/asm_arm64.s:1222 +0x4 fp=0x140000657d0 sp=0x140000657d0 pc=0x1000add34
created by runtime.gcBgMarkStartWorkers in goroutine 1
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/mgc.go:1234 +0x28

goroutine 25 gp=0x1400008d180 m=nil [GC worker (idle)]:
runtime.gopark(0x3ebb3d18f6ba?, 0x1?, 0x72?, 0x6a?, 0x0?)
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/proc.go:402 +0xc8 fp=0x14000061f30 sp=0x14000061f10 pc=0x10007dbf8
runtime.gcBgMarkWorker()
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/mgc.go:1310 +0xd8 fp=0x14000061fd0 sp=0x14000061f30 pc=0x1000601a8
runtime.goexit({})
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/asm_arm64.s:1222 +0x4 fp=0x14000061fd0 sp=0x14000061fd0 pc=0x1000add34
created by runtime.gcBgMarkStartWorkers in goroutine 1
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/mgc.go:1234 +0x28

goroutine 36 gp=0x14000114540 m=nil [GC worker (idle)]:
runtime.gopark(0x3ebb3d18f132?, 0x3?, 0x1c?, 0xa2?, 0x140000b1330?)
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/proc.go:402 +0xc8 fp=0x14000423f30 sp=0x14000423f10 pc=0x10007dbf8
runtime.gcBgMarkWorker()
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/mgc.go:1310 +0xd8 fp=0x14000423fd0 sp=0x14000423f30 pc=0x1000601a8
runtime.goexit({})
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/asm_arm64.s:1222 +0x4 fp=0x14000423fd0 sp=0x14000423fd0 pc=0x1000add34
created by runtime.gcBgMarkStartWorkers in goroutine 1
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/mgc.go:1234 +0x28

goroutine 8 gp=0x14000003880 m=nil [GC worker (idle)]:
runtime.gopark(0x3ebb3d18f70e?, 0x140001160e0?, 0x1a?, 0xa?, 0x0?)
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/proc.go:402 +0xc8 fp=0x14000065f30 sp=0x14000065f10 pc=0x10007dbf8
runtime.gcBgMarkWorker()
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/mgc.go:1310 +0xd8 fp=0x14000065fd0 sp=0x14000065f30 pc=0x1000601a8
runtime.goexit({})
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/asm_arm64.s:1222 +0x4 fp=0x14000065fd0 sp=0x14000065fd0 pc=0x1000add34
created by runtime.gcBgMarkStartWorkers in goroutine 1
        /opt/homebrew/Cellar/go/1.22.2/libexec/src/runtime/mgc.go:1234 +0x28
exit status 2
core/types/block.go:37: running "go": exit status 1
ferranbt commented 5 months ago

Can you share the sszgen script? I managed to run the generator with the testcases for this example here.

gsora commented 1 month ago

Hi, this issue is very much still present nowadays.

Minimum reproducer:

package main

type Int = uint256.Int

type Bug struct {
        Field *Int
}

go.mod:

module sszgen-bug

go 1.22.3

require github.com/holiman/uint256 v1.3.1

Run: sszgen -path .

ferranbt commented 1 month ago

Hi! Thank you for the example. I will take a look.