https://gcc.gnu.org/bugzilla/show_bug.cgi?id=101953

--- Comment #12 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
For aarch64 we do:
        fcvtzs  w0, d0 ; int
        fcvtzu  w0, d0 ; uint32_t
For ARM:
        vcvt.s32.f64    s15, d16 ; int
        vcvt.u32.f64    s15, d7 ; uint32_t



For x86 we do:
        cvttsd2sil      %xmm0, %eax ; int
        cvttsd2siq      %xmm0, %rax ;unsigned int 32

So in the case of x86, we convert it to long long and then truncate while on
aarch64/arm, it is a direct conversion.  This is because on x86 there is no
instruction which does unsigned; only signed.

Reply via email to