On 06/29/2011 09:52 AM, Christoph Hellwig wrote:
On Wed, Jun 29, 2011 at 09:20:03AM -0500, Anthony Liguori wrote:
Sorry, I meant having a new cache option (maybe diskcache). Semantics
would be:
diskcache=on,wce=on 0
diskcache=on,wce=off O_SYNC
diskcache=off,wce=on O_DIRECT
diskcache=off,wce=off O_DIRECT | O_SYNC
ignore_flush could be another option too.
Please make it two options instead of a two-dimensional one.
Yeah, that was just for the table. diskcache/hostcache belongs in
-drive, wce belongs in -device.
E.g. e hostcache=[on,off] option for the drive command line,
where fake is the equivalent of the current code together with
I think developers usually want diskcache=on but I also agree that usually
in production, you want diskcache=off.
Why would you want to not use O_DIRECT as a developer?
Relaunching the same guest:
cache=writethrough:
real 0m9.500s
user 0m4.720s
sys 0m3.780s
cache=none:
real 0m15.263s
user 0m4.870s
sys 0m6.390s
If you're doing kernel development where you're frequently launching the
same guest with a different kernel, it using the page cache makes a big
difference in guest boot time.
Regards,
Anthony Liguori