Re: [PATCH 4/4] MADV_VOLATILE: Add page purging logic & SIGBUS trap

2014-05-08 Thread John Stultz
On 05/07/2014 10:16 PM, Minchan Kim wrote: > On Tue, Apr 29, 2014 at 02:21:23PM -0700, John Stultz wrote: >> +update_hiwater_rss(mm); >> +if (PageAnon(page)) >> +dec_mm_counter(mm, MM_ANONPAGES); >> +else >> +dec_mm_counter(mm, MM_FILEPAGES); > We can add file-ba

Re: [PATCH 4/4] MADV_VOLATILE: Add page purging logic & SIGBUS trap

2014-05-07 Thread Minchan Kim
On Tue, Apr 29, 2014 at 02:21:23PM -0700, John Stultz wrote: > This patch adds the hooks in the vmscan logic to purge volatile pages > and mark their pte as purged. With this, volatile pages will be purged > under pressure, and their ptes swap entry's marked. If the purged pages > are accessed befo

[PATCH 4/4] MADV_VOLATILE: Add page purging logic & SIGBUS trap

2014-04-29 Thread John Stultz
This patch adds the hooks in the vmscan logic to purge volatile pages and mark their pte as purged. With this, volatile pages will be purged under pressure, and their ptes swap entry's marked. If the purged pages are accessed before being marked non-volatile, we catch this and send a SIGBUS. This