From patchwork Thu Apr 11 18:15:41 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stefan Weil X-Patchwork-Id: 235875 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [208.118.235.17]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (Client did not present a certificate) by ozlabs.org (Postfix) with ESMTPS id D24BE2C0089 for ; Fri, 12 Apr 2013 04:53:15 +1000 (EST) Received: from localhost ([::1]:35730 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UQM30-0007yI-Ga for incoming@patchwork.ozlabs.org; Thu, 11 Apr 2013 14:16:34 -0400 Received: from eggs.gnu.org ([208.118.235.92]:47548) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UQM2X-0007kQ-WA for qemu-devel@nongnu.org; Thu, 11 Apr 2013 14:16:08 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UQM2V-0006dE-7a for qemu-devel@nongnu.org; Thu, 11 Apr 2013 14:16:05 -0400 Received: from v220110690675601.yourvserver.net ([78.47.199.172]:59776) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UQM2V-0006d3-19 for qemu-devel@nongnu.org; Thu, 11 Apr 2013 14:16:03 -0400 Received: from localhost (v220110690675601.yourvserver.net.local [127.0.0.1]) by v220110690675601.yourvserver.net (Postfix) with ESMTP id 86FD47280065; Thu, 11 Apr 2013 20:15:59 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at weilnetz.de Received: from v220110690675601.yourvserver.net ([127.0.0.1]) by localhost (v220110690675601.yourvserver.net [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id lZbtOHh0nGfM; Thu, 11 Apr 2013 20:15:57 +0200 (CEST) Received: by v220110690675601.yourvserver.net (Postfix, from userid 1000) id 4FB2B728004A; Thu, 11 Apr 2013 20:15:55 +0200 (CEST) From: Stefan Weil To: Anthony Liguori Date: Thu, 11 Apr 2013 20:15:41 +0200 Message-Id: <1365704144-8852-3-git-send-email-sw@weilnetz.de> X-Mailer: git-send-email 1.7.10.4 In-Reply-To: <1365704144-8852-1-git-send-email-sw@weilnetz.de> References: <1365704144-8852-1-git-send-email-sw@weilnetz.de> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 78.47.199.172 Cc: qemu-devel@nongnu.org, Richard Henderson Subject: [Qemu-devel] [PATCH 2/5] tci: Use a local variable for env X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Sender: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org From: Richard Henderson Since we have total conversion away from global AREG0, we do not need a global variable named "env". Retain that name as the function parameter inside the interpreter. Signed-off-by: Richard Henderson Signed-off by: Stefan Weil --- tci.c | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/tci.c b/tci.c index 9ce0be3..77e0980 100644 --- a/tci.c +++ b/tci.c @@ -51,11 +51,6 @@ typedef uint64_t (*helper_function)(tcg_target_ulong, tcg_target_ulong, tcg_target_ulong); #endif -/* TCI can optionally use a global register variable for env. */ -#if !defined(AREG0) -CPUArchState *env; -#endif - /* Targets which don't use GETPC also don't need tci_tb_ptr which makes them a little faster. */ #if defined(GETPC) @@ -438,11 +433,10 @@ static bool tci_compare64(uint64_t u0, uint64_t u1, TCGCond condition) } /* Interpret pseudo code in tb. */ -tcg_target_ulong tcg_qemu_tb_exec(CPUArchState *cpustate, uint8_t *tb_ptr) +tcg_target_ulong tcg_qemu_tb_exec(CPUArchState *env, uint8_t *tb_ptr) { tcg_target_ulong next_tb = 0; - env = cpustate; tci_reg[TCG_AREG0] = (tcg_target_ulong)env; assert(tb_ptr);