From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:54304) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Yfpgv-0001Mj-Qm for qemu-devel@nongnu.org; Wed, 08 Apr 2015 09:06:54 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Yfpgp-0005pz-BM for qemu-devel@nongnu.org; Wed, 08 Apr 2015 09:06:48 -0400 Received: from cantor2.suse.de ([195.135.220.15]:48900 helo=mx2.suse.de) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Yfpgp-0005pZ-5g for qemu-devel@nongnu.org; Wed, 08 Apr 2015 09:06:43 -0400 Message-ID: <552527E1.3010604@suse.de> Date: Wed, 08 Apr 2015 15:06:41 +0200 From: =?ISO-8859-15?Q?Andreas_F=E4rber?= MIME-Version: 1.0 References: <1427139432-27530-1-git-send-email-ehabkost@redhat.com> In-Reply-To: <1427139432-27530-1-git-send-email-ehabkost@redhat.com> Content-Type: text/plain; charset=iso-8859-15 Content-Transfer-Encoding: quoted-printable Subject: Re: [Qemu-devel] [PATCH for-2.4 v5 0/7] Target-specific unit test support, add unit tests for target-i386/cpu.c code List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Eduardo Habkost , qemu-devel@nongnu.org Cc: Paolo Bonzini , Igor Mammedov Am 23.03.2015 um 20:37 schrieb Eduardo Habkost: > Changes v4 -> v5: > * Rewrite fake kvm_arch_get_supported_cpuid() code > * Add new test to ensure KVM defaults won't override explicit command-= line > options >=20 > Changes v3 -> v4: > * Move target_words_bigendian() prototype back inside tests/x86-stub.c= . >=20 > Changes v2 -> v3: > * Extra KVM "host" CPU model test cases > * Move target_words_bigendian() prototype to exec-all.h >=20 > Changes v1 -> v2: > * Make dependency list of test binary much simpler, now that cpus.o > was removed. I don't recall seeing the previous four versions of this... I think adding unit tests for whole devices is the wrong approach. We had that discussion for tmp105. Instead, using the QTest framework - be it extending my pc-cpu-test or adding a new one - allows to reuse the device infrastructure in-place in the actual executable without the need for stubs and without risking to break the test suite by forgetting to run make check after device changes or forcing work duplication onto othe= rs. Specifically, you added properties to allow inspection of CPUID feature bits that - as I understood - today no one (including libvirt) is using. Regards, Andreas > Eduardo Habkost (7): > tests: Support target-specific unit tests > tests: Make test-x86-cpuid target-specific > tests: Add unit test for X86CPU code > target-i386: Isolate enabled-by-default features to a separate array > tests: test-x86-cpu: Add TCG feature bit initialization test > tests: test-x86-cpu: Add KVM feature bit initialization test > tests: test-x86-cpu: Ensure that -cpu override KVM-specific defaults >=20 > target-i386/cpu.c | 12 ++- > tests/.gitignore | 1 + > tests/Makefile | 49 +++++++++--- > tests/test-x86-cpu.c | 208 +++++++++++++++++++++++++++++++++++++++++++= ++++++++ > tests/vl-stub.c | 15 ++++ > tests/x86-stub.c | 165 ++++++++++++++++++++++++++++++++++++++++ > 6 files changed, 437 insertions(+), 13 deletions(-) > create mode 100644 tests/test-x86-cpu.c > create mode 100644 tests/vl-stub.c > create mode 100644 tests/x86-stub.c --=20 SUSE Linux GmbH, Maxfeldstr. 5, 90409 N=FCrnberg, Germany GF: Felix Imend=F6rffer, Jane Smithard, Jennifer Guild, Dilip Upmanyu, Graham Norton; HRB 21284 (AG N=FCrnberg)