From c99ace4213c83082abe5c6bb0d93782adf099ee2 Mon Sep 17 00:00:00 2001 From: Filip Vranesevic Date: Sat, 9 Sep 2023 22:48:46 +0200 Subject: [PATCH] restoring original comment --- src/runtime/gc_blocks.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/runtime/gc_blocks.go b/src/runtime/gc_blocks.go index e5bc23e8..40a7764b 100644 --- a/src/runtime/gc_blocks.go +++ b/src/runtime/gc_blocks.go @@ -125,6 +125,9 @@ func (b gcBlock) address() uintptr { return addr } +// findHead returns the head (first block) of an object, assuming the block +// points to an allocated object. It returns the same block if this block +// already points to the head. func (b gcBlock) findHead() gcBlock { stateBytePtr := (*uint8)(unsafe.Add(metadataStart, b/blocksPerStateByte))