From patchwork Mon Dec 20 23:18:16 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "H.J. Lu" X-Patchwork-Id: 49128 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 1F0543858415 for ; Mon, 20 Dec 2021 23:18:44 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 1F0543858415 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1640042324; bh=G43zjYyd1s54jieV6e4+W9OkQxlFBsfD0roVy/gIQ60=; h=To:Subject:Date:List-Id:List-Unsubscribe:List-Archive:List-Post: List-Help:List-Subscribe:From:Reply-To:Cc:From; b=sQTKJE8GUjuHjh7O7cECO8p5xap2KdK8vD2STQwnMBc3Zd4NJTsNUEZQcNQoM5BNb MYJ5VZ+7bouZsck6iLYFauBbg0DWLpXLri9Nm5zBvdT6UWycg32TapwazRlV0ezPyB HstmwG+rAO3eFiEh0qiabaxxn59prZFT5bE8aGyw= X-Original-To: libc-alpha@sourceware.org Delivered-To: libc-alpha@sourceware.org Received: from mail-pj1-x1036.google.com (mail-pj1-x1036.google.com [IPv6:2607:f8b0:4864:20::1036]) by sourceware.org (Postfix) with ESMTPS id 5DE6F3858415 for ; Mon, 20 Dec 2021 23:18:19 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 5DE6F3858415 Received: by mail-pj1-x1036.google.com with SMTP id z9-20020a17090a7b8900b001b13558eadaso668791pjc.4 for ; Mon, 20 Dec 2021 15:18:19 -0800 (PST) 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:mime-version :content-transfer-encoding; bh=G43zjYyd1s54jieV6e4+W9OkQxlFBsfD0roVy/gIQ60=; b=1t91RpEtbiCbjX6tAHQrWIIbES7sforRasTqPGCqkPZcHym6xUr8jUZiB3VwyfzN8V yFg5i/VSog04gSYV06CaMNdnRNUP8iBrHaLpexdL5x/i5MLFINiWHd0OQnUHkPTLL/Xg d9n8Mdd83Yu+iF7h3UQpRiZdxfFy/cV9Ww/c6ZwVw7iNwpAqS098d/YHJDQeaJgHUMfu tsg3WI9YHB5qeDbQKHPn04trmumdwlAJAAQ/PCcgoR12ka8vc0xI3oc4gxA20RTnurMP SHUbcNOmNrqM8HrUR9oWY5GLnIKMftOo8Iw5oGJtXXu5/YYJn8qZTm0GN+Vx1vNJLSEH vFpg== X-Gm-Message-State: AOAM530pA6yMa7VmeHGMWM4I+VSudYItuD4fCRb3f4bnDx6uWVYTfwMl vg3eGzq7HXeMV+38E8/PzP0ywKB00bE= X-Google-Smtp-Source: ABdhPJzYF4gXHQPVAUUWfHEqR2/uTIQZ3MJPwPPmTGwjGnpJ+aRMn8sTxAaahMsYd+OrobXzlUORqw== X-Received: by 2002:a17:902:768b:b0:144:e570:c7d2 with SMTP id m11-20020a170902768b00b00144e570c7d2mr239226pll.86.1640042298445; Mon, 20 Dec 2021 15:18:18 -0800 (PST) Received: from gnu-tgl-3.localdomain ([172.58.35.133]) by smtp.gmail.com with ESMTPSA id v15sm20269940pfu.195.2021.12.20.15.18.18 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 20 Dec 2021 15:18:18 -0800 (PST) Received: from gnu-tgl-3.. (localhost [IPv6:::1]) by gnu-tgl-3.localdomain (Postfix) with ESMTP id 1CBDBC0396; Mon, 20 Dec 2021 15:18:17 -0800 (PST) To: libc-alpha@sourceware.org Subject: [PATCH 1/2] s_sincosf.h: Change pio4 type to float [BZ #28713] Date: Mon, 20 Dec 2021 15:18:16 -0800 Message-Id: <20211220231817.4051571-1-hjl.tools@gmail.com> X-Mailer: git-send-email 2.33.1 MIME-Version: 1.0 X-Spam-Status: No, score=-3029.1 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, FREEMAIL_FROM, GIT_PATCH_0, RCVD_IN_BARRACUDACENTRAL, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.4 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on server2.sourceware.org X-BeenThere: libc-alpha@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Libc-alpha mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-Patchwork-Original-From: "H.J. Lu via Libc-alpha" From: "H.J. Lu" Reply-To: "H.J. Lu" Cc: Joseph Myers Errors-To: libc-alpha-bounces+patchwork=sourceware.org@sourceware.org Sender: "Libc-alpha" s_cosf.c and s_sinf.c have if (abstop12 (y) < abstop12 (pio4)) where abstop12 takes a float argument, but pio4 is static const double. pio4 is used only in calls to abstop12 and never in arithmetic. Change it to float to fix: FAIL: math/test-float-cos FAIL: math/test-float-sin FAIL: math/test-float-sincos FAIL: math/test-float32-cos FAIL: math/test-float32-sin FAIL: math/test-float32-sincos when compiling with GCC 12. --- sysdeps/ieee754/flt-32/s_sincosf.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sysdeps/ieee754/flt-32/s_sincosf.h b/sysdeps/ieee754/flt-32/s_sincosf.h index 125ab7f846..0dadd6374e 100644 --- a/sysdeps/ieee754/flt-32/s_sincosf.h +++ b/sysdeps/ieee754/flt-32/s_sincosf.h @@ -24,7 +24,7 @@ /* 2PI * 2^-64. */ static const double pi63 = 0x1.921FB54442D18p-62; /* PI / 4. */ -static const double pio4 = 0x1.921FB54442D18p-1; +static const float pio4 = 0x1.921FB54442D18p-1; /* Polynomial data (the cosine polynomial is negated in the 2nd entry). */ extern const sincos_t __sincosf_table[2] attribute_hidden;