Closed
Description
The hugo
binary gets slower, potentially dramatically so, with GOEXPERIMENT=greenteagc
. The root cause is page mapping churn. The Green Tea code introduced a new implicit nil check on value in a freshly-allocated span to clear some new heap metadata. This nil check would read the fresh memory, causing Linux to back that virtual address space with an RO page. This would then be almost immediately written to, causing Linux to possibly flush the TLB and find memory to replace that RO page (likely deduplicated as just the zero page).
The full investigation is in #73581 and culminates with #73581 (comment).