From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id DB0CB3858D29; Mon, 22 Mar 2021 17:38:28 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org DB0CB3858D29 From: "jakub at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug target/99708] __SIZEOF_FLOAT128__ not defined on powerpc64le-linux Date: Mon, 22 Mar 2021 17:38:28 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: target X-Bugzilla-Version: 11.0 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: jakub at gcc dot gnu.org X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Resolution: X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-BeenThere: gcc-bugs@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-bugs mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 22 Mar 2021 17:38:29 -0000 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D99708 --- Comment #2 from Jakub Jelinek --- The __SIZEOF_*__ macros are widely used to detect both if a type can be used and what sizeof (the_type) is when it needs to be checked in preprocessor conditionals, including hundreds of times in GCC testsuite. It is something supported by multiple compilers (GCC, clang, ICC at least). Having to remember magic macros which are different on each arch and in each compiler is much more complicated. The topic this came up on is libstdc++ headers which in ext/numeric_traits.h wants to provide ppc64le compatibility and right now assumes that if __LONG_DOUBLE_IEEE128__ is defined then __ibm128 type can be used and __LONG_DOUBLE_IBM128__ is defined then __ieee128 type can be used. Apparently that is not the case at least for clang which didn't have __ieee= 128 support until very recently and __float128 support needs a non-default opti= on passed to the compiler. Which was why I suggested to guard those by # elif defined __LONG_DOUBLE_IBM128__ && __SIZEOF_FLOAT128__ =3D=3D 16 or something similar, but it doesn't work for GCC.=