From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([208.118.235.92]:42703) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UJ7xm-0000RB-SU for qemu-devel@nongnu.org; Fri, 22 Mar 2013 15:49:23 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UJ7xl-0003Ym-0Q for qemu-devel@nongnu.org; Fri, 22 Mar 2013 15:49:18 -0400 Received: from mx1.redhat.com ([209.132.183.28]:12025) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UJ7xk-0003Yc-H5 for qemu-devel@nongnu.org; Fri, 22 Mar 2013 15:49:16 -0400 Message-ID: <514CB5B3.5070803@redhat.com> Date: Fri, 22 Mar 2013 13:49:07 -0600 From: Eric Blake MIME-Version: 1.0 References: <1363956370-23681-1-git-send-email-pl@kamp.de> <1363956370-23681-6-git-send-email-pl@kamp.de> In-Reply-To: <1363956370-23681-6-git-send-email-pl@kamp.de> Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="----enig2OXBWUJNMOOPEMQJLOQAA" Subject: Re: [Qemu-devel] [PATCHv4 5/9] migration: search for zero instead of dup pages List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Peter Lieven Cc: Paolo Bonzini , quintela@redhat.com, Orit Wasserman , qemu-devel@nongnu.org, Stefan Hajnoczi This is an OpenPGP/MIME signed message (RFC 4880 and 3156) ------enig2OXBWUJNMOOPEMQJLOQAA Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable On 03/22/2013 06:46 AM, Peter Lieven wrote: > virtually all dup pages are zero pages. remove > the special is_dup_page() function and use the > optimized buffer_find_nonzero_offset() function > instead. >=20 > here buffer_find_nonzero_offset() is used directly > to avoid the unnecssary additional checks in > buffer_is_zero(). >=20 > raw performace gain checking zeroed memory > over is_dup_page() is approx. 15-20% with SSE2. >=20 > Signed-off-by: Peter Lieven > --- > arch_init.c | 21 ++++++--------------- > 1 file changed, 6 insertions(+), 15 deletions(-) Reviewed-by: Eric Blake The code is sound, but I agree with Paolo's assessment that seeing a bit more benchmarking, such as on non-SSE2 seupts, wouldn't hurt. --=20 Eric Blake eblake redhat com +1-919-301-3266 Libvirt virtualization library http://libvirt.org ------enig2OXBWUJNMOOPEMQJLOQAA Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.13 (GNU/Linux) Comment: Public key at http://people.redhat.com/eblake/eblake.gpg Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/ iQEcBAEBCAAGBQJRTLWzAAoJEKeha0olJ0NqNbMIAI2gpdPQQJ6xlyHyoFMrYgLN I1uzRAeL6wtyQcqDm9165uzq+9V+2UrVZ+2tPHQPtRoYbf770djGrE+8UqNUjgIU vKkA8sJDcD+0TzxMndDyLRzNRcXTX1XvmyN/wP+/cvHIrkb0P0HTBoPDCw3cdEwx oviyAbLJIH312M3BsA4kx2BXpIJk41cRTTa+1kB0/7hJJZ3sQq+qeKs/FimuI0hn PCUuKkvP/CuKo+Vo4GV8PeZWn/7DBPTuDOAdXKV4WJjKbff7L02vctnnYaRisJKC Cg7UPpdA8yAZ0/qCdSJQ4Ck0qXNqa4r94nt0YrFXbAVt/6mRvqySeiL99ckE2HE= =HOGT -----END PGP SIGNATURE----- ------enig2OXBWUJNMOOPEMQJLOQAA--