From patchwork Tue Dec 24 20:05:10 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 853274 Delivered-To: patch@linaro.org Received: by 2002:a5d:4888:0:b0:385:e875:8a9e with SMTP id g8csp4084969wrq; Tue, 24 Dec 2024 12:18:44 -0800 (PST) X-Forwarded-Encrypted: i=2; AJvYcCXizROHGJbRpVim5HcdMG25c2j/bBBi8pLAvqAqB9+virhKK+Th2PJD+MQbZWudzN8z9Psn+w==@linaro.org X-Google-Smtp-Source: AGHT+IGopu/BnCvjSl8hK0lZ7LvfRb4ntU/TqAUcrbzNnf9VXuULZVxD01yt2cXFXqjZMqf2TJlU X-Received: by 2002:a05:620a:4452:b0:7b1:48ff:6b62 with SMTP id af79cd13be357-7b9ba738951mr2536281585a.16.1735071523909; Tue, 24 Dec 2024 12:18:43 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1735071523; cv=none; d=google.com; s=arc-20240605; b=MMw8b14+X4NM+45HLr60xJaECOUSOBYuAzMJvrVBoPxyIyk6BOXuRizIyo3/6s4j8r Dknb4w8zgyGtedXCN5UF9tTSokGqiaeKuwoYiOrD1oGiP9irQPdH+J7vG9Hy3KdY0FB9 HNl3eYVfFRKilHVJGP/jdkiglCOzjXIrUf/vIDpmIvkloOR5kyVlvbOFcTkkeB+AL7Uk hBCyrRavh5REpzU/3QydvH448/Xfye9likrj4qoNHGyk1hDr0zh5kIdAxgIX8H0oo73x ao/nIVzRKmYJaqXk0BVcpZPFYWXXoaHP7TXFQuo8EWDIi2SHHNTJIqTZCgTBO5Y+cvgY efIA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; 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:cc:to :from:dkim-signature; bh=dTGDXG/LHK+cbArsNVQoTZPhYd/l2OlGD8Apa8yjd5c=; fh=erpJr+t1J1nk7LsZaPa1TvOu4e//VqKoadf7h5wHEDQ=; b=lU6oEKysgM3buto+LfcupF3HavP9dWkd8XyJAhMGrXzF0T3jF3aij1vX9k5xhjT9FI mzgh0U8qOpR4sx9zTUIm/FqgvP3t0VKNU/OeB7EZmAPMZunwcigIlzzKZElO9fnmq7Z2 khUJ3Tr5IwOe0aNTekAgpR8YximFPxgYE3ZykbEfrsGpzTBVdP5HvJeY8HsEKfUfZFNy vYecyERD/gejwA89jZmHv8PN0WJaye8d/ln075saMJkJPZlqNUEJcTEgTgwhSHdcRQP8 MXbsRUMT82DnUtHImpVaYYFGcnWRhsPC5dbLquY9SugubILWlzBH1UWTDwcBOASpcM/1 4Utg==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=imwiTqt5; 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; dara=neutral header.i=@linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id af79cd13be357-7b9ac47896dsi1605617285a.265.2024.12.24.12.18.43 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Tue, 24 Dec 2024 12:18:43 -0800 (PST) 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=imwiTqt5; 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; dara=neutral header.i=@linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1tQBDt-00019I-7M; Tue, 24 Dec 2024 15:09:45 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1tQBDY-00073P-Uk for qemu-devel@nongnu.org; Tue, 24 Dec 2024 15:09:25 -0500 Received: from mail-pl1-x634.google.com ([2607:f8b0:4864:20::634]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1tQBDV-0002yv-W5 for qemu-devel@nongnu.org; Tue, 24 Dec 2024 15:09:23 -0500 Received: by mail-pl1-x634.google.com with SMTP id d9443c01a7336-2163dc5155fso55567595ad.0 for ; Tue, 24 Dec 2024 12:09:21 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1735070961; x=1735675761; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=dTGDXG/LHK+cbArsNVQoTZPhYd/l2OlGD8Apa8yjd5c=; b=imwiTqt55KHmMFeNaE75nII/ZaBDuPy4V2/0CiYKrGhPJvZP3fo5s52aC3fAaCl/nI j7p3BAT7W1iST011QE1d4DXMdkLgOgCfa5fRNJJs8Uo7FNQHDrWjVoYmwUPIJTRhQ4pJ vkFs+tKIaOXDq4a6QeGaZswt/h73Sw75jK7REzqhFlLiSYwIFYyvjmaGwD+zFOaLhfcn BMGJOtQuCTdDR+aeumsK8xT76gM26uRH+v6AL6Yte7vLEbzv/K+VFSr54EKyXkBz8GZz xOrjVALZWUueqs84l5SaIn58YwXecIj5bbG7SmLgErS+xC7+C8FQ1bTFB6UQIsXzXPff ftbQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1735070961; x=1735675761; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=dTGDXG/LHK+cbArsNVQoTZPhYd/l2OlGD8Apa8yjd5c=; b=NHVsSth9vzU778W/Kk2Y1v7EdVLkAMSzp9NllZXFVkjB2ez9hEshBiw8ReRIG0l9S1 OFH6TKfVav1ro4GWPMDDSC8AygH6s4VekW5xw+bC4kRKQqobRDs8GegMpY3CszChZ2mM DTjipaUYDTwL/LJ6UDBbJ5A2DFjEROUOZfrpJzX+I3EQTsZImw7dZ6fcjoxec0IsWgs5 RRANxG/fMjlDWYBpAnQ8C1EmuRhDOfvv9iWzksC8L1YSlA5vb8focMIwMMptdcLuG8b4 Y+jD7n+AMVjl9PPdiAGq1iCWaNpxJTJwMJXCZFkHhuctL10OuHCF78z4uXTXTM04+Q1R 84+A== X-Gm-Message-State: AOJu0YyrZFzuy11SuNdC9z3/h0z+4QiNvdhOt8ChQtlV2aQrtEzwgs5K oOZx6sXJbTFrHWpyE71scjm4x1qJjHK+kEMdP2wquc4wfM+X3XqWg1hXomJRusjyYo0QXeHMsP/ 1++U= X-Gm-Gg: ASbGncub3ERq56oZkJiLTCj90ck1uHcfI4x0CLi/nk6VunFUuQm2EGA2iEf9O4tbO1N cqx2Aw0/TOKVQJbSLgyBFOMEzKJiuI4fD7Xn796gqKUE1vnwypP1hCLthPQWq15VjHZWVCdjkCO dcIZrR4JApxvV7/9yDvJvf2w3YZqb30VtJDxh+7z+1mbgUn4OuYuRClgQf5v1anF3hCw98bCdRs GJPkFVtcMTFIw586eJBasXk2/g43wfLLcNhXvPcPfA4sMSsDus5wWvDoLWnd7Hd67mX9fWhEclC yQGCX2GWspSxLJdpW3XxAL4hCg== X-Received: by 2002:a05:6a00:a95:b0:725:d956:aa6f with SMTP id d2e1a72fcca58-72abdd5eea8mr28794770b3a.5.1735070960766; Tue, 24 Dec 2024 12:09:20 -0800 (PST) Received: from stoup.. (syn-156-019-246-023.biz.spectrum.com. [156.19.246.23]) by smtp.gmail.com with ESMTPSA id d2e1a72fcca58-72aad8309acsm10033521b3a.45.2024.12.24.12.09.20 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 24 Dec 2024 12:09:20 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Cc: Brian Cain Subject: [PULL 61/72] target/hexagon: Use float32_mul in helper_sfmpy Date: Tue, 24 Dec 2024 12:05:10 -0800 Message-ID: <20241224200521.310066-62-richard.henderson@linaro.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20241224200521.310066-1-richard.henderson@linaro.org> References: <20241224200521.310066-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::634; envelope-from=richard.henderson@linaro.org; helo=mail-pl1-x634.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 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-bounces+patch=linaro.org@nongnu.org There are no special cases for this instruction. Remove internal_mpyf as unused. Reviewed-by: Brian Cain Signed-off-by: Richard Henderson --- target/hexagon/fma_emu.h | 1 - target/hexagon/fma_emu.c | 8 -------- target/hexagon/op_helper.c | 2 +- 3 files changed, 1 insertion(+), 10 deletions(-) diff --git a/target/hexagon/fma_emu.h b/target/hexagon/fma_emu.h index 91591d6050..ad5df5d038 100644 --- a/target/hexagon/fma_emu.h +++ b/target/hexagon/fma_emu.h @@ -32,7 +32,6 @@ int32_t float32_getexp(float32 f32); float32 infinite_float32(uint8_t sign); float32 internal_fmafx(float32 a, float32 b, float32 c, int scale, float_status *fp_status); -float32 internal_mpyf(float32 a, float32 b, float_status *fp_status); float64 internal_mpyhh(float64 a, float64 b, unsigned long long int accumulated, float_status *fp_status); diff --git a/target/hexagon/fma_emu.c b/target/hexagon/fma_emu.c index 05a56d8c10..35971b8b99 100644 --- a/target/hexagon/fma_emu.c +++ b/target/hexagon/fma_emu.c @@ -655,14 +655,6 @@ float32 internal_fmafx(float32 a, float32 b, float32 c, int scale, return accum_round_float32(result, fp_status); } -float32 internal_mpyf(float32 a, float32 b, float_status *fp_status) -{ - if (float32_is_zero(a) || float32_is_zero(b)) { - return float32_mul(a, b, fp_status); - } - return internal_fmafx(a, b, float32_zero, 0, fp_status); -} - float64 internal_mpyhh(float64 a, float64 b, unsigned long long int accumulated, float_status *fp_status) diff --git a/target/hexagon/op_helper.c b/target/hexagon/op_helper.c index 01d1a1b1a7..d257097091 100644 --- a/target/hexagon/op_helper.c +++ b/target/hexagon/op_helper.c @@ -1045,7 +1045,7 @@ float32 HELPER(sfmpy)(CPUHexagonState *env, float32 RsV, float32 RtV) { float32 RdV; arch_fpop_start(env); - RdV = internal_mpyf(RsV, RtV, &env->fp_status); + RdV = float32_mul(RsV, RtV, &env->fp_status); arch_fpop_end(env); return RdV; }