On Tuesday, 13 July 2021 at 03:52:24 UTC+1 bai...@gmail.com wrote:

> Hi, I wrote a test program, which tests when GC starts to return heap 
> space to OS.
> Here's the code: https://paste.ubuntu.com/p/jxHqDnsM2T/
>
> But I've waited for a long time and haven't seen the RSS memory reduced. I 
> can't figured out why, Any help ? (go version 1.14.3)
>

There was a change in go 1.16 <https://golang.org/doc/go1.16#runtime> which 
could affect this, so I suggest you try the latest go.

Previously, go just marked the pages as "can be freed when required" - but 
the OS would not actually free them until under memory pressure. Now it 
tells the OS to free them immediately.

-- 
You received this message because you are subscribed to the Google Groups 
"golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to golang-nuts+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/golang-nuts/7c99fe43-376d-4f94-9070-17dafbe6baffn%40googlegroups.com.

Reply via email to