[cfe-dev] [RFC] implementation of _Float16

Hubert Tong via cfe-dev cfe-dev at lists.llvm.org
Wed May 10 14:22:51 PDT 2017


On Wed, May 10, 2017 at 9:13 AM, Martin J. O'Riordan via cfe-dev <
cfe-dev at lists.llvm.org> wrote:

> More controversially we also added a “synonym” for this using ‘short
> float’ rather than ‘_Float16’ (or OpenCL’s ‘half’), and created a parallel
> set of the ISO C library functions using ‘s’ to suffix the usual names
> (e.g. ‘tan’, ‘tanf’, ‘tanl’ plus ‘tans’).
>
Perhaps a bit of a tangent here with regards to language semantics. I am
going to guess that, in general, short float is not necessarily the same
format as _Float16. So it follows that if both are present, then _Float16
and short float are types which are not compatible (e.g., for _Generic)
with each other. This would be consistent with _Float32 and "plain" float.

-- HT
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20170510/c7ce333d/attachment.html>


More information about the cfe-dev mailing list