From patchwork Fri Nov 19 16:04:52 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 519270 Delivered-To: patch@linaro.org Received: by 2002:ac0:c605:0:0:0:0:0 with SMTP id p5csp2746661imj; Fri, 19 Nov 2021 08:28:18 -0800 (PST) X-Google-Smtp-Source: ABdhPJyrtqU6ivhhVXLy4GgAAuhFVbXElAEpRtHfCTnnSt10h6sUIXDM9/tVyC4WWIdnkNfqdTzj X-Received: by 2002:ac8:7e90:: with SMTP id w16mr7518078qtj.257.1637339298477; Fri, 19 Nov 2021 08:28:18 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1637339298; cv=none; d=google.com; s=arc-20160816; b=c+5AxDkZMxPZt8rCA7FnxQzGrrJ4vO3aQuSyw0KI0Ywmvr06nSqtz5xRlS9hPm2BY5 HVZwJloWAMXK4P/gkcbxsNsjvaaB2ri9TuKbSgtUK2uC0AxCPl3OqsZ/NQbRYIjmzMjF M4NdFbI3Hbmkqz/MgcuBLOlibZAyHGNV86yuFHYm/NNhIeCzh3GVYQUG5dJIH6SeY8gc vNRnowX+5OyxZyEdNWF1jzuGl/0bCucwL9JuyPYAU/yoONxeXYOkfRURDwQVSt8Et6sT YPPnXZ4hAJfh2jEgi3EMFdkyTEaQgGHZtWelZHAjtJPlg9bz+/k6sCY0E/HyXuFifFRs Mncw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc: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=hJYMrWgBLbvrLnER5gqNxXtDWmn4A7cBf68IZ0GsqMY=; b=NYdJ0fG10Ddk2FTv83OKjrDc4kYZQIjlEzvQpY+OK6cpCEEJFycVJE9PcEPdAfgwoS zsz2BCFnv9Bpd+OkQ4VeJKe94moVD8l/OtaTSh7EkW1HQTwURnRtfNAX4kqFgjArkDSm PguY91CmnM9Lt0narzKHmup8uQg5slSHbtIn5vXVZpXlAWcpOOI079kCNrXG9qap2ld5 omwgcFCo8V837Cgxub2RgJ64xlEStWyCpzr8etAupTVxRNr6AVbCr4LGMMEWFtoR0tIa 10SH64ncu3sbJXwxGOStTcJ8IPchtv4iYxHmt21iIQQJf2YHhOFeF7I6pn40eH35lWoI k3Dw== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=xHBjhQiy; 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=fail (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 t10si450857qtc.118.2021.11.19.08.28.18 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 19 Nov 2021 08:28:18 -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=fail header.i=@linaro.org header.s=google header.b=xHBjhQiy; 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=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:56778 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mo6kL-0005tH-UR for patch@linaro.org; Fri, 19 Nov 2021 11:28:17 -0500 Received: from eggs.gnu.org ([209.51.188.92]:44266) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mo6Ov-0006WP-3M for qemu-devel@nongnu.org; Fri, 19 Nov 2021 11:06:09 -0500 Received: from [2a00:1450:4864:20::335] (port=33382 helo=mail-wm1-x335.google.com) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1mo6Ot-0004TO-KY for qemu-devel@nongnu.org; Fri, 19 Nov 2021 11:06:08 -0500 Received: by mail-wm1-x335.google.com with SMTP id r9-20020a7bc089000000b00332f4abf43fso8029413wmh.0 for ; Fri, 19 Nov 2021 08:06:07 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=hJYMrWgBLbvrLnER5gqNxXtDWmn4A7cBf68IZ0GsqMY=; b=xHBjhQiyR0UT3bi8zLicgY6s95KFyObAnKUjDDjYFJCbfNvnKJ51NmCNIMQL4TrySX B8baOTtXMO9KX04nXASzK+AWNq8uo+IVPXZLktTTQmpKgFS+5TFg+XQ6yS9+QP7LutqF YS7VrASDGRiA85/bHzDbYOorezCSazgyZTTNr0/pi8ONnpcNjgo5ODJbNAWGKyic120D L7WGrPLEtjzzyW/cHKJh3YSlhAk3P+ywFvaey22bgsgUZE0TUFxdLMU0ZTb60pUKkt9Z 9GV4q99JyBJzI/h6A1x13Eytkxxn3tqE/caZUcMEp+pwTr9/+csg/T7ERA3tYUEov4/A snpw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=hJYMrWgBLbvrLnER5gqNxXtDWmn4A7cBf68IZ0GsqMY=; b=j2VIAAbx2HvkV6fd3VAmDwvvl/bnJejaW99ygb3t2MV9TPvCUYr56dw5LmzX64heoD bGKkkxQwccwCdj3pZZklWbgh6Yf0j/6p+baIN2wIHCMc8Dvg1ZOgGjARL5oyQjCMODb/ 9pSpB2lRHOGW2rM/AI/BY68qacSD5L+EfneLbXdHRQtw6EEwqyb4gToZWrI/ay0XwLZe 9drYxG/AMkpKSIgrMiPP1ryWgBpLLwwzLABcHzRWFnCxTEnapKa0Q6E4QzEAUstqhHaa URFxRlQUeePndXPLQ24lNDOr/gGHnKYDNVhWkMH1NkBB+m9SkOcL6xhhy/ktUJ7l5qBP QOUA== X-Gm-Message-State: AOAM533M88vim29P9c8yyf8lw3f9A+FCBmJ+rViD/ePQRswZbECl5qst AuGHNw5kwlg4UZHHyh5B3iRdsP+k3gmrxNZkgI0= X-Received: by 2002:a05:600c:1e06:: with SMTP id ay6mr979917wmb.64.1637337966209; Fri, 19 Nov 2021 08:06:06 -0800 (PST) Received: from localhost.localdomain (165.red-37-158-79.dynamicip.rima-tde.net. [37.158.79.165]) by smtp.gmail.com with ESMTPSA id q84sm14044877wme.3.2021.11.19.08.06.04 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 19 Nov 2021 08:06:05 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Subject: [PATCH 25/35] target/ppc: Update xsrqpi and xsrqpxp to new flags Date: Fri, 19 Nov 2021 17:04:52 +0100 Message-Id: <20211119160502.17432-26-richard.henderson@linaro.org> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20211119160502.17432-1-richard.henderson@linaro.org> References: <20211119160502.17432-1-richard.henderson@linaro.org> MIME-Version: 1.0 X-Host-Lookup-Failed: Reverse DNS lookup failed for 2a00:1450:4864:20::335 (failed) Received-SPF: pass client-ip=2a00:1450:4864:20::335; envelope-from=richard.henderson@linaro.org; helo=mail-wm1-x335.google.com X-Spam_score_int: -12 X-Spam_score: -1.3 X-Spam_bar: - X-Spam_report: (-1.3 / 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, PDS_HP_HELO_NORDNS=0.001, RCVD_IN_DNSWL_NONE=-0.0001, RDNS_NONE=0.793, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=no 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: , Cc: qemu-ppc@nongnu.org, danielhb413@gmail.com, alex.bennee@linaro.org, clg@kaod.org Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" Use float_flag_invalid_snan instead of recomputing the snan-ness of the operand. Signed-off-by: Richard Henderson --- target/ppc/fpu_helper.c | 15 +++++---------- 1 file changed, 5 insertions(+), 10 deletions(-) diff --git a/target/ppc/fpu_helper.c b/target/ppc/fpu_helper.c index f17d5a1af1..f46d529f04 100644 --- a/target/ppc/fpu_helper.c +++ b/target/ppc/fpu_helper.c @@ -3090,11 +3090,8 @@ void helper_xsrqpi(CPUPPCState *env, uint32_t opcode, t.f128 = float128_round_to_int(xb->f128, &tstat); env->fp_status.float_exception_flags |= tstat.float_exception_flags; - if (unlikely(tstat.float_exception_flags & float_flag_invalid)) { - if (float128_is_signaling_nan(xb->f128, &tstat)) { - float_invalid_op_vxsnan(env, GETPC()); - t.f128 = float128_snan_to_qnan(t.f128); - } + if (unlikely(tstat.float_exception_flags & float_flag_invalid_snan)) { + float_invalid_op_vxsnan(env, GETPC()); } if (ex == 0 && (tstat.float_exception_flags & float_flag_inexact)) { @@ -3148,11 +3145,9 @@ void helper_xsrqpxp(CPUPPCState *env, uint32_t opcode, t.f128 = floatx80_to_float128(round_res, &tstat); env->fp_status.float_exception_flags |= tstat.float_exception_flags; - if (unlikely(tstat.float_exception_flags & float_flag_invalid)) { - if (float128_is_signaling_nan(xb->f128, &tstat)) { - float_invalid_op_vxsnan(env, GETPC()); - t.f128 = float128_snan_to_qnan(t.f128); - } + if (unlikely(tstat.float_exception_flags & float_flag_invalid_snan)) { + float_invalid_op_vxsnan(env, GETPC()); + t.f128 = float128_snan_to_qnan(t.f128); } helper_compute_fprf_float128(env, t.f128);