From patchwork Wed Sep 29 17:39:18 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Joseph Myers X-Patchwork-Id: 45579 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 678E73857C5B for ; Wed, 29 Sep 2021 17:39:37 +0000 (GMT) X-Original-To: libc-alpha@sourceware.org Delivered-To: libc-alpha@sourceware.org Received: from esa3.mentor.iphmx.com (esa3.mentor.iphmx.com [68.232.137.180]) by sourceware.org (Postfix) with ESMTPS id 4BD003858C60 for ; Wed, 29 Sep 2021 17:39:25 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 4BD003858C60 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=codesourcery.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=mentor.com IronPort-SDR: +JNA4DrwqzYnKK3JVLGEfm2hryUAxYSD0ull5yaICg58qP3ET+L8q1ZQngAyCA4LNcHxbVo3EI 8janYfYKzwLFroRDvDj5ymZ2DGgiw/3l0jT64n+tjcXktytMitfUHH+AegiWKxvC7L+DcrYSm3 nLQ7spZ7Ne3Qnl0AYlQBeNe5mZW6VZk5loE8nw25re8BU0HvO5rHOzvZC71rkxv8SoQSI4zps4 T7NXle1ZiPU/p4Tw+jgwbGlppKKVzG81uRITe47wxx2KFcese9NVtr+0BrG5oZrXieqK8+PtAP 9Q2iPCwjePTAjC7L8+HKcLqa X-IronPort-AV: E=Sophos;i="5.85,332,1624348800"; d="scan'208";a="66461605" Received: from orw-gwy-01-in.mentorg.com ([192.94.38.165]) by esa3.mentor.iphmx.com with ESMTP; 29 Sep 2021 09:39:24 -0800 IronPort-SDR: gOsNAoa3Jjewd6WEk4WiW3sFkh8Bir8+d3tbEg1FzU4ROWGO6Zd6kLkjBlgcVwKpHq9T7U9XTt tDORckqQtH7mdrjLEC1jPHc2Sisz0TaRcrWVmanx2opXkxK7Co2hTVaS305kbv2QCNl1QypOSp OGHvzgkbUvdSPn74i6ZoFWKJPuya6P2cmzRW4H6rXuAcggPHjquGCQuxevmiUAqouik6VtN8Vi MUliMA5pr+VUwKmIL0zvsDupG66uVlhdD9BEPTSEuxQnK2nIDTQeeGt0INXYzjKyUtRgh5adDU pH0= Date: Wed, 29 Sep 2021 17:39:18 +0000 From: Joseph Myers X-X-Sender: jsm28@digraph.polyomino.org.uk To: Subject: Do not define tgmath.h fmaxmag, fminmag macros for C2X (bug 28397) [committed] Message-ID: User-Agent: Alpine 2.22 (DEB 394 2020-01-19) MIME-Version: 1.0 X-Originating-IP: [137.202.0.90] X-ClientProxiedBy: svr-ies-mbx-02.mgc.mentorg.com (139.181.222.2) To svr-ies-mbx-01.mgc.mentorg.com (139.181.222.1) X-Spam-Status: No, score=-3124.0 required=5.0 tests=BAYES_00, GIT_PATCH_0, HEADER_FROM_DIFFERENT_DOMAINS, KAM_DMARC_STATUS, SPF_HELO_PASS, 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: , Errors-To: libc-alpha-bounces+patchwork=sourceware.org@sourceware.org Sender: "Libc-alpha" C2X does not include fmaxmag and fminmag. When I updated feature test macro handling accordingly (commit 858045ad1c5ac1682288bbcb3676632b97a21ddf, "Update floating-point feature test macro handling for C2X", included in 2.34), I missed updating tgmath.h so it doesn't define the corresponding type-generic macros unless __STDC_WANT_IEC_60559_BFP_EXT__ is defined; I've now reported this as bug 28397. Adjust the conditionals in tgmath.h accordingly. Tested for x86_64. --- Committed. diff --git a/math/tgmath.h b/math/tgmath.h index 9868353c46..3d7b0998df 100644 --- a/math/tgmath.h +++ b/math/tgmath.h @@ -921,7 +921,9 @@ /* Like ilogb, but returning long int. */ # define llogb(Val) __TGMATH_UNARY_REAL_RET_ONLY (Val, llogb) +#endif +#if __GLIBC_USE (IEC_60559_BFP_EXT) /* Return value with maximum magnitude. */ # define fmaxmag(Val1, Val2) __TGMATH_BINARY_REAL_ONLY (Val1, Val2, fmaxmag)