KS2007: Memory management
Posted Sep 24, 2007 14:38 UTC (Mon) by stereodee
In reply to: KS2007: Memory management
Parent article: KS2007: Memory management
> Does any system currently offer a weak_free call?
How about madvise(2)?
"MADV_FREE - Gives the VM system the freedom to free pages, and tells the system that information in the specified page range is no longer important. This is an efficient way of allowing malloc(3) to free pages anywhere in the address space, while keeping the address space valid. The next time that the page is referenced, the page might be demand zeroed, or might contain the data that was there before the MADV_FREE call. References made to that address space range will not make the VM system page the information back in from backing store until the page is modified again."
to post comments)