From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:33093) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Xmhhd-00078R-LK for qemu-devel@nongnu.org; Fri, 07 Nov 2014 06:27:47 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1XmhhX-0003OY-FL for qemu-devel@nongnu.org; Fri, 07 Nov 2014 06:27:41 -0500 Received: from cantor2.suse.de ([195.135.220.15]:41753 helo=mx2.suse.de) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XmhhX-0003OL-9Y for qemu-devel@nongnu.org; Fri, 07 Nov 2014 06:27:35 -0500 Message-ID: <545CACA3.8040003@suse.de> Date: Fri, 07 Nov 2014 12:27:31 +0100 From: =?UTF-8?B?QW5kcmVhcyBGw6RyYmVy?= MIME-Version: 1.0 References: <20141107103123.6136.18545.stgit@PASHA-ISP> <20141107103223.6136.57870.stgit@PASHA-ISP> In-Reply-To: <20141107103223.6136.57870.stgit@PASHA-ISP> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Subject: Re: [Qemu-devel] [RFC PATCH v4 10/25] i386: do not cross the pages boundaries in replay mode List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Pavel Dovgalyuk , qemu-devel@nongnu.org Cc: peter.maydell@linaro.org, peter.crosthwaite@xilinx.com, alex.bennee@linaro.org, mark.burton@greensocs.com, real@ispras.ru, batuzovk@ispras.ru, maria.klimushenkova@ispras.ru, pbonzini@redhat.com, fred.konrad@greensocs.com Am 07.11.2014 um 11:32 schrieb Pavel Dovgalyuk: > This patch denies crossing the boundary of the pages in the replay mode= , > because it can cause an exception. Do it only when boundary is > crossed by the first instruction in the block. > If current instruction already crossed the bound - it's ok, > because an exception hasn't stopped this code. >=20 > Signed-off-by: Pavel Dovgalyuk > --- > target-i386/cpu.h | 7 +++++++ > target-i386/translate.c | 14 ++++++++++++++ > 2 files changed, 21 insertions(+), 0 deletions(-) >=20 > diff --git a/target-i386/cpu.h b/target-i386/cpu.h > index 2968749..bc3f9f5 100644 > --- a/target-i386/cpu.h > +++ b/target-i386/cpu.h > @@ -28,6 +28,13 @@ > #define TARGET_LONG_BITS 32 > #endif > =20 > +/* Maximum instruction code size */ > +#ifdef TARGET_X86_64 > +#define TARGET_MAX_INSN_SIZE 16 > +#else > +#define TARGET_MAX_INSN_SIZE 16 > +#endif Is this a spot-the-difference game? ;) Seriously, if they're the same values, just drop the #ifdef. > + > /* target supports implicit self modifying code */ > #define TARGET_HAS_SMC > /* support for self modifying code even if the modified instruction is [snip] Regards, Andreas --=20 SUSE LINUX GmbH, Maxfeldstr. 5, 90409 N=C3=BCrnberg, Germany GF: Jeff Hawn, Jennifer Guild, Felix Imend=C3=B6rffer; HRB 21284 AG N=C3=BC= rnberg