From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:60779) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YGUMv-0000Kt-7l for qemu-devel@nongnu.org; Wed, 28 Jan 2015 10:17:26 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YGUMu-0006zT-G3 for qemu-devel@nongnu.org; Wed, 28 Jan 2015 10:17:25 -0500 Received: from mx1.redhat.com ([209.132.183.28]:50482) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YGUMu-0006zF-9P for qemu-devel@nongnu.org; Wed, 28 Jan 2015 10:17:24 -0500 Message-ID: <54C8FD7C.8040907@redhat.com> Date: Wed, 28 Jan 2015 16:17:16 +0100 From: Paolo Bonzini MIME-Version: 1.0 References: <54C8FA7B.3050501@greensocs.com> In-Reply-To: <54C8FA7B.3050501@greensocs.com> Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] Thread local TCGContext. List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Frederic Konrad , qemu-devel , mttcg@greensocs.com Cc: Peter Maydell , Mark Burton On 28/01/2015 16:04, Frederic Konrad wrote: > > > /* code generation context */ > -TCGContext tcg_ctx; > +__thread TCGContext tcg_ctx; > > But the big problem is the initialisation, it's done only onetime in the > iothread with > the accelerator.. You need to move it to qemu_tcg_cpu_thread_fn. Paolo