From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:42006) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bDqwp-0002JU-4X for qemu-devel@nongnu.org; Fri, 17 Jun 2016 06:24:24 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bDqwn-0001P7-5L for qemu-devel@nongnu.org; Fri, 17 Jun 2016 06:24:22 -0400 Date: Fri, 17 Jun 2016 12:24:11 +0200 From: Kevin Wolf Message-ID: <20160617102411.GD5431@noname.redhat.com> References: <1465989402-18890-1-git-send-email-kwolf@redhat.com> <20160617101330.GE6994@stefanha-x1.localdomain> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="opJtzjQTFsWo+cga" Content-Disposition: inline In-Reply-To: <20160617101330.GE6994@stefanha-x1.localdomain> Subject: Re: [Qemu-devel] [Qemu-block] [PATCH] linux-aio: Cancel BH if not needed List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Stefan Hajnoczi Cc: qemu-block@nongnu.org, pbonzini@redhat.com, qemu-devel@nongnu.org, stefanha@redhat.com --opJtzjQTFsWo+cga Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Am 17.06.2016 um 12:13 hat Stefan Hajnoczi geschrieben: > On Wed, Jun 15, 2016 at 01:16:42PM +0200, Kevin Wolf wrote: > > linux-aio uses a BH in order to make sure that the remaining completions > > are processed even in nested event loops of completion callbacks in > > order to avoid deadlocks. > >=20 > > There is no need, however, to have the BH overhead for the first call > > into qemu_laio_completion_bh() or after all pending completions have > > already been processed. Therefore, this patch calls directly into > > qemu_laio_completion_bh() in qemu_laio_completion_cb() and cancels > > the BH after qemu_laio_completion_bh() has processed all pending > > completions. > >=20 > > Signed-off-by: Kevin Wolf > > --- > > block/linux-aio.c | 4 +++- > > 1 file changed, 3 insertions(+), 1 deletion(-) >=20 > I ran 4 x iodepth=3D16 random 4KB read I/O benchmarks. There might be an > improvement but it's within the error margin. My benchmarking setup can > be noisy... >=20 > Anyway, this patch doesn't hurt performance. Guest and host are RHEL 7.2. Thanks for confirming! > $ ./analyze.py runs/ > Name IOPS Error > linux-aio-bh-optimizations-ccb9dc1 12942616.0 =B1 16.83% > linux-aio-bh-optimizations-ccb9dc1-2 13833110.4 =B1 4.74% > linux-aio-bh-optimizations-off-23b0d9f 13303981.4 =B1 2.21% What are these three commits? Is the first one with your virtio-blk changes and this patch, the second only this patch and the third one the baseline? Kevin --opJtzjQTFsWo+cga Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.22 (GNU/Linux) iQIcBAEBAgAGBQJXY8/LAAoJEH8JsnLIjy/W5GYQAJ/DMNmT7nTVcYLN3xOI110C PryibLDLUylamqdZzV0Wa8WAJWBH7WaAIJcUUG0rR8DzHKUD7LyQiyKg80aFh7QB Lvc5L2pXFlHgEhjuI9yLsKqLJl0mHRNqmK9dgFGBW+iIwnk65E0w2ND1YDBp27Ik tzLDzIFRpVyBeb5ffkLtpBS+wQ2c7KwCM0iRT8RKh835c+zlxmachMEr7XLPN1tu X5qq/Hs2XYl6+80Ci4zyLIyQh/LoSf5I8FjvUwm0MciB7XocdmB5nMIJDjqLFtXW bdXOKSwpW/Y6VdmOKWQaQ3fR+bBw0SgT3hq9iVYzCocnOwSc6CbhDas64bwVYZ8V Mri5WOlZOpR+8niuj3dKID6kGSPRIU35FEwDTdOevwqRPA9apyKl+dzXNB5jWMdG N7PHr+0IIUl1CbtD7wyMynIKFbVdjaOhiaLFa/YjS8UFwcAHDvyEZ2xc/ztYykp3 IlZGF5WL7vGm+EVf7T9DkCsoQjhzAIJ4cb9whGwKcBph42o9U5Sf2ksfk8Qgl+IF iNd6cQ70K9DkyvQWNgGcR9DG0C+GF+6o55ZejoVfvX7vZ0Fslxwc23r9QAAIIkOs 51xAmdEPO0RunwHnE5WnLqtZC8GkG4dJuUl8k78fy/Mp3Y1cIskUPEqWThIvmFiz S5VV+A8OnXVMwB0vsR7n =1lmo -----END PGP SIGNATURE----- --opJtzjQTFsWo+cga--