From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wm1-x32f.google.com (mail-wm1-x32f.google.com [IPv6:2a00:1450:4864:20::32f]) by sourceware.org (Postfix) with ESMTPS id 3CE3A387090F for ; Fri, 12 Mar 2021 09:38:03 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org 3CE3A387090F Received: by mail-wm1-x32f.google.com with SMTP id o26so3380801wmc.5 for ; Fri, 12 Mar 2021 01:38:03 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=SwXG6q0SwtHW72kQq7HuoCG6fNNt3J2u3mMM3KMCt4I=; b=hHTPdzr8Vq5sbmb+JIkxnuYSv3E8ljHPnGgw4l/3dNgllaQAQSuc45hWYnzW50EEgc F8Habv6d38oXNC21g+HPXfRIH/QkxMNfy5gZxNYlEfW1Sr2CT8WXFg3oKiRojrww7x4h G95ytAKimue7nEb0KDWaYlUxnktEotib1TM8G1H23gr6rNVnnm2Wh/kQVI07waNP6ble J62jOrLin4cMrOtK2XVEQUKPAcdyBUhS9PdTjVl+ysmY+eIoyMY5kXfV/4G70otAkXIB KSxsd77boL34uVH06x8VOndIjPOuM7hgLB4rsdJFi1CkJiUOhqTCuUUei1LRc3ZqV1XU g4GA== X-Gm-Message-State: AOAM532exwlK11uBqmOIkI8mrP7t1DHqBvNOHBphTHOJ/sdWz5zZJ+Yf aMmWCb8RFM1qFBnjoUu7dNBsy0bpFPDEhD1U5uc= X-Google-Smtp-Source: ABdhPJyQdf938S9ALKFoDmB+F0+0ad24ZBO5iyJpgt6ygjYtF04pkT+q37R0JtnAgwQHdGXTw9xYfD3Q07mY7SpI8ZA= X-Received: by 2002:a1c:bdc2:: with SMTP id n185mr12371178wmf.128.1615541881400; Fri, 12 Mar 2021 01:38:01 -0800 (PST) MIME-Version: 1.0 References: In-Reply-To: From: Kito Cheng Date: Fri, 12 Mar 2021 17:37:50 +0800 Message-ID: Subject: Re: [RFC] Appropriate portable data type for IEEE half-precision on C/C++ To: Jonathan Wakely Cc: GCC Content-Type: text/plain; charset="UTF-8" X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, FREEMAIL_FROM, KAM_SHORT, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on server2.sourceware.org X-BeenThere: gcc@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 12 Mar 2021 09:38:08 -0000 Hi Jonathan: > > C++ also has another proposal for extended floating-point types > > (https://wg21.link/p1467), which included half-precision types, so in > > my understanding, _Float16 won't be a portable typen between C/C++. > > Why not just make _Float16 available in C++ as a GCC extension? Not sure it would introduce any ABI issue or not? Especially the function name mangling for _Decimal* types, or maybe we could just implement the interchanged floating point type (_FloatN) part to C++ is fine? I am happy to implement that if it's an acceptable way to go, and I guess it could be used when GCC implements P1467 in future.