From mboxrd@z Thu Jan 1 00:00:00 1970 From: Guillaume Thouvenin Subject: Re: [PATCH] x86 emulator: Add Src2 decode set Date: Thu, 9 Oct 2008 11:30:41 +0200 Message-ID: <20081009113041.714b3fbe@frecb000711> References: <20081008145245.78c7084d@frecb000711> <48ECC028.5070807@redhat.com> <20081009095253.66737bf1@frecb000711> <48EDBCCD.4010705@redhat.com> <20081009105744.40478c77@frecb000711> <48EDC9AA.5010407@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Cc: kvm To: Avi Kivity Return-path: Received: from ecfrec.frec.bull.fr ([129.183.4.8]:38564 "EHLO ecfrec.frec.bull.fr" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753157AbYJIJav (ORCPT ); Thu, 9 Oct 2008 05:30:51 -0400 In-Reply-To: <48EDC9AA.5010407@redhat.com> Sender: kvm-owner@vger.kernel.org List-ID: On Thu, 09 Oct 2008 11:06:50 +0200 Avi Kivity wrote: > > The regular shift instructions (shl, rcl, etc) come in three varieties: > shift by 1, shift by imm8, and shift by CL. Right now they use > SrcImmByte and decode the implied '1' and CL by hand. If we change them > to use Src2, they can reuse the Src2CL and Src2One support that you are > adding now. Ok I see but shld, rcld, etc come only in two varieties: immediate and CL. So maybe it could be better to replace SrcImplicit (that is not really useful) by SrcOne? and then we will have ... case SrcOne: c->src.val = 1; break; ... and we can reuse Src2CL as well.