x86-32 "f16" ABI needs SSE, incompatible with i586 targets #131819
Open
Description
On 32-bit x86, the ABI specifies that f16 gets returned in xmm0, which is what Clang and GCC do (neither Clang nor GCC support _Float16 when SSE2 is disabled)
So... for the "Rust" ABI we can do our own thing bypassing this (likely similar fo f32
/f64
, we should just always return f16
in via PassMode::Indirect
), but what shall we do for the extern "C"
ABI? We'll need a new dedicated compiler error (likely as part of the pass that we are adding here) that rejects returning f16
when the SSE registers are not available.
That will mean that libcore does not compile on i586 targets.... Actually libcore uses the "Rust" ABI so that one is fine. But if we have extern "C"
float functions somewhere those would not be portable any more.
Metadata
Assignees
Labels
Area: Concerning the application binary interface (ABI)Area: Code generation parts specific to LLVM. Both correctness bugs and optimization-related issues.Category: This is a bug.`#![feature(f16)]`, `#![feature(f128)]`Target: x86 processors, 32 bit (like i686-*)Status: the compiler-dragon is eepy, can someone get it some tea?