cmd/keeper: disable GC for zkvm execution

ZKVMs are constrained environments that liberally allocate memory and
never release it. In this context, using the GC is only going to cause
issues down the road, and slow things down in any case.
This commit is contained in:
Guillaume Ballet 2025-09-17 11:27:50 +02:00
parent a4c9b34730
commit 3a5399d8e6
No known key found for this signature in database

View file

@ -19,6 +19,7 @@ package main
import (
"fmt"
"os"
"runtime/debug"
"github.com/ethereum/go-ethereum/core"
"github.com/ethereum/go-ethereum/core/stateless"
@ -35,6 +36,10 @@ type Payload struct {
Witness *stateless.Witness
}
func init() {
debug.SetGCPercent(-1) // Disable garbage collection
}
func main() {
input := getInput()
var payload Payload