From patchwork Mon May 30 16:06:29 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Peter Maydell X-Patchwork-Id: 577270 Delivered-To: patch@linaro.org Received: by 2002:a05:7000:330b:0:0:0:0 with SMTP id f11csp432595mag; Mon, 30 May 2022 10:24:54 -0700 (PDT) X-Google-Smtp-Source: ABdhPJy/0g+coP99h9QNqf0SYlaGRFHaRD7pCt8+tgqiQXWg1SUFHa9j+Xib6i1dgUjZDHj0hsRO X-Received: by 2002:a05:622a:30e:b0:2f3:cfab:77a4 with SMTP id q14-20020a05622a030e00b002f3cfab77a4mr44595166qtw.326.1653931494106; Mon, 30 May 2022 10:24:54 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1653931494; cv=none; d=google.com; s=arc-20160816; b=W8wF+PUOfbRD+9/Nwa5qymWWB4L9Vmxi2CPGqYPQ/CGedocq6L1d/sM+86jiV7Sm2l l0/Ong2DygPxhj10DHZKTafKYTReX7hYSt+CnoJqt99O7eGMkCHsNFK97/sJYsnqnBkE q5qVyUOfSHnurz/uxJiwB9NQlpQJw+HV2x+k3fQVvJjHe4QcGKuEUVB4HFSMLfxVxw8N W3+oMSoU7Ob0yohiRPNaLM82Kng4oPjm7CV8GfthxR7WXqfbqfaogjMfmJV+uZ59fl9H LaelWH7cbA4oFqjjetSOEip9ieE6GH1nyhiFu9UKx5K6ugOiAl/kIivo/1J94rRjLpvJ zNZA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=yOfBGJsQ6kG2clBgPZOWH9zA3Hm2JWOzez0eyAwJGf8=; b=TaMul3v5xKlFiIDqDy9sp9wi+S+D0oPT8NfAjqArF7HgWFj9sSESCLPm4ttwg6fySp ltP8Se3/M25gsBwZxt5fuGcBGpnOq8PaYif4zcXYGm6i4dVxrefPhTDOFyLFqeehR6ls pzXnD4u21YUxGsR0JOGw9HNGtN9LtFpnEyKGMuhAdV6JawA6PS5uyTNOXcY6bO1Uxvc2 q6OEgUG7m0NYgfdTWqLLkyszzXAWr4q7utfFAAB6e2p0VSyDHrqwtCcppuVkyNxGm9Q7 JZoqe4YMbS9uRjOwDbhWrM/G3eA2b80LlxWMTpJYvDkdtAMifBld5SeY0UCVYLsaSS/m Cneg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=IL1Qp3TL; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id v9-20020a05622a130900b002f3b4aa7030si8683762qtk.27.2022.05.30.10.24.54 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Mon, 30 May 2022 10:24:54 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=IL1Qp3TL; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:45884 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1nvj8P-0007B3-M2 for patch@linaro.org; Mon, 30 May 2022 13:24:53 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:39862) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nvhwU-0003xV-Hg for qemu-devel@nongnu.org; Mon, 30 May 2022 12:08:31 -0400 Received: from mail-wr1-x430.google.com ([2a00:1450:4864:20::430]:44833) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1nvhwQ-0007QN-In for qemu-devel@nongnu.org; Mon, 30 May 2022 12:08:30 -0400 Received: by mail-wr1-x430.google.com with SMTP id e25so4655035wra.11 for ; Mon, 30 May 2022 09:08:23 -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=yOfBGJsQ6kG2clBgPZOWH9zA3Hm2JWOzez0eyAwJGf8=; b=IL1Qp3TLKwuiClquIE4GIraSqF7RykopY7alnQF9JfkkWfWlyDm8QYi4wz9demdM7W uxpwDtnFGBoTdoVHuhuBJMi1aNrj/NO9x2U7dRg5ax6lKPH+UI1hr6x4ilP3NalDEC1c C1N4VmMoh52XRGcfSRmoUPocqfhPpkqpJdIThvBAMRHzB5yZLBauf66R+WmMYzXzstwD wsWP1B2IoNi+6R+BHN3HFrFNSKfc2nHvdzr2Vo7EP/2YoZlmJ+EDiUje6gbDwD8Dcr4/ lUt6ewaI+VLAPUCXnlxwFEvqfTZdzLATuUy70uuU4gJMj82zoxvnxlVHrVGrUhRh48D+ Qb3A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=yOfBGJsQ6kG2clBgPZOWH9zA3Hm2JWOzez0eyAwJGf8=; b=D3YJM8Hn6hFO3ZE1VaVUcbxz+DPcPfNSyxcnula5lO9tFcTEe35kbDjjyqgLURqGqU cUFiP1p/wjeJuwnnpfWqZzTmWvnxWZTd6xEvJ12Bu6dAuSGkOip/kmu/pweA3ougWH2r Oy5GEnnZDaoM3lG/RSzxJ+RGtEzQ6mOMIQuqfe9RKPQLlcV1HTHXXdkkf0H3C06zvj26 nJmRpGGSKKNpbCb2mfbg5V3A6bCBzmnd8aIQvrEQydd3LrcyQiv/yR0EjfeGrZa4l4on bJ//KCIRQInWr8UAq8xgSQu0l/PiwtYFZE5/6TlQI2VvF6AqShu+9txtp3fS7jCu7rkq lYgQ== X-Gm-Message-State: AOAM531WDUfOd4HM+56J7Mm2cC0f/U3sFbEQ+pEbyQjxtH/xSu4467U/ UPp2n9lxt/vvZ6Z9jIjnEKlWHWeOZWEYFQ== X-Received: by 2002:a5d:47c5:0:b0:20e:73a0:79a0 with SMTP id o5-20020a5d47c5000000b0020e73a079a0mr43526239wrc.632.1653926902538; Mon, 30 May 2022 09:08:22 -0700 (PDT) Received: from orth.archaic.org.uk (orth.archaic.org.uk. [2001:8b0:1d0::2]) by smtp.gmail.com with ESMTPSA id bi12-20020a05600c3d8c00b003974b95d897sm10232152wmb.37.2022.05.30.09.08.21 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 30 May 2022 09:08:22 -0700 (PDT) From: Peter Maydell To: qemu-devel@nongnu.org Subject: [PULL 078/117] target/arm: Use TRANS_FEAT for do_zzi_sat Date: Mon, 30 May 2022 17:06:29 +0100 Message-Id: <20220530160708.726466-79-peter.maydell@linaro.org> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20220530160708.726466-1-peter.maydell@linaro.org> References: <20220530160708.726466-1-peter.maydell@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::430; envelope-from=peter.maydell@linaro.org; helo=mail-wr1-x430.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" From: Richard Henderson Signed-off-by: Richard Henderson Message-id: 20220527181907.189259-76-richard.henderson@linaro.org Reviewed-by: Peter Maydell Signed-off-by: Peter Maydell --- target/arm/translate-sve.c | 23 ++++------------------- 1 file changed, 4 insertions(+), 19 deletions(-) diff --git a/target/arm/translate-sve.c b/target/arm/translate-sve.c index 6b2f235e4a7..e6434589f46 100644 --- a/target/arm/translate-sve.c +++ b/target/arm/translate-sve.c @@ -3313,25 +3313,10 @@ static bool do_zzi_sat(DisasContext *s, arg_rri_esz *a, bool u, bool d) return true; } -static bool trans_SQADD_zzi(DisasContext *s, arg_rri_esz *a) -{ - return do_zzi_sat(s, a, false, false); -} - -static bool trans_UQADD_zzi(DisasContext *s, arg_rri_esz *a) -{ - return do_zzi_sat(s, a, true, false); -} - -static bool trans_SQSUB_zzi(DisasContext *s, arg_rri_esz *a) -{ - return do_zzi_sat(s, a, false, true); -} - -static bool trans_UQSUB_zzi(DisasContext *s, arg_rri_esz *a) -{ - return do_zzi_sat(s, a, true, true); -} +TRANS_FEAT(SQADD_zzi, aa64_sve, do_zzi_sat, a, false, false) +TRANS_FEAT(UQADD_zzi, aa64_sve, do_zzi_sat, a, true, false) +TRANS_FEAT(SQSUB_zzi, aa64_sve, do_zzi_sat, a, false, true) +TRANS_FEAT(UQSUB_zzi, aa64_sve, do_zzi_sat, a, true, true) static bool do_zzi_ool(DisasContext *s, arg_rri_esz *a, gen_helper_gvec_2i *fn) {