From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1JysVm-00007Y-Ix for qemu-devel@nongnu.org; Wed, 21 May 2008 13:54:02 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1JysVl-00005L-1d for qemu-devel@nongnu.org; Wed, 21 May 2008 13:54:02 -0400 Received: from [199.232.76.173] (port=59795 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1JysVk-000055-SG for qemu-devel@nongnu.org; Wed, 21 May 2008 13:54:00 -0400 Received: from py-out-1112.google.com ([64.233.166.176]:43208) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1JysVk-0007Re-MS for qemu-devel@nongnu.org; Wed, 21 May 2008 13:54:00 -0400 Received: by py-out-1112.google.com with SMTP id p76so291569pyb.10 for ; Wed, 21 May 2008 10:53:59 -0700 (PDT) Message-ID: <483461B0.20709@codemonkey.ws> Date: Wed, 21 May 2008 12:53:52 -0500 From: Anthony Liguori MIME-Version: 1.0 Subject: Re: [Qemu-devel] Re: [PATCH][v2] Align file accesses with cache=off (O_DIRECT) References: <483429EB.7070705@codemonkey.ws> <48342F05.2090603@qumranet.com> <48343106.4070801@codemonkey.ws> <48343844.1050107@qumranet.com> <20080521153454.GB20527@shareable.org> <48344793.2020902@codemonkey.ws> <20080521162406.GA21501@shareable.org> <48345258.9040004@qumranet.com> <20080521170129.GF22488@duo.random> <48345949.4050903@qumranet.com> <20080521174754.GG22488@duo.random> In-Reply-To: <20080521174754.GG22488@duo.random> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Reply-To: qemu-devel@nongnu.org List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Andrea Arcangeli Cc: Blue Swirl , Laurent Vivier , qemu-devel@nongnu.org, Paul Brook Andrea Arcangeli wrote: > On Wed, May 21, 2008 at 08:18:01PM +0300, Avi Kivity wrote: > >> Yes, that's the reason. Here zerocopy is not the motivation; instead, we >> have host-cached pages that are used directly in the guest. So we get both >> reduced memory footprint, and host caching. O_DIRECT reduces the memory >> footprint but kills host caching. >> > > Sure. So MAP_SHARED+remap_file_pages should work just fine to achieve > zerocopy I/O. > MAP_SHARED cannot be done transparently to the guest, that's the motivating reason behind MAP_PRIVATE. Regards, Anthony Liguori