[PATCH] D76077: [ARM] Add __bf16 as new Bfloat16 C Type

Sjoerd Meijer via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon May 18 05:52:39 PDT 2020


SjoerdMeijer added inline comments.


================
Comment at: clang/docs/LanguageExtensions.rst:518
+Clang supports three half-precision (16-bit) floating point types: ``__fp16``,
+``_Float16`` and ``__bf16``.  These types are supported in all language modes.
 
----------------
stuij wrote:
> SjoerdMeijer wrote:
> > Not my field of expertise, and sorry if I've missed this somewhere, but was wondering if this (i.e. all language modes) means we need C++ name mangling support for bfloat? In the AArch64 backend I saw this:
> > 
> >   getBFloat16Mangling() const override { return "u6__bf16"; }
> > 
> > But that's something else I guess, and I was guessing a 2 letter mangling needs to be added here?
> > 
> > https://itanium-cxx-abi.github.io/cxx-abi/abi.html#mangling-builtin
> Yes, we need name-mangling support, and yes that method you mentioned does that. There's one for AArch32 as well. And yes we have documented it in the 'C++ ABI for the latest Arm Architecture' docs:
> 
> aarch32: https://developer.arm.com/docs/ihi0041/latest
> aarch64: https://developer.arm.com/docs/ihi0059/latest
But does that mean that for other targets this is not (yet) supported?


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D76077/new/

https://reviews.llvm.org/D76077





More information about the cfe-commits mailing list