From 8fd784fb38225e6ff371bb5b0a122dbbd5f3c3cd Mon Sep 17 00:00:00 2001 From: Heschi Kreinick Date: Tue, 18 Feb 2020 15:17:40 -0500 Subject: [PATCH] internal/lsp/debug: drop memory debug threshold to 1GiB Most people do not have giant 64-GiB workstations, so 10GiB of RAM (5 active heap, 5 inactive for GOGC=100) is a really high threshold. Drop to 1GiB active to drop profiles. Change-Id: If0ae418828377a648a93322e269f4610fd64ebb3 Reviewed-on: https://go-review.googlesource.com/c/tools/+/219937 Run-TryBot: Heschi Kreinick TryBot-Result: Gobot Gobot Reviewed-by: Rebecca Stambler --- internal/lsp/debug/serve.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/internal/lsp/debug/serve.go b/internal/lsp/debug/serve.go index 3b10a37bfd..c65c8f33cb 100644 --- a/internal/lsp/debug/serve.go +++ b/internal/lsp/debug/serve.go @@ -335,7 +335,7 @@ func (i *Instance) Serve(ctx context.Context) error { func (i *Instance) MonitorMemory(ctx context.Context) { tick := time.NewTicker(time.Second) - nextThresholdGiB := uint64(5) + nextThresholdGiB := uint64(1) go func() { for { <-tick.C