From patchwork Fri Oct 25 14:12:40 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Peter Maydell X-Patchwork-Id: 838347 Delivered-To: patch@linaro.org Received: by 2002:adf:e287:0:b0:37d:45d0:187 with SMTP id v7csp306529wri; Fri, 25 Oct 2024 07:14:41 -0700 (PDT) X-Forwarded-Encrypted: i=2; AJvYcCWDBAXrusDnYYwQ0CiOGl1Lxc1QfJzLkV57Mtb27+U0hpWjflgI5o4A7KRUjjCZvlvKbY7V2g==@linaro.org X-Google-Smtp-Source: AGHT+IHcY/5+vqgnMSQIbaaLHljDdgkJlmzOnSjE2aDyCdw33UzMIVhUKJ2b4Fn3MSREqqJgZpZv X-Received: by 2002:ac8:59d3:0:b0:461:1212:c5c2 with SMTP id d75a77b69052e-461146d6743mr149593711cf.26.1729865680935; Fri, 25 Oct 2024 07:14:40 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1729865680; cv=none; d=google.com; s=arc-20240605; b=k85JCI8R2GoIpEEkt83VSlpBczX6NlhuRmsx1gTsaZgN+Hg2Lr1ebJscxEIUItOjHD yn/7y0bwUwXlhye/N4OtrFgWmtIeRk0ciuqmfwbMX5yrYxV6FrCEuj1Xsp/393Wrtofg qixPMNV/NNsYiezsDtTJHCcystIHJnstPRAgCJmAkrUnadbbmD43NcSF5YiVU88S5YPW 54vuikxseDFW7sxxN6taMvuA1HvrC82ovh11TqgWnKWhW9XtdrWb2zihAArEtmnGwV9H +U6KNwUVcnfoOgVJuyuwouPITSEd2qc4rYubKcKwcaIVhT/sJWldPzWFNBeUjicZa+os HcMQ== 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=ixfMug0zlUN7NkGJexyOs+kqoUuLgEjdmFA8bPjqRvc=; fh=C3XY52Z9mcVnQeyeWcjqrJn3izWJL/WCux1k8ARP3FU=; b=Mc2fcEgwlaJ8LYGOsZ+jMX/olyWfsHbgemCvV0CGLknQeMNA6bHWZpArGI5SGuc2ue yfvWY5ZBrXBYyFxvQT7RAZiikiqi1UlqF2MUdSh2QVBOlfrJ86nPOfd39awv2UQbds6b UpjWro+di3k3YUNnc1hbG+JSvVDVO4UN1xtN+FEBB3ppK/mnVtrxXlpOlvflQ04HlsiH uxjl7syZrXge+5wPAkXQwcLev7v2kJPA0WMbldoM+G5Ed960uaC1b8oYSx9E+rK5xppt T9HdRuc8NNIS9Dop8boFXYp/QLstdgAjJ29JOTnXg0IzKuA9v/POV44mbCpciI/FOeMz kb8w==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=JpVzLQtj; 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 d75a77b69052e-4613235db6csi16616661cf.302.2024.10.25.07.14.40 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 25 Oct 2024 07:14:40 -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=JpVzLQtj; 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 1t4L41-0004D7-Lk; Fri, 25 Oct 2024 10:13:17 -0400 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 1t4L3u-00046L-Sz for qemu-devel@nongnu.org; Fri, 25 Oct 2024 10:13:10 -0400 Received: from mail-wm1-x336.google.com ([2a00:1450:4864:20::336]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1t4L3o-0007oF-4K for qemu-devel@nongnu.org; Fri, 25 Oct 2024 10:13:10 -0400 Received: by mail-wm1-x336.google.com with SMTP id 5b1f17b1804b1-43163667f0eso20598895e9.0 for ; Fri, 25 Oct 2024 07:13:03 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1729865582; x=1730470382; 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=ixfMug0zlUN7NkGJexyOs+kqoUuLgEjdmFA8bPjqRvc=; b=JpVzLQtjMem9QPEwwD3MqYVycr9HYRhFThvWx+Fuefmmu+UxPRnIq6zwTlOlu3H/Iv fBCDTcG81/1h6pDE/nDvb/09WFZZ2PSYXpnL4M7XwwLWbIcGqFv3mbLquuKNMhCRcs7/ 42yvrZDUe41Oj+GeGD9r1a0xSaEwCCmagyWe9Ehd6OBWVfLh/RVWKsYFwN+0/6Jaz+ui Kn2hwdJEDqwG/eBUOFeJjWKTdjbbYYsuOOGObRM/ra4NzwgTMDWKE5B2t9/G+Y2u5Vm7 qAgB9TJR6u3Rj5xi260sfhv3TegnrEDJWQgLN7gTyBvYN2gyX1TXZUNAUCx2n1x85zrF rwXw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1729865582; x=1730470382; 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=ixfMug0zlUN7NkGJexyOs+kqoUuLgEjdmFA8bPjqRvc=; b=Im2cc6sBuEq4lo+LahpVlvlA8wFP/OnWUT571MpJFGfhvAaRFhELdCv8l9z2fg2fzu t9sgWBHe0osflxmoPWPWBD0TKMQjuKUqavCk00tzkf8LohTac9z3/Cs4s03YYdhhW2Ec V/uogw1Vq1KhYbDyoDexZyHMQI+xZLdzngEjNSqng8VZAfKMF+mgyQ0w5TrQSc6oVSht HsQA9lWiXV7bCZMBVRF6fcE3nFy/JZbQnmMJgyJw/dt5pZL5DnBlCEvmaWIoQw4t7kSf lfE/uRHK9EOfThbesmipws3ek3Q9LOtdh+zquCpGcAGTo4GmYeNyq4jGlmJJlanBNbVk 9tZg== X-Forwarded-Encrypted: i=1; AJvYcCU9408XmkUjNQDR6O4Jdu6DCAVuivO5lk/F8oqJyKpnOQeNg/AGy3c03PcC6isiOq4MFmJO9ijPjiKs@nongnu.org X-Gm-Message-State: AOJu0YwtcC6qAxZOBCWdAJcsYyJ0hTcqsKAMDdbQNscx9bTLqb32jXhR P0yjJRORYu1jwyk9Aj24KjkyMBLbp66QKqsOX9NnKfsDd+ZU9DLUZEHzGmr46Kiy6dbMEcHLSlv g X-Received: by 2002:a05:600c:34d4:b0:431:5533:8f0b with SMTP id 5b1f17b1804b1-43184246647mr93646725e9.32.1729865582530; Fri, 25 Oct 2024 07:13:02 -0700 (PDT) Received: from orth.archaic.org.uk (orth.archaic.org.uk. [2001:8b0:1d0::2]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-4318b57b051sm50104535e9.42.2024.10.25.07.13.01 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 25 Oct 2024 07:13:02 -0700 (PDT) From: Peter Maydell To: qemu-arm@nongnu.org, qemu-devel@nongnu.org Cc: =?utf-8?q?Alex_Benn=C3=A9e?= , Richard Henderson , =?utf-8?q?Philippe_Mathie?= =?utf-8?q?u-Daud=C3=A9?= , Song Gao , Eduardo Habkost , "Edgar E. Iglesias" , Jiaxun Yang , Aleksandar Rikalo , Stafford Horne , Nicholas Piggin , Daniel Henrique Barboza , Yoshinori Sato , David Hildenbrand , Ilya Leoshkevich , Thomas Huth , Mark Cave-Ayland , Artyom Tarasenko , Max Filippov , qemu-ppc@nongnu.org, qemu-s390x@nongnu.org Subject: [PATCH 07/21] target/s390x: Explicitly set 2-NaN propagation rule Date: Fri, 25 Oct 2024 15:12:40 +0100 Message-Id: <20241025141254.2141506-8-peter.maydell@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20241025141254.2141506-1-peter.maydell@linaro.org> References: <20241025141254.2141506-1-peter.maydell@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::336; envelope-from=peter.maydell@linaro.org; helo=mail-wm1-x336.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: 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 Set the 2-NaN propagation rule explicitly in env->fpu_status. Signed-off-by: Peter Maydell Reviewed-by: Ilya Leoshkevich Reviewed-by: Philippe Mathieu-Daudé Reviewed-by: Richard Henderson --- target/s390x/cpu.c | 1 + fpu/softfloat-specialize.c.inc | 5 ++--- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/target/s390x/cpu.c b/target/s390x/cpu.c index 4e41a3dff59..514c70f3010 100644 --- a/target/s390x/cpu.c +++ b/target/s390x/cpu.c @@ -205,6 +205,7 @@ static void s390_cpu_reset_hold(Object *obj, ResetType type) /* tininess for underflow is detected before rounding */ set_float_detect_tininess(float_tininess_before_rounding, &env->fpu_status); + set_float_2nan_prop_rule(float_2nan_prop_s_ab, &env->fpu_status); /* fall through */ case RESET_TYPE_S390_CPU_NORMAL: env->psw.mask &= ~PSW_MASK_RI; diff --git a/fpu/softfloat-specialize.c.inc b/fpu/softfloat-specialize.c.inc index 4e51cf8d083..a0c740e544d 100644 --- a/fpu/softfloat-specialize.c.inc +++ b/fpu/softfloat-specialize.c.inc @@ -403,10 +403,9 @@ static int pickNaN(FloatClass a_cls, FloatClass b_cls, #if defined(TARGET_AVR) || defined(TARGET_HEXAGON) \ || defined(TARGET_RISCV) || defined(TARGET_SH4) \ || defined(TARGET_TRICORE) || defined(TARGET_ARM) || defined(TARGET_MIPS) \ - || defined(TARGET_LOONGARCH64) || defined(TARGET_HPPA) + || defined(TARGET_LOONGARCH64) || defined(TARGET_HPPA) \ + || defined(TARGET_S390X) g_assert_not_reached(); -#elif defined(TARGET_S390X) - rule = float_2nan_prop_s_ab; #elif defined(TARGET_PPC) || defined(TARGET_M68K) /* * PowerPC propagation rules: