Re:Go memory ballast: How I learnt to stop worrying and love...
by sharpneli on Monday December 02, 2019 @04:32AM
(#21681040)
"Only if we attempt to read or write to the slice, will the page fault occur that causes the physical RAM backing the virtual addresses to be allocated."
Tiny nitpick. On Linux at least you can read from the slice. New memory allocations are given a copy on write zero page (full of zeroes). So you can easily read that 10GB worth of zeroes out and still memory consumption wouldn't increase.
Only when you write a pagefault is issued and you'll get real backing for it.
Tiny nitpick. On Linux at least you can read from the slice. New memory allocations are given a copy on write zero page (full of zeroes). So you can easily read that 10GB worth of zeroes out and still memory consumption wouldn't increase.
Only when you write a pagefault is issued and you'll get real backing for it.