From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:45383) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1b0p24-0002oh-6k for qemu-devel@nongnu.org; Thu, 12 May 2016 07:43:57 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1b0p22-00052z-2P for qemu-devel@nongnu.org; Thu, 12 May 2016 07:43:55 -0400 References: <146299653361.5203.4475655460859700214.stgit@localhost> <146299653947.5203.13161479377215549869.stgit@localhost> From: Paolo Bonzini Message-ID: <57346C4D.20006@redhat.com> Date: Thu, 12 May 2016 13:43:09 +0200 MIME-Version: 1.0 In-Reply-To: <146299653947.5203.13161479377215549869.stgit@localhost> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Subject: Re: [Qemu-devel] [PATCH v2 1/2] exec: [tcg] Track which vCPU is performing translation and execution List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: =?UTF-8?Q?Llu=c3=ads_Vilanova?= , qemu-devel@nongnu.org Cc: Peter Maydell , Stefan Hajnoczi , Richard Henderson , "Edgar E. Iglesias" , Eduardo Habkost , Michael Walle , Aurelien Jarno , Leon Alrae , Anthony Green , Jia Liu , Alexander Graf , Blue Swirl , Mark Cave-Ayland , Bastian Koppelmann , Guan Xuetao , Max Filippov , Peter Crosthwaite , "open list:ARM" , "open list:PowerPC" On 11/05/2016 21:55, Llu=C3=ADs Vilanova wrote: > =20 > diff --git a/translate-all.c b/translate-all.c > index 8329ea6..1c16b14 100644 > --- a/translate-all.c > +++ b/translate-all.c > @@ -1092,6 +1092,8 @@ TranslationBlock *tb_gen_code(CPUState *cpu, > ti =3D profile_getclock(); > #endif > =20 > + tcg_ctx.cpu =3D ENV_GET_CPU(env); > + > tcg_func_start(&tcg_ctx); > =20 > gen_intermediate_code(env, tb); >=20 I prefer to also set this to NULL outside translation. Paolo