Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1KyjEu-0005Gw-9F for qemu-devel@nongnu.org; Sat, 08 Nov 2008 03:32:16 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1KyjEt-0005Ge-7P for qemu-devel@nongnu.org; Sat, 08 Nov 2008 03:32:15 -0500 Received: from [199.232.76.173] (port=48059 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1KyjEs-0005GZ-RJ for qemu-devel@nongnu.org; Sat, 08 Nov 2008 03:32:15 -0500 Received: from mx20.gnu.org ([199.232.41.8]:19348) by monty-python.gnu.org with esmtps (TLS-1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1KyjEs-0006RK-C6 for qemu-devel@nongnu.org; Sat, 08 Nov 2008 03:32:14 -0500 Received: from hall.aurel32.net ([88.191.82.174]) by mx20.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1KyjEr-0001Ta-NO for qemu-devel@nongnu.org; Sat, 08 Nov 2008 03:32:13 -0500 Date: Sat, 8 Nov 2008 09:32:12 +0100 From: Aurelien Jarno Message-ID: <20081108083212.GC9549@volta.aurel32.net> References: <20081108083118.GB9549@volta.aurel32.net> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-15 Content-Disposition: inline In-Reply-To: <20081108083118.GB9549@volta.aurel32.net> Subject: [Qemu-devel] [PATCH 01/11] target-mips: optimize gen_save_pc() Reply-To: qemu-devel@nongnu.org List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org We obviously don't need to use a temporary variable to write PC. Signed-off-by: Aurelien Jarno --- target-mips/translate.c | 6 +----- 1 files changed, 1 insertions(+), 5 deletions(-) diff --git a/target-mips/translate.c b/target-mips/translate.c index 9a197ee..dcd8094 100644 --- a/target-mips/translate.c +++ b/target-mips/translate.c @@ -827,11 +827,7 @@ OP_CONDZ(ltz, TCG_COND_LT); static inline void gen_save_pc(target_ulong pc) { - TCGv r_tmp = tcg_temp_new(TCG_TYPE_TL); - - tcg_gen_movi_tl(r_tmp, pc); - tcg_gen_mov_tl(cpu_PC, r_tmp); - tcg_temp_free(r_tmp); + tcg_gen_movi_tl(cpu_PC, pc); } static inline void save_cpu_state (DisasContext *ctx, int do_save_pc) -- 1.5.6.5 -- .''`. Aurelien Jarno | GPG: 1024D/F1BCDB73 : :' : Debian developer | Electrical Engineer `. `' aurel32@debian.org | aurelien@aurel32.net `- people.debian.org/~aurel32 | www.aurel32.net