From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:58347) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bnWmY-0006eR-Bp for qemu-devel@nongnu.org; Fri, 23 Sep 2016 16:09:15 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bnWmW-0002oQ-81 for qemu-devel@nongnu.org; Fri, 23 Sep 2016 16:09:13 -0400 Received: from mail-io0-x244.google.com ([2607:f8b0:4001:c06::244]:35031) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bnWmW-0002oC-2v for qemu-devel@nongnu.org; Fri, 23 Sep 2016 16:09:12 -0400 Received: by mail-io0-x244.google.com with SMTP id 92so2377703iom.2 for ; Fri, 23 Sep 2016 13:09:12 -0700 (PDT) Sender: Richard Henderson References: <1474659936-978-1-git-send-email-ehabkost@redhat.com> <1474659936-978-7-git-send-email-ehabkost@redhat.com> From: Richard Henderson Message-ID: Date: Fri, 23 Sep 2016 13:09:09 -0700 MIME-Version: 1.0 In-Reply-To: <1474659936-978-7-git-send-email-ehabkost@redhat.com> Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH 6/7] target-i386: xsave: Calculate set of xsave components on realize List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Eduardo Habkost , qemu-devel@nongnu.org Cc: Paolo Bonzini , Igor Mammedov On 09/23/2016 12:45 PM, Eduardo Habkost wrote: > Instead of doing complex calculations and calling > kvm_arch_get_supported_cpuid() inside cpu_x86_cpuid(), calculate > the set of required XSAVE components earlier, at realize time. > > Signed-off-by: Eduardo Habkost > --- > target-i386/cpu.c | 51 ++++++++++++++++++++++++++++----------------------- > target-i386/cpu.h | 1 + > 2 files changed, 29 insertions(+), 23 deletions(-) Reviewed-by: Richard Henderson > @@ -2504,9 +2504,6 @@ void cpu_x86_cpuid(CPUX86State *env, uint32_t index, uint32_t count, > *ebx &= 0xffff; /* The count doesn't need to be reliable. */ > break; > case 0xD: { > - uint64_t ena_mask; > - int i; > - > /* Processor Extended State */ > *eax = 0; > *ebx = 0; We should be able to drop the braces around this case as well, please. r~