From 47a71d1ec9b650d864aa36c4642e5ffc500c3d78 Mon Sep 17 00:00:00 2001 From: Michael Pratt Date: Wed, 11 Oct 2023 12:02:28 -0400 Subject: [PATCH] runtime: remove stale non-atomic access comment CL 397014 converted this into an atomic access. Change-Id: Ib97716cd19ecd7d6bf8601baf0391755a5baf378 Reviewed-on: https://go-review.googlesource.com/c/go/+/534159 Auto-Submit: Michael Pratt Reviewed-by: Michael Knyszek LUCI-TryBot-Result: Go LUCI --- src/runtime/mgc.go | 4 ---- 1 file changed, 4 deletions(-) diff --git a/src/runtime/mgc.go b/src/runtime/mgc.go index 0c84047358..da8e578eb6 100644 --- a/src/runtime/mgc.go +++ b/src/runtime/mgc.go @@ -575,10 +575,6 @@ func (t gcTrigger) test() bool { } switch t.kind { case gcTriggerHeap: - // Non-atomic access to gcController.heapLive for performance. If - // we are going to trigger on this, this thread just - // atomically wrote gcController.heapLive anyway and we'll see our - // own write. trigger, _ := gcController.trigger() return gcController.heapLive.Load() >= trigger case gcTriggerTime: -- 2.50.0