From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1JmaMq-00022L-Ry for qemu-devel@nongnu.org; Thu, 17 Apr 2008 16:06:00 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1JmaMp-00021q-82 for qemu-devel@nongnu.org; Thu, 17 Apr 2008 16:06:00 -0400 Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1JmaMp-00021n-4z for qemu-devel@nongnu.org; Thu, 17 Apr 2008 16:05:59 -0400 Received: from e2.ny.us.ibm.com ([32.97.182.142]) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1JmaMo-0002EA-RW for qemu-devel@nongnu.org; Thu, 17 Apr 2008 16:05:58 -0400 Received: from d01relay04.pok.ibm.com (d01relay04.pok.ibm.com [9.56.227.236]) by e2.ny.us.ibm.com (8.13.8/8.13.8) with ESMTP id m3HK5rkA018828 for ; Thu, 17 Apr 2008 16:05:53 -0400 Received: from d01av04.pok.ibm.com (d01av04.pok.ibm.com [9.56.224.64]) by d01relay04.pok.ibm.com (8.13.8/8.13.8/NCO v8.7) with ESMTP id m3HK5roe255232 for ; Thu, 17 Apr 2008 16:05:53 -0400 Received: from d01av04.pok.ibm.com (loopback [127.0.0.1]) by d01av04.pok.ibm.com (8.12.11.20060308/8.13.3) with ESMTP id m3HK5qo9029446 for ; Thu, 17 Apr 2008 16:05:53 -0400 Message-ID: <4807ADA0.2090005@us.ibm.com> Date: Thu, 17 Apr 2008 15:05:52 -0500 From: Anthony Liguori MIME-Version: 1.0 References: <1208460412-27567-1-git-send-email-aliguori@us.ibm.com> <20080417193807.GB11916@redhat.com> <4807A7EC.6040408@us.ibm.com> <20080417200024.GC11916@redhat.com> In-Reply-To: <20080417200024.GC11916@redhat.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Subject: [Qemu-devel] Re: [kvm-devel] [PATCH 1/3] Refactor AIO interface to allow other AIO implementations Reply-To: qemu-devel@nongnu.org List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: "Daniel P. Berrange" Cc: kvm-devel@lists.sourceforge.net, Marcelo Tosatti , qemu-devel@nongnu.org Daniel P. Berrange wrote: > If QEMU can't discover cases where it won't work, what criteria should > the end user use to decide between the impls, or for that matter, what > criteria should a management api/app like libvirt use ? If the only decision > logic is 'try it & benchmark your VM' then its not a particularly useful > option. > > I've basically got a choice of making libvirt always ad '-aio linux' > or never add it at all. My inclination is to the latter since it is > compatible with existing QEMU which has no -aio option. Presumably > '-aio linux' is intended to provide some performance benefit so it'd > be nice to use it. If we can't express some criteria under which it > should be turned on, I can't enable it; where as if you can express > some criteria, then QEMU should apply them automatically. > > Pushing this choice of AIO impls to the app or user invoking QEMU just > does not seem like a win here. > The one thing we could possibly do is detect the cache where we see a block device and then automagically enable cache=off and -aio linux. Without cache=off, -aio linux is not so useful ATM. At the same time though, not all users are going to want to disable the use of the host page cache. It's not necessary an easy decision either way. For libvirt, I'd recommend just never using -aio linux. We'll have a better AIO option in the near future (based on Rusty's vringfd work) and I'd like to detect and enable that by default. Regards, Anthony Liguori > Dan. >