I didn't look at the source for your program because you don't seem to understand what "resident set size" means in this context. The RSS of a process is unrelated to its virtual size. You appear to be equating RSS and virtual size. This might be an example of the XY Problem <https://xyproblem.info/>.. What Prompted you to open this discussion thread?
On Mon, Jul 12, 2021 at 7:52 PM Chan Lewis <baiw...@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) > > -- > 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/a511d995-7f1d-431d-9065-6b6d287a19dan%40googlegroups.com > <https://groups.google.com/d/msgid/golang-nuts/a511d995-7f1d-431d-9065-6b6d287a19dan%40googlegroups.com?utm_medium=email&utm_source=footer> > . > -- Kurtis Rader Caretaker of the exceptional canines Junior and Hank -- 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/CABx2%3DD_BMdKn_du_REFU0NEyQaBSM979%2BHTGFf3JWmvvohNqJw%40mail.gmail.com.