From nobody Tue Jul 28 22:00:40 2026 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=linaro.org ARC-Seal: i=1; a=rsa-sha256; t=1777211864; cv=none; d=zohomail.com; s=zohoarc; b=JircA6HrwRqMSUgx3oG6dwT2PFa1IUZIDcp1+KFUG7aa7Rr+tghJhNLFcLl8j3oW4kQFMLaiejQ3nu45lCWdZe4z0vkJJr2/GjYLwHBC4yR8H9og9WkPyOVOd4Vh8KHU2V6tiJ6/CtCBXsRNnWQpXucosbFbz5oKDphb+0bIZkw= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1777211864; h=Content-Transfer-Encoding:Cc:Cc:Date:Date:From:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:Subject:To:To:Message-Id:Reply-To; bh=OOhr11zVvt44EpENvwVC0mN/CNtKtYPzWM2DbHLH1/I=; b=DSa0YaTK6Eceo0uztJR6l27qKSJkMoPBDpvaaYTn2ZQzIcNZtuxG8r7zHtM8hlcm9WVrpWpM5OYyB+I8oah5CV/AwFIPafIEKY3cy/U0luFRfG3Byknz46I251OLthIt3mXHZu9qzDlXq4jQe7TeGd06lBWkjtcpIgcDetEOzeA= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists1p.gnu.org (lists1p.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1777211864043679.65806396811; Sun, 26 Apr 2026 06:57:44 -0700 (PDT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists1p.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1wGzjH-0007Dd-TQ; Sun, 26 Apr 2026 09:40:59 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists1p.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1wGzjF-00079E-0L for qemu-devel@nongnu.org; Sun, 26 Apr 2026 09:40:57 -0400 Received: from mail-pl1-x631.google.com ([2607:f8b0:4864:20::631]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1wGzjD-0008S5-0r for qemu-devel@nongnu.org; Sun, 26 Apr 2026 09:40:56 -0400 Received: by mail-pl1-x631.google.com with SMTP id d9443c01a7336-2b941cd869cso6860625ad.1 for ; Sun, 26 Apr 2026 06:40:54 -0700 (PDT) Received: from stoup.. ([180.233.125.15]) by smtp.gmail.com with ESMTPSA id d9443c01a7336-2b5fab30f29sm277940375ad.68.2026.04.26.06.40.50 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 26 Apr 2026 06:40:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1777210853; x=1777815653; 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=OOhr11zVvt44EpENvwVC0mN/CNtKtYPzWM2DbHLH1/I=; b=SChi2SEvFlIewVxbp7+As4pni2P0n9391p0PHsBh2FmSn1DM/DsocvFuwo+21UDK4z vP7+BPJ67nlpmuXgTFVAjfYNX91n/pCBbqglyG6myr43Qct3s+YaH/drfK7YAfFDA7gZ vA5xvtSXbprVfCRYDJYi04mcb7l4lbi8Ej6RFtC0caPVqKkKPwjk1FntFAmq54Szrrjv HYi6lmMtxYag5SMnEOd+T5vNzCilevX2irU1EyF7u3ZQGsh26nUBMS6ODt2rIErnUccI bohsLlZs+xbckKw9D78jg6L1hm2Zz5E3Yv17qQ/6VTl8zdpeQkY1BKWvPLQPr+BOW/jD n5KA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1777210853; x=1777815653; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=OOhr11zVvt44EpENvwVC0mN/CNtKtYPzWM2DbHLH1/I=; b=dUfOQrM+/0363zvHDP8f0RrG+nu9ICV6EVUwFraGBmCdQKAd4hgBUvyKLf7Na1a0uX 2ejA22W7modKadjxnI23MwP3hIfttyYyYINdHF4u2mnwoJY105JRkidNJTk53YP3Rmjm wl1HLtd7OPZRzVjJYKI+e3hYSoZ0C6ONFkquaEG1JEAPj9uN1D6bxddhW8z9KVi1+ouX mZJds3PVakCdq1SjNp2fTDygaEVWuq2ECzwABSKKiE3vRhWOD3qG9vB2RClEZEMp+Edl TzA+cWhUaJbmgmq4NGVjP90swLiR88uAYAe0eiNyfoyXcq5UFuXunIqFFtwNntSYiVBS 4Jng== X-Gm-Message-State: AOJu0YwLZoJzIpEzxwlUmS0DUQEEwOZkqlXRWzWb+eqDzY14rn3l6k/g mZQ344ujT+ZXJNkvTptylm8/WII7O+QcsBxlxeA13ca3gPUXlky9O7XcB9w5KCECAiEfq8Y0q4X gMlnLFfg= X-Gm-Gg: AeBDievwO5kzRT7tIJIR6PfqgIKri8XZOPunFTW+hpHFb6R26fk/SN1Fg5amy+Y1RYD aArXXaXpwhofTjxgRrDnm/520QerJT+Wt91hpv2kbXTGScuXB7qLEyxlZuK8j29l8GV8MCP/tu+ CjmocQiQOBa5AqixFVe41ZB4nQxPxV+nAL0gPu0tEG9Yv7/kah10CZWNcK4WmBCTuThK5RfDLKX Pzivd6cPRu1+EBNp4J+/zxGAWoCbPJU/vAq+0/rpOCEpPBs/HTBrAwasduPHLpTqBtVzOl0QM7W d0fVvtERC9ThxsH3qRAJRwiycFgAQfjar8sIq5jh41KvLksWmi4e8YwPChfYvfpxRXG3J9lltB8 eiDnF7yL6kwmOKS1U15L7LDL4d4UJ+uf+LTw81iGbD7Y6l8UBXtq+62FWxXms0VOQEzR8iwvWzv aLztgaQvN4nrXSMZGaGg0ATrX8Rh1ZBCQeVaN9CeIx X-Received: by 2002:a17:903:37c4:b0:2b9:601e:da11 with SMTP id d9443c01a7336-2b9601edceemr13915595ad.35.1777210853342; Sun, 26 Apr 2026 06:40:53 -0700 (PDT) From: Richard Henderson To: qemu-devel@nongnu.org Cc: qemu-arm@nongnu.org, qemu-s390x@nongnu.org Subject: [PATCH 17/84] fpu: Drop parts_round_to_int_normal Date: Sun, 26 Apr 2026 23:38:54 +1000 Message-ID: <20260426134002.865628-18-richard.henderson@linaro.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20260426134002.865628-1-richard.henderson@linaro.org> References: <20260426134002.865628-1-richard.henderson@linaro.org> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.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=lists1p.gnu.org; Received-SPF: pass client-ip=2607:f8b0:4864:20::631; envelope-from=richard.henderson@linaro.org; helo=mail-pl1-x631.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=unavailable autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: qemu development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @linaro.org) X-ZM-MESSAGEID: 1777211864809154100 Content-Type: text/plain; charset="utf-8" Signed-off-by: Richard Henderson Reviewed-by: Philippe Mathieu-Daud=C3=A9 --- fpu/softfloat.c | 22 +++++++--------------- fpu/softfloat-parts.c.inc | 10 +++++----- 2 files changed, 12 insertions(+), 20 deletions(-) diff --git a/fpu/softfloat.c b/fpu/softfloat.c index 0a6bc6d580..1f03fcf687 100644 --- a/fpu/softfloat.c +++ b/fpu/softfloat.c @@ -779,14 +779,6 @@ static float128 QEMU_FLATTEN float128_pack_raw(const F= loatParts128 *p) FloatParts128 *: parts128_##NAME, \ FloatParts256 *: parts256_##NAME) =20 -static bool parts64_round_to_int_normal(FloatParts64 *a, FloatRoundMode rm, - int scale, int frac_size); -static bool parts128_round_to_int_normal(FloatParts128 *a, FloatRoundMode = r, - int scale, int frac_size); - -#define parts_round_to_int_normal(A, R, C, F) \ - PARTS_GENERIC_64_128(round_to_int_normal, A)(A, R, C, F) - static void parts64_round_to_int(FloatParts64 *a, FloatRoundMode rm, int scale, float_status *s, const FloatFmt *fmt); @@ -3365,7 +3357,7 @@ static Int128 float128_to_int128_scalbn(float128 a, F= loatRoundMode rmode, =20 case float_class_normal: case float_class_denormal: - if (parts_round_to_int_normal(&p, rmode, scale, 128 - 2)) { + if (parts128_round_to_int_normal(&p, rmode, scale, 128 - 2)) { flags =3D float_flag_inexact; } =20 @@ -3793,7 +3785,7 @@ static Int128 float128_to_uint128_scalbn(float128 a, = FloatRoundMode rmode, =20 case float_class_normal: case float_class_denormal: - if (parts_round_to_int_normal(&p, rmode, scale, 128 - 2)) { + if (parts128_round_to_int_normal(&p, rmode, scale, 128 - 2)) { flags =3D float_flag_inexact; if (p.cls =3D=3D float_class_zero) { r =3D int128_zero(); @@ -5482,11 +5474,11 @@ static void parts_s390_divide_to_integer(FloatParts= 64 *a, FloatParts64 *b, * of distinguishing partial quotients, so ignore the exception. */ *n =3D *q; - parts_round_to_int_normal(n, - is_q_smallish ? - final_quotient_rounding_mode : - float_round_to_zero, - 0, fmt->frac_size); + parts64_round_to_int_normal(n, + is_q_smallish + ? final_quotient_rounding_mode + : float_round_to_zero, + 0, fmt->frac_size); =20 /* Compute precise remainder */ r_precise_buf =3D *b; diff --git a/fpu/softfloat-parts.c.inc b/fpu/softfloat-parts.c.inc index 6e1800b117..9b719ac5cf 100644 --- a/fpu/softfloat-parts.c.inc +++ b/fpu/softfloat-parts.c.inc @@ -1127,7 +1127,7 @@ static void partsN(sqrt)(FloatPartsN *a, float_status= *status, * according to the IEC/IEEE Standard for Binary Floating-Point * Arithmetic. * - * parts_round_to_int_normal is an internal helper function for + * partsN(round_to_int_normal) is an internal helper function for * normal numbers only, returning true for inexact but not directly * raising float_flag_inexact. */ @@ -1270,7 +1270,7 @@ static void partsN(round_to_int)(FloatPartsN *a, Floa= tRoundMode rmode, break; case float_class_normal: case float_class_denormal: - if (parts_round_to_int_normal(a, rmode, scale, fmt->frac_size)) { + if (partsN(round_to_int_normal)(a, rmode, scale, fmt->frac_size)) { float_raise(float_flag_inexact, s); } break; @@ -1316,7 +1316,7 @@ static int64_t partsN(float_to_sint)(FloatPartsN *p, = FloatRoundMode rmode, case float_class_normal: case float_class_denormal: /* TODO: N - 2 is frac_size for rounding; could use input fmt. */ - if (parts_round_to_int_normal(p, rmode, scale, N - 2)) { + if (partsN(round_to_int_normal)(p, rmode, scale, N - 2)) { flags =3D float_flag_inexact; } =20 @@ -1384,7 +1384,7 @@ static uint64_t partsN(float_to_uint)(FloatPartsN *p,= FloatRoundMode rmode, case float_class_normal: case float_class_denormal: /* TODO: N - 2 is frac_size for rounding; could use input fmt. */ - if (parts_round_to_int_normal(p, rmode, scale, N - 2)) { + if (partsN(round_to_int_normal)(p, rmode, scale, N - 2)) { flags =3D float_flag_inexact; if (p->cls =3D=3D float_class_zero) { r =3D 0; @@ -1448,7 +1448,7 @@ static int64_t partsN(float_to_sint_modulo)(FloatPart= sN *p, case float_class_normal: case float_class_denormal: /* TODO: N - 2 is frac_size for rounding; could use input fmt. */ - if (parts_round_to_int_normal(p, rmode, 0, N - 2)) { + if (partsN(round_to_int_normal)(p, rmode, 0, N - 2)) { flags =3D float_flag_inexact; } =20 --=20 2.43.0