From: Phillip Susi <psusi@ubuntu.com>
To: Dave Hansen <dave@linux.vnet.ibm.com>
Cc: linux-mm@kvack.org
Subject: Re: [PATCH 1/2] mm: fadvise: fix POSIX_FADV_DONTNEED
Date: Sat, 23 Feb 2013 22:37:48 -0500 [thread overview]
Message-ID: <51298B0C.2020400@ubuntu.com> (raw)
In-Reply-To: <5129710F.6060804@linux.vnet.ibm.com>
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
On 02/23/2013 08:46 PM, Dave Hansen wrote:
> Folks actually use this in practice to flush the page cache out:
>
> http://git.sr71.net/?p=eyefi-config.git;a=blob;f=eyefi-linux.c;h=b77a891995109f6caa288925a13985cc495d7b2d;hb=HEAD#l62
>
> I have really good reasons for really wanting to be _rid_ of the
> page cache no matter how much memory pressure there is.
>
> I've seen people at IBM using this to ensure that they stay out of
> memory reclaim completely. I don't completely agree with the
> approach, but this would completely ruin their performance since
> the VM-initiated writeout is so relatively slow for them.
>
> I think this patch is a really bad idea. If you want the behavior
> you're proposing, I'd suggest using another flag.
This is the correct behavior prescribed by posix. If you have been
using it for that purpose in the past, then you were using the wrong
syscall. If you want to begin writeout now, then you should be using
sync_file_range(). As it was, it only initiated writeout if the
backing device was not already congested, which is going to no longer
be the case rather soon if you ( or other tasks ) are writing
significant amounts of data.
If you really want to stay out of memory reclaim entirely, then you
should be using O_DIRECT.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.12 (GNU/Linux)
Comment: Using GnuPG with undefined - http://www.enigmail.net/
iQEcBAEBAgAGBQJRKYsKAAoJEJrBOlT6nu75nLAH/AyZetl9eFqSsXEXoSVsmimW
ih9Nwlhqy1g4zSuThHWIS41t2XQ6vrwh7NDkGdFSwJ0GWVoWIFu5E31LofbCQEYk
ApsTrUflUk/Cn/82oCCBzxv9G4RrmG+ywcz9SCG62uOHs3+e2525+aPzt0mPMsBR
672J5wPXV59NmEp2jNl2VFObnBQBWKxQR9xFfZ/jzvtjW+KtVvg+G4eG+3gFGfqi
gExlAnh6V05AS9ut7GUNDhWkJky/2qQl7sE53NbYC738f6I70vF38IMF68Taojcw
kWWW3gc8tZvhlYVnZqWqbK9Yz7+fBxca73ELtCI5i89gcV6VBekdFTqjq4HnWyg=
=7et5
-----END PGP SIGNATURE-----
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
next prev parent reply other threads:[~2013-02-24 3:37 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-02-22 19:57 POSIX_FADV_DONTNEED implemented wrong Phillip Susi
2013-02-22 20:29 ` Johannes Weiner
2013-02-22 21:52 ` Phillip Susi
2013-02-23 22:57 ` [PATCH 0/2] FADV_DONTNEED and FADV_NOREUSE Phillip Susi
2013-02-23 22:58 ` [PATCH 1/2] mm: fadvise: fix POSIX_FADV_DONTNEED Phillip Susi
2013-02-24 1:46 ` Dave Hansen
2013-02-24 3:37 ` Phillip Susi [this message]
2013-02-24 18:24 ` Dave Hansen
2013-02-24 20:40 ` Phillip Susi
2013-02-24 21:25 ` Dave Hansen
2013-02-24 22:38 ` Phillip Susi
2013-02-25 17:50 ` Dave Hansen
2013-02-24 3:58 ` Zheng Liu
2013-02-24 4:04 ` Phillip Susi
2013-02-26 4:21 ` Minchan Kim
2013-02-26 14:06 ` Andrea Righi
2013-02-26 15:39 ` Phillip Susi
2013-02-23 22:58 ` [PATCH 2/2] mm: fadvise: implement POSIX_FADV_NOREUSE Phillip Susi
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=51298B0C.2020400@ubuntu.com \
--to=psusi@ubuntu.com \
--cc=dave@linux.vnet.ibm.com \
--cc=linux-mm@kvack.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox