Patch Detail
get:
Show a patch.
patch:
Update a patch.
put:
Update a patch.
GET /api/1.2/patches/2234610/?format=api
{ "id": 2234610, "url": "http://patchwork.ozlabs.org/api/1.2/patches/2234610/?format=api", "web_url": "http://patchwork.ozlabs.org/project/qemu-devel/patch/20260507221717.486023-14-richard.henderson@linaro.org/", "project": { "id": 14, "url": "http://patchwork.ozlabs.org/api/1.2/projects/14/?format=api", "name": "QEMU Development", "link_name": "qemu-devel", "list_id": "qemu-devel.nongnu.org", "list_email": "qemu-devel@nongnu.org", "web_url": "", "scm_url": "", "webscm_url": "", "list_archive_url": "", "list_archive_url_format": "", "commit_url_format": "" }, "msgid": "<20260507221717.486023-14-richard.henderson@linaro.org>", "list_archive_url": null, "date": "2026-05-07T22:17:12", "name": "[13/18] fpu: Use accessors for ftz_before_rounding", "commit_ref": null, "pull_url": null, "state": "new", "archived": false, "hash": "bf5750b0f62af2d542f3bd1dd43fc650cfe0727e", "submitter": { "id": 72104, "url": "http://patchwork.ozlabs.org/api/1.2/people/72104/?format=api", "name": "Richard Henderson", "email": "richard.henderson@linaro.org" }, "delegate": null, "mbox": "http://patchwork.ozlabs.org/project/qemu-devel/patch/20260507221717.486023-14-richard.henderson@linaro.org/mbox/", "series": [ { "id": 503289, "url": "http://patchwork.ozlabs.org/api/1.2/series/503289/?format=api", "web_url": "http://patchwork.ozlabs.org/project/qemu-devel/list/?series=503289", "date": "2026-05-07T22:16:59", "name": "fpu: Compress float_status", "version": 1, "mbox": "http://patchwork.ozlabs.org/series/503289/mbox/" } ], "comments": "http://patchwork.ozlabs.org/api/patches/2234610/comments/", "check": "pending", "checks": "http://patchwork.ozlabs.org/api/patches/2234610/checks/", "tags": {}, "related": [], "headers": { "Return-Path": "<qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org>", "X-Original-To": "incoming@patchwork.ozlabs.org", "Delivered-To": "patchwork-incoming@legolas.ozlabs.org", "Authentication-Results": [ "legolas.ozlabs.org;\n\tdkim=pass (2048-bit key;\n unprotected) header.d=linaro.org header.i=@linaro.org header.a=rsa-sha256\n header.s=google header.b=qA3UGcvt;\n\tdkim-atps=neutral", "legolas.ozlabs.org;\n spf=pass (sender SPF authorized) smtp.mailfrom=nongnu.org\n (client-ip=209.51.188.17; helo=lists1p.gnu.org;\n envelope-from=qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org;\n receiver=patchwork.ozlabs.org)" ], "Received": [ "from lists1p.gnu.org (lists1p.gnu.org [209.51.188.17])\n\t(using TLSv1.2 with cipher ECDHE-ECDSA-AES256-GCM-SHA384 (256/256 bits))\n\t(No client certificate requested)\n\tby legolas.ozlabs.org (Postfix) with ESMTPS id 4gBRVC3djnz1yCg\n\tfor <incoming@patchwork.ozlabs.org>; Fri, 08 May 2026 08:18:43 +1000 (AEST)", "from localhost ([::1] helo=lists1p.gnu.org)\n\tby lists1p.gnu.org with esmtp (Exim 4.90_1)\n\t(envelope-from <qemu-devel-bounces@nongnu.org>)\n\tid 1wL72M-0000sy-W9; Thu, 07 May 2026 18:17:43 -0400", "from eggs.gnu.org ([2001:470:142:3::10])\n by lists1p.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)\n (Exim 4.90_1) (envelope-from <richard.henderson@linaro.org>)\n id 1wL72K-0000sX-TO\n for qemu-devel@nongnu.org; Thu, 07 May 2026 18:17:41 -0400", "from mail-oa1-x29.google.com ([2001:4860:4864:20::29])\n by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128)\n (Exim 4.90_1) (envelope-from <richard.henderson@linaro.org>)\n id 1wL72I-0003FI-Fz\n for qemu-devel@nongnu.org; Thu, 07 May 2026 18:17:40 -0400", "by mail-oa1-x29.google.com with SMTP id\n 586e51a60fabf-42fbf95cca8so1028182fac.0\n for <qemu-devel@nongnu.org>; Thu, 07 May 2026 15:17:37 -0700 (PDT)", "from stoup.attlocal.net ([2600:381:c938:6375:9641:bbb2:a93a:bb4c])\n by smtp.gmail.com with ESMTPSA id\n 586e51a60fabf-435573e7254sm45037fac.14.2026.05.07.15.17.35\n for <qemu-devel@nongnu.org>\n (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);\n Thu, 07 May 2026 15:17:35 -0700 (PDT)" ], "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n d=linaro.org; s=google; t=1778192256; x=1778797056; darn=nongnu.org;\n h=content-transfer-encoding:mime-version:references:in-reply-to\n :message-id:date:subject:to:from:from:to:cc:subject:date:message-id\n :reply-to; bh=qpHmtar2AeEUNpLjC+puJZ8I/ID4F4UwiaLMpyjXJYg=;\n b=qA3UGcvt1pxH08QAO4YSe7Ea+8RfVDVVfBEfj8AIOQqBtVSIlPFuVeotHfVi0AZv6T\n cv6eVoIutaujMkHX81wMmOWs8Jrj4SOZ00eMxL9mX7+/Mh1WmzWp183JYGggA07ljICu\n bK2H2cbS6Obyc7rfsn/LgBtCEDfCU3QdtMDD2gx7ODckXEjqL7iRdgHGeds05ZwzReyO\n 0np6Ps/mXYsH/XrRYELnGsNpYCGtUo4uv/bIB8qH0c8px35sEweIpQPNUj/hWZMuWH9P\n AjA0gBMFibM62cCJSeJgjOnH20l0iv6e1TNnnOL/V47PNzM4mXZ7kxx2nSIoB9UqPptn\n OvGg==", "X-Google-DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n d=1e100.net; s=20251104; t=1778192256; x=1778797056;\n h=content-transfer-encoding:mime-version:references:in-reply-to\n :message-id:date:subject:to:from:x-gm-gg:x-gm-message-state:from:to\n :cc:subject:date:message-id:reply-to;\n bh=qpHmtar2AeEUNpLjC+puJZ8I/ID4F4UwiaLMpyjXJYg=;\n b=NCxvtBO8PsOPzQo0yzxgjaNoF0oPzWXKS6ale4pvRcEpDsuyciAEjIKM/o1dNv2WqF\n UbHwjmlWir+6C1PLZB23sLEsRZAsH0RMwucCTBsqvZn5thxBF1Vpt1KPMZv2YS/+Sfem\n MXCWRJlpbJLROkeLnNBV3nNT/qnKg1QV8X2+55EDCJSNzaJi3zoz0roBLa3iGhZR/EWt\n Aj52FVWf03W3useWbbk2kiD4/ztwm/7Mgvg9PiJaonSh4ORyYz2fpLVTIWhG8L9aJDIY\n FO4excSIdzaWI4Bhncm8Ho+k5V0p5fPsaVUnMSX/SHjZZDYlwBES49rCWH3bUhWTYYfu\n 9hKA==", "X-Gm-Message-State": "AOJu0Yzf1hq+JKZzDLEUXfDc48z+gnhfCURAKIUFF/i9rMpvYqdap1Eu\n K5+MIFbKcnSENnBs3Soe+a8RcbvT21M9CpzwNwr5IUBH0a00EkkJl26+7mqkbAQAXUcbvM+gkc0\n FoGxb", "X-Gm-Gg": "AeBDiesKdMopC5rVttGDaNGiTI/TTLDXAANMm/r+SgS2cSD9Bn6XVMU4S59TVPFDoxR\n 1/dTEh9ugOvYarudCHEqQ9bcW8mFssSDTYi82pTefAbbLPm4jvt5bzxysLIlmSleT5qquRkGePt\n S4HQnsZ7tZv7OO7QuiBLviWQYVehmTmR4DyY2B6xO7Om85W1jKcWx27keTxPNucp2pD+4TPAZPN\n C2dBPh2Gj7TQ3hsK5r3CgV0LelKcg6cX8+chYdR8C014+JDDTGPXiXvCd9Ri/SfJuk9Tv/7igTi\n /LH/E90ihzV36GjewsnRMiPK+ETnctxhsVqMeYLG1TRsOnbf0K4W7mWMZjWhEsXOeOpF7JaVkRU\n jf42n/cMcpqGnr+hNEkCH416Qqe9+QDBpgJMVgtYa2x7sKTHQ6Pv1hEZ/znHyEDWMZhn7y6lJec\n cjC2fMDKjGrUC7tSIkoP0ABU0JOfnMme0KBYLPKtae6y7bUoLs3r1yLsyb", "X-Received": "by 2002:a05:6870:889d:b0:42d:a405:efe1 with SMTP id\n 586e51a60fabf-43556ebb4camr109454fac.22.1778192256224;\n Thu, 07 May 2026 15:17:36 -0700 (PDT)", "From": "Richard Henderson <richard.henderson@linaro.org>", "To": "qemu-devel@nongnu.org", "Subject": "[PATCH 13/18] fpu: Use accessors for ftz_before_rounding", "Date": "Thu, 7 May 2026 17:17:12 -0500", "Message-ID": "<20260507221717.486023-14-richard.henderson@linaro.org>", "X-Mailer": "git-send-email 2.43.0", "In-Reply-To": "<20260507221717.486023-1-richard.henderson@linaro.org>", "References": "<20260507221717.486023-1-richard.henderson@linaro.org>", "MIME-Version": "1.0", "Content-Transfer-Encoding": "8bit", "Received-SPF": "pass client-ip=2001:4860:4864:20::29;\n envelope-from=richard.henderson@linaro.org; helo=mail-oa1-x29.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,\n DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1,\n RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001,\n 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": "qemu development <qemu-devel.nongnu.org>", "List-Unsubscribe": "<https://lists.nongnu.org/mailman/options/qemu-devel>,\n <mailto:qemu-devel-request@nongnu.org?subject=unsubscribe>", "List-Archive": "<https://lists.nongnu.org/archive/html/qemu-devel>", "List-Post": "<mailto:qemu-devel@nongnu.org>", "List-Help": "<mailto:qemu-devel-request@nongnu.org?subject=help>", "List-Subscribe": "<https://lists.nongnu.org/mailman/listinfo/qemu-devel>,\n <mailto:qemu-devel-request@nongnu.org?subject=subscribe>", "Errors-To": "qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org", "Sender": "qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org" }, "content": "Drop FloatFTZDetection and use #defines, like we do for\ntininess_before_rounding. Rename get_float_ftz_detection\nto get_ftz_before_rounding and move to softfloat.c, as\nthere are no external users.\n\nSigned-off-by: Richard Henderson <richard.henderson@linaro.org>\n---\n include/fpu/softfloat-helpers.h | 10 ++--------\n include/fpu/softfloat-types.h | 8 +++-----\n fpu/softfloat-parts.c.inc | 5 ++---\n fpu/softfloat-specialize.c.inc | 5 +++++\n 4 files changed, 12 insertions(+), 16 deletions(-)", "diff": "diff --git a/include/fpu/softfloat-helpers.h b/include/fpu/softfloat-helpers.h\nindex 395ce67abf..d36e3a24b1 100644\n--- a/include/fpu/softfloat-helpers.h\n+++ b/include/fpu/softfloat-helpers.h\n@@ -116,10 +116,9 @@ static inline void set_flush_inputs_to_zero(bool val, float_status *status)\n status->flush_inputs_to_zero = val;\n }\n \n-static inline void set_float_ftz_detection(FloatFTZDetection d,\n- float_status *status)\n+static inline void set_float_ftz_detection(bool val, float_status *status)\n {\n- status->ftz_detection = d;\n+ status->ftz_before_rounding = val;\n }\n \n static inline void set_default_nan_mode(bool val, float_status *status)\n@@ -198,9 +197,4 @@ static inline FloatSNaNRule get_snan_rule(float_status *status)\n return status->float_snan_rule;\n }\n \n-static inline FloatFTZDetection get_float_ftz_detection(const float_status *status)\n-{\n- return status->ftz_detection;\n-}\n-\n #endif /* SOFTFLOAT_HELPERS_H */\ndiff --git a/include/fpu/softfloat-types.h b/include/fpu/softfloat-types.h\nindex b8ce8ff78e..b83f67defc 100644\n--- a/include/fpu/softfloat-types.h\n+++ b/include/fpu/softfloat-types.h\n@@ -341,10 +341,8 @@ typedef enum __attribute__((__packed__)) {\n * configure it matches the default for tininess_before_rounding\n * (i.e. \"after rounding\").\n */\n-typedef enum __attribute__((__packed__)) {\n- float_ftz_after_rounding = 0,\n- float_ftz_before_rounding = 1,\n-} FloatFTZDetection;\n+#define float_ftz_after_rounding false\n+#define float_ftz_before_rounding true\n \n /*\n * floatx80 is primarily used by x86 and m68k, and there are\n@@ -416,7 +414,7 @@ typedef struct float_status {\n /* should denormalised results go to zero and set output_denormal_flushed? */\n bool flush_to_zero;\n /* do we detect and flush denormal results before or after rounding? */\n- FloatFTZDetection ftz_detection;\n+ bool ftz_before_rounding;\n /* should denormalised inputs go to zero and set input_denormal_flushed? */\n bool flush_inputs_to_zero;\n bool default_nan_mode;\ndiff --git a/fpu/softfloat-parts.c.inc b/fpu/softfloat-parts.c.inc\nindex ddef8cc089..22c11171f3 100644\n--- a/fpu/softfloat-parts.c.inc\n+++ b/fpu/softfloat-parts.c.inc\n@@ -421,8 +421,7 @@ static void partsN(uncanon_normal)(FloatPartsN *p, float_status *s,\n p->frac_lo &= ~round_mask;\n }\n fracN(shr)(p, frac_shift);\n- } else if (get_flush_to_zero(s) &&\n- s->ftz_detection == float_ftz_before_rounding) {\n+ } else if (get_flush_to_zero(s) && get_ftz_before_rounding(s)) {\n flags |= float_flag_output_denormal_flushed;\n p->cls = float_class_zero;\n exp = 0;\n@@ -473,7 +472,7 @@ static void partsN(uncanon_normal)(FloatPartsN *p, float_status *s,\n \n if (is_tiny) {\n if (get_flush_to_zero(s)) {\n- assert(s->ftz_detection == float_ftz_after_rounding);\n+ assert(!get_ftz_before_rounding(s));\n flags |= float_flag_output_denormal_flushed;\n p->cls = float_class_zero;\n exp = 0;\ndiff --git a/fpu/softfloat-specialize.c.inc b/fpu/softfloat-specialize.c.inc\nindex ac3fc85138..bde68aa0ec 100644\n--- a/fpu/softfloat-specialize.c.inc\n+++ b/fpu/softfloat-specialize.c.inc\n@@ -84,6 +84,11 @@ static inline bool get_tininess_before_rounding(const float_status *status)\n return status->tininess_before_rounding;\n }\n \n+static inline bool get_ftz_before_rounding(const float_status *status)\n+{\n+ return status->ftz_before_rounding;\n+}\n+\n /*----------------------------------------------------------------------------\n | For the deconstructed floating-point with fraction FRAC, return true\n | if the fraction represents a signalling NaN; otherwise false.\n", "prefixes": [ "13/18" ] }