From nobody Wed Apr 16 05:28:14 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; dmarc=fail(p=none dis=none) header.from=linaro.org ARC-Seal: i=1; a=rsa-sha256; t=1560430602; cv=none; d=zoho.com; s=zohoarc; b=Sq8xBi8qjh6upJxxXbUTDlgI/X6/q5euzFIyBbV3nxSJCb+aoHCaTdKfyMnZAlxR9Sl+egZhG3KOLB7PQWTBXZcYgcI1/QA0PMEQdVA6s1pWUMgeN7FZsTbHsYWwxhpLxv3cDUoh62XW+pFksvySaw9DAZE750NCp2eQt+93qh0= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zoho.com; s=zohoarc; t=1560430602; h=Content-Transfer-Encoding:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To:ARC-Authentication-Results; bh=n6lixbnjvJpGmbP+wJzw0YyYNuM8C0qvQLRRdQPH6UY=; b=jTLeOaE5CdpRYKh6Ljucm+zEgZpglyk9TLe51TFMcxu+buNSr8z1oj4cQy0tSHHC6kPM0RFneWQTBXYxzWHZgmaAjkVYinzQlltIYhHURT7kCqa7asSpDQtveX+Ox2mL0Sxy+O6N03TLetlpjaWuu5AFO2V36v5cD0XrrmNZBfk= ARC-Authentication-Results: i=1; mx.zoho.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; dmarc=fail header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (209.51.188.17 [209.51.188.17]) by mx.zohomail.com with SMTPS id 1560430602935468.26827582366695; Thu, 13 Jun 2019 05:56:42 -0700 (PDT) Received: from localhost ([::1]:39532 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hbPHQ-0003Xk-UI for importer@patchew.org; Thu, 13 Jun 2019 08:56:36 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:59131) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hbOdR-00085b-JK for qemu-devel@nongnu.org; Thu, 13 Jun 2019 08:15:19 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hbOdN-0004QP-A0 for qemu-devel@nongnu.org; Thu, 13 Jun 2019 08:15:15 -0400 Received: from mail-wm1-x331.google.com ([2a00:1450:4864:20::331]:34062) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hbOdL-0004Mq-By for qemu-devel@nongnu.org; Thu, 13 Jun 2019 08:15:13 -0400 Received: by mail-wm1-x331.google.com with SMTP id w9so6496220wmd.1 for ; Thu, 13 Jun 2019 05:15:10 -0700 (PDT) Received: from orth.archaic.org.uk (orth.archaic.org.uk. [81.2.115.148]) by smtp.gmail.com with ESMTPSA id y6sm2010576wrp.12.2019.06.13.05.15.08 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 13 Jun 2019 05:15:08 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:subject:date:message-id:in-reply-to:references:mime-version :content-transfer-encoding; bh=n6lixbnjvJpGmbP+wJzw0YyYNuM8C0qvQLRRdQPH6UY=; b=Lnyco95WaHnU9n7B1RJc4kb4AqyZbhXBY9WPW+5ETnNyL4c2QJm7lnqJhKOZVAt0vx C9oUDSvQCm7LB7P2TksNuv6h0M2c9dQ4KcglPuZqIJX+bkcJ/27W91Pd/T8qkraWHEXg keKVbLsj5IA2J+CigRXqUQnm/tvSv+hO3FnjrYLApePECTr4Yt4N5OjvKboUrw0Iu/Q5 g+WxLhv8zvff5Z0Ck2yXl87wReEZxbCxYU47MUp51v7939m+sYURC87BhHa81e3lLBZl +QZC6aHbpvJ6qXc3XY/51DKjz7F0XfwRUo9GfNvcctMBDnB0lsu1ybE1stqlhw/ndz0m KcAg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=n6lixbnjvJpGmbP+wJzw0YyYNuM8C0qvQLRRdQPH6UY=; b=gD51Mc6DWK39VJMt8/+oJ+zmdjgoJ4RwMrB/oiMHeY7CAnefVHexd/6WvoHP7UADUv 3heD3T15TWw4hxS4XMUDGkCLSFg9m8/wD5HYMgfySCPdVmMSoL81hArvil3PGQdCmBlL GyK9O51+yp1Pq7NcO7amroIqgf2RdW5vIirN0OL1yGZUq5vIVshWyMgzXsehmm+JiJFg CH6xgIAMNePUPWcVP06Hc19rdhniqlaxiUuROjM9xtMVWP2Xo9Qg37xeYZF9HOSTBTtu M40xceZ8xJVi49wmyEySyOaFJAawcwxRl8bMkmSHLSfgO3bsy1ovbj7cFiRJf9NJrbCf mBwg== X-Gm-Message-State: APjAAAUktFXkb/Ujp56AxlBPbU2i4d4WjBheHoEBzQw7VzShMsvaCgtv G/MrxFKLWvjd6ZQQsDbH9zCeq1VCM058GQ== X-Google-Smtp-Source: APXvYqzHhEA8dklqytjDCKFAJdqLuxRoCo9txKZS10VfZ7iRFugZ5S11O8eI8QdbKvl8HKczLt+LNQ== X-Received: by 2002:a1c:3942:: with SMTP id g63mr3191936wma.61.1560428108976; Thu, 13 Jun 2019 05:15:08 -0700 (PDT) From: Peter Maydell To: qemu-devel@nongnu.org Date: Thu, 13 Jun 2019 13:14:16 +0100 Message-Id: <20190613121433.5246-32-peter.maydell@linaro.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20190613121433.5246-1-peter.maydell@linaro.org> References: <20190613121433.5246-1-peter.maydell@linaro.org> MIME-Version: 1.0 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::331 Subject: [Qemu-devel] [PULL 31/48] target/arm: Convert VSUB to decodetree X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) Content-Type: text/plain; charset="utf-8" Convert the VSUB instruction to decodetree. Signed-off-by: Peter Maydell Reviewed-by: Richard Henderson --- target/arm/translate-vfp.inc.c | 10 ++++++++++ target/arm/translate.c | 6 +----- target/arm/vfp.decode | 5 +++++ 3 files changed, 16 insertions(+), 5 deletions(-) diff --git a/target/arm/translate-vfp.inc.c b/target/arm/translate-vfp.inc.c index 14aeb25f597..12da3b8acb8 100644 --- a/target/arm/translate-vfp.inc.c +++ b/target/arm/translate-vfp.inc.c @@ -1461,3 +1461,13 @@ static bool trans_VADD_dp(DisasContext *s, arg_VADD_= sp *a) { return do_vfp_3op_dp(s, gen_helper_vfp_addd, a->vd, a->vn, a->vm, fals= e); } + +static bool trans_VSUB_sp(DisasContext *s, arg_VSUB_sp *a) +{ + return do_vfp_3op_sp(s, gen_helper_vfp_subs, a->vd, a->vn, a->vm, fals= e); +} + +static bool trans_VSUB_dp(DisasContext *s, arg_VSUB_sp *a) +{ + return do_vfp_3op_dp(s, gen_helper_vfp_subd, a->vd, a->vn, a->vm, fals= e); +} diff --git a/target/arm/translate.c b/target/arm/translate.c index 2341479a7c2..a7f79395e31 100644 --- a/target/arm/translate.c +++ b/target/arm/translate.c @@ -1386,7 +1386,6 @@ static inline void gen_vfp_##name(int dp) = \ tcg_temp_free_ptr(fpst); \ } =20 -VFP_OP2(sub) VFP_OP2(div) =20 #undef VFP_OP2 @@ -3110,7 +3109,7 @@ static int disas_vfp_insn(DisasContext *s, uint32_t i= nsn) rn =3D VFP_SREG_N(insn); =20 switch (op) { - case 0 ... 6: + case 0 ... 7: /* Already handled by decodetree */ return 1; default: @@ -3296,9 +3295,6 @@ static int disas_vfp_insn(DisasContext *s, uint32_t i= nsn) for (;;) { /* Perform the calculation. */ switch (op) { - case 7: /* sub: fn - fm */ - gen_vfp_sub(dp); - break; case 8: /* div: fn / fm */ gen_vfp_div(dp); break; diff --git a/target/arm/vfp.decode b/target/arm/vfp.decode index d911f12dfd0..de56f44efc9 100644 --- a/target/arm/vfp.decode +++ b/target/arm/vfp.decode @@ -132,3 +132,8 @@ VADD_sp ---- 1110 0.11 .... .... 1010 .0.0 .... \ vm=3D%vm_sp vn=3D%vn_sp vd=3D%vd_sp VADD_dp ---- 1110 0.11 .... .... 1011 .0.0 .... \ vm=3D%vm_dp vn=3D%vn_dp vd=3D%vd_dp + +VSUB_sp ---- 1110 0.11 .... .... 1010 .1.0 .... \ + vm=3D%vm_sp vn=3D%vn_sp vd=3D%vd_sp +VSUB_dp ---- 1110 0.11 .... .... 1011 .1.0 .... \ + vm=3D%vm_dp vn=3D%vn_dp vd=3D%vd_dp --=20 2.20.1