From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:51333) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Xwbmy-0005It-2y for qemu-devel@nongnu.org; Thu, 04 Dec 2014 14:10:12 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Xwbmt-0000B9-5Q for qemu-devel@nongnu.org; Thu, 04 Dec 2014 14:10:08 -0500 Received: from mx1.redhat.com ([209.132.183.28]:58433) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Xwbms-00009Y-VC for qemu-devel@nongnu.org; Thu, 04 Dec 2014 14:10:03 -0500 Received: from int-mx09.intmail.prod.int.phx2.redhat.com (int-mx09.intmail.prod.int.phx2.redhat.com [10.5.11.22]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id sB4JA1Nf017581 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=FAIL) for ; Thu, 4 Dec 2014 14:10:01 -0500 Message-ID: <5480B188.9050304@redhat.com> Date: Thu, 04 Dec 2014 12:10:00 -0700 From: Eric Blake MIME-Version: 1.0 References: <1417613866-25890-1-git-send-email-mreitz@redhat.com> <1417613866-25890-27-git-send-email-mreitz@redhat.com> <547FA4E9.40302@redhat.com> <54802E89.8030500@redhat.com> In-Reply-To: <54802E89.8030500@redhat.com> Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="N4AgokAHXS8nSpPOh7VlgsVlJha2DfrGu" Subject: Re: [Qemu-devel] [PATCH v4 26/26] iotests: Add test for different refcount widths List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Max Reitz , qemu-devel@nongnu.org Cc: Kevin Wolf , Stefan Hajnoczi This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --N4AgokAHXS8nSpPOh7VlgsVlJha2DfrGu Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable On 12/04/2014 02:51 AM, Max Reitz wrote: >> Side note: >> >> Now that we can produce MUCH smaller images where the reftable can >> easily require enough contiguous clusters to require the creation of a= t >> least one refblock that cannot be self-referential, it would probably = be >> good to modify an existing test and/or add a new test to prove that we= >> don't trip up when trying to create and read such an image. >=20 > Reading is rarely a problem because we don't even need to read the > refcounts then. However, creation may indeed be (or better: it should > not be), so I will see to add a test later on. Such a test is not necessarily quick. On my machine with a spinning rust disk, qemu-img create -f qcow2 -ocluster_size=3D512 image 256M qemu-io -c 'write -P 0x22 0 256M' image took several minutes (I'm not sure if that is all because of 512-byte operations needing read-modify-write operations on the underlying filesystem, or I ended up with a safer-but-slower cache mode that was flushing a lot more often than necessary). And running 'qemu-img map image' in another terminal during that time to watch progress sometimes dumped core due to assertion failures about unexpected nb_clusters (but that's to be expected - reading an image in one process while another is actively modifying it is prone to cause grief to the reader). But the resulting image was successfully completed, and appears to be valid. Although I didn't find an easy way to determine where the L1 table actually ended up, and whether it really did cause the creation of at least one refblock that was not self-referential. --=20 Eric Blake eblake redhat com +1-919-301-3266 Libvirt virtualization library http://libvirt.org --N4AgokAHXS8nSpPOh7VlgsVlJha2DfrGu 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 Comment: Public key at http://people.redhat.com/eblake/eblake.gpg iQEcBAEBCAAGBQJUgLGIAAoJEKeha0olJ0NqY/sH/RIhmSgwbd+p+qoGhqD0S6yQ IDyc0QdPZx1y0R0E2IaTsRmlLCcmTSWdEyC+PU0B5B5T1owzDzweJhtA8p2oeyaR rr2iymqV2dsV8uBXJglW3VBu6GMXbIALNKslM2SIsu7K9AYnhJ0cntPx5tN6INU+ CQrvvrPg/6v4Ag8neZxnnqvVz5RYlqzv/MAy25s8VwagE+BeOPCcKqUcNtQy108V rBJ5gMkDipzhGWvfyQkGXciyruOdbduTHPDFreFMFLWP+rPt+f+dba2xnQt3MQb1 u3ac6Ud7kuvJdQnx5bQvhuMwnSgR1I/6hnOoCma/NTRn5MlqtYHAIlnBMHZMMC4= =Cc1b -----END PGP SIGNATURE----- --N4AgokAHXS8nSpPOh7VlgsVlJha2DfrGu--