Hacker News new | ask | show | jobs
by amelius 1 day ago
That's what every "copying GC" does.

https://www.cs.cornell.edu/courses/cs312/2003fa/lectures/sec...

1 comments

Of course, but Go's GC doesn't compact or relocate the objects still in use in the middle of a page (which means that page can't be released to the OS) until you manually copy those surviving objects out, freeing up the page they left behind.