Re: [PATCH v10 1/7] mm: support madvise(MADV_FREE)

From
Zhang Yanfei <hidden>
Date
2014-07-08 03:54:57
Also in
linux-mm, lkml
Reply to
Minchan Kim, 2014-07-07
Hi Minchan,

On 07/07/2014 08:53 AM, Minchan Kim wrote:
Linux doesn't have an ability to free pages lazy while other OS
already have been supported that named by madvise(MADV_FREE).

The gain is clear that kernel can discard freed pages rather than
swapping out or OOM if memory pressure happens.

Without memory pressure, freed pages would be reused by userspace
without another additional overhead(ex, page fault + allocation
+ zeroing).

How to work is following as.

When madvise syscall is called, VM clears dirty bit of ptes of
the range. 
This should be updated because the implementation has been changed.
It also remove the page from the swapcache if it is.

Thank you for your effort!

-- 
Thanks.
Zhang Yanfei
Thread (21 messages) 21 messages, 6 authors, last reply 2014-07-08
Keyboard shortcuts
hback out one level
jnext message in thread / next series-diff position
kprevious message in thread / previous series-diff position
ldrill in
Escclose help / fold thread tree
?toggle this help