From nobody Sun Nov 9 23:46:11 2025 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1552178461621973.7697140929063; Sat, 9 Mar 2019 16:41:01 -0800 (PST) Received: from localhost ([127.0.0.1]:38160 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1h2mWQ-00084T-8s for importer@patchew.org; Sat, 09 Mar 2019 19:40:58 -0500 Received: from eggs.gnu.org ([209.51.188.92]:47020) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1h2mQK-0003OO-7M for qemu-devel@nongnu.org; Sat, 09 Mar 2019 19:34:43 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1h2mQJ-0001I6-6r for qemu-devel@nongnu.org; Sat, 09 Mar 2019 19:34:40 -0500 Received: from mail-wr1-x443.google.com ([2a00:1450:4864:20::443]:33763) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1h2mQJ-0001H3-0O for qemu-devel@nongnu.org; Sat, 09 Mar 2019 19:34:39 -0500 Received: by mail-wr1-x443.google.com with SMTP id i8so1291180wrm.0 for ; Sat, 09 Mar 2019 16:34:38 -0800 (PST) Received: from x1.local (43.red-88-25-181.staticip.rima-tde.net. [88.25.181.43]) by smtp.gmail.com with ESMTPSA id 12sm29164462wme.25.2019.03.09.16.34.37 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sat, 09 Mar 2019 16:34:37 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=VwkVuDXOE1qqDiObBHK25pvVhgEHDqOLPb9q+LOY5J8=; b=DNHlMhEkF/5WTq7QGf45CnJ7LZvJ3wvAOuhbk20Y1zWpTsUuoecXKTVZtZEoANLp1C wy7qOSlvNwuMHCs5RlVcRVdeQE0ioGNX8RI3NNsOgNGSdPJAmaetC7S539aLpIjUBW7h BdDi5bb7+VIYVTpZYQaO/0oOoREnOp0yHpYtD74YAfyQd0EWlKiqEjzL7NjZtcqV3vVc PzY+WWKmE1bIxu6H99O4oV9jPeK4DKrFdSxbgkx3TEiJ3kiqdIUo+grXyYD7E9uBHdbd FS/luramUkPcqHf01eLxlvfgwt+oxZvx/vV8uyDXmfKYFMEakBL5R4NieSdcjYSeKIwE 1Gsg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=VwkVuDXOE1qqDiObBHK25pvVhgEHDqOLPb9q+LOY5J8=; b=B1Hi7lrkvZCpDuum0HVGY6ldgSfFD7B6xyWjsuItQvlJteSLKz0vWUZm6u19srLr+H JhT/pQxTTT+GG3XjQkJcGMbhly2kwEti3hga6W4GA5dcUvPEQnCZq9Dc11e/BYPrZWms 6LW9aW7RkYEeRpiP+BtzKv97+ZIAdlNx6o86lkB9+xNl6m96iW8WETfFz0qK65bxuo5Y nMDUeJfff4GCeLh6H7RIq4Cbdysclbg2X2VuzX1TtP2g3jRovKUa7x7+cw+EymBYxuwQ ugUy6ks9ZpdDkeo+S2y7pPXTzTOuCbpD8DjCN7BPtJgJZ0taynjt6i9RvMH0/vM2AIE8 ObVQ== X-Gm-Message-State: APjAAAXDoiCF6cnv0OK8A9MZNlUt1IafLHCATXF0eKrZmFhQHWBCxLTu WmQkX1GKVlGFDlFJaYKXrIs= X-Google-Smtp-Source: APXvYqy5ONk1rvjgFHFQkgYlXI4OtPdoWEiY21CWmb52HdwzGmyyS8XrR7mcwaAf22Z+kM5sUV8ffA== X-Received: by 2002:a5d:52ca:: with SMTP id r10mr16273171wrv.187.1552178078107; Sat, 09 Mar 2019 16:34:38 -0800 (PST) From: =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= To: Laurent Vivier , Richard Henderson Date: Sun, 10 Mar 2019 01:34:28 +0100 Message-Id: <20190310003428.11723-7-f4bug@amsat.org> X-Mailer: git-send-email 2.19.1 In-Reply-To: <20190310003428.11723-1-f4bug@amsat.org> References: <20190310003428.11723-1-f4bug@amsat.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2a00:1450:4864:20::443 Subject: [Qemu-devel] [PATCH 6/6] target/m68k: Reduce the scope of the 'zero' tcg_temp X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: qemu-devel@nongnu.org, =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) Reduce the scope of the 'zero' tcg_temp. Since this tcg_temp is allocated with tcg_const_i32(), free it using tcg_temp_free_i32(). Signed-off-by: Philippe Mathieu-Daud=C3=A9 --- target/m68k/translate.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/target/m68k/translate.c b/target/m68k/translate.c index b51b8a2a12..3f27079379 100644 --- a/target/m68k/translate.c +++ b/target/m68k/translate.c @@ -3664,7 +3664,7 @@ static void rotate_x_flags(TCGv reg, TCGv X, int size) /* Result of rotate_x() is valid if 0 <=3D shift <=3D size */ static TCGv rotate_x(TCGv reg, TCGv shift, int left, int size) { - TCGv X, shl, shr, shx, sz, zero; + TCGv X, shl, shr, shx, sz; =20 sz =3D tcg_const_i32(size); =20 @@ -3672,14 +3672,14 @@ static TCGv rotate_x(TCGv reg, TCGv shift, int left= , int size) shl =3D tcg_temp_new(); shx =3D tcg_temp_new(); if (left) { + TCGv zero =3D tcg_const_i32(0); tcg_gen_mov_i32(shl, shift); /* shl =3D shift */ tcg_gen_movi_i32(shr, size + 1); tcg_gen_sub_i32(shr, shr, shift); /* shr =3D size + 1 - shift */ tcg_gen_subi_i32(shx, shift, 1); /* shx =3D shift - 1 */ /* shx =3D shx < 0 ? size : shx; */ - zero =3D tcg_const_i32(0); tcg_gen_movcond_i32(TCG_COND_LT, shx, shx, zero, sz, shx); - tcg_temp_free(zero); + tcg_temp_free_i32(zero); } else { tcg_gen_mov_i32(shr, shift); /* shr =3D shift */ tcg_gen_movi_i32(shl, size + 1); --=20 2.19.1