Skip to content

Commit 862a8b5

Browse files
pdrobnjakclaude
andcommitted
perf: set GOGC=200 to reduce GC frequency
Reduces GC CPU overhead (~17% of total) by allowing the heap to grow larger before triggering collection. Benchmarked at +3.2% avg TPS. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
1 parent 21e991f commit 862a8b5

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

app/app.go

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -440,6 +440,8 @@ func New(
440440
appOptions []AppOption,
441441
baseAppOptions ...func(*baseapp.BaseApp),
442442
) *App {
443+
debug.SetGCPercent(200)
444+
443445
appCodec := encodingConfig.Marshaler
444446
cdc := encodingConfig.Amino
445447
interfaceRegistry := encodingConfig.InterfaceRegistry

0 commit comments

Comments
 (0)