[llvm-dev] [PATCH] Add optional _Float16 support

Joseph Myers via llvm-dev llvm-dev at lists.llvm.org
Tue Jul 13 08:41:08 PDT 2021


On Tue, 13 Jul 2021, H.J. Lu wrote:

> On Mon, Jul 12, 2021 at 8:59 PM Wang, Pengfei <pengfei.wang at intel.com> wrote:
> >
> > > Return _Float16 and _Complex _Float16 values in %xmm0/%xmm1 registers.
> >
> > Can you please explain the behavior here? Is there difference between _Float16 and _Complex _Float16 when return? I.e.,
> > 1, In which case will _Float16 values return in both %xmm0 and %xmm1?
> > 2, For a single _Float16 value, are both real part and imaginary part returned in %xmm0? Or returned in %xmm0 and %xmm1 respectively?
> 
> Here is the v2 patch to add the missing _Float16 bits.   The PDF file is at
> 
> https://gitlab.com/x86-psABIs/i386-ABI/-/wikis/Intel386-psABI

This PDF shows _Complex _Float16 as having a size of 2 bytes (should be 
4-byte size, 2-byte alignment).

It also seems to change double from 4-byte to 8-byte alignment, which is 
wrong.  And it's inconsistent about whether it covers the long double = 
double (Android) case - it shows that case for _Complex long double but 
not for long double itself.

-- 
Joseph S. Myers
joseph at codesourcery.com


More information about the llvm-dev mailing list