From mboxrd@z Thu Jan 1 00:00:00 1970 From: Avi Kivity Subject: Re: [PATCH v2 6/8] KVM: x86 emulator: simplify instruction decode flags for opcodes C0-DF Date: Thu, 26 Aug 2010 11:50:59 +0300 Message-ID: <4C762AF3.7050705@redhat.com> References: <1282811774-16534-1-git-send-email-avi@redhat.com> <1282811774-16534-7-git-send-email-avi@redhat.com> <4C762A04.6020304@cn.fujitsu.com> Mime-Version: 1.0 Content-Type: text/plain; charset=GB2312 Content-Transfer-Encoding: 7bit Cc: Marcelo Tosatti , kvm@vger.kernel.org To: Wei Yongjun Return-path: Received: from mx1.redhat.com ([209.132.183.28]:55851 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753246Ab0HZIvE (ORCPT ); Thu, 26 Aug 2010 04:51:04 -0400 In-Reply-To: <4C762A04.6020304@cn.fujitsu.com> Sender: kvm-owner@vger.kernel.org List-ID: On 08/26/2010 11:47 AM, Wei Yongjun wrote: >> Use the new byte/word dual opcode decode. >> >> Signed-off-by: Avi Kivity >> --- >> arch/x86/kvm/emulate.c | 7 +++---- >> 1 files changed, 3 insertions(+), 4 deletions(-) >> >> diff --git a/arch/x86/kvm/emulate.c b/arch/x86/kvm/emulate.c >> index 935f98e..2610fc5 100644 >> --- a/arch/x86/kvm/emulate.c >> +++ b/arch/x86/kvm/emulate.c >> @@ -2466,17 +2466,16 @@ static struct opcode opcode_table[256] = { >> /* 0xB8 - 0xBF */ >> X8(D(DstReg | SrcImm | Mov)), >> /* 0xC0 - 0xC7 */ >> - D(ByteOp | DstMem | SrcImm | ModRM), D(DstMem | SrcImmByte | ModRM), >> + D2bv(DstMem | SrcImm | ModRM), >> > 0xC1 takes imm8 as the source operand. Good catch. > So D2bv can not be used here. It can, just needs to be D2bv(DstMem | SrcImmByte | ModRM). -- error compiling committee.c: too many arguments to function