Quoting Rémi Denis-Courmont (2024-07-26 18:32:19)
> The absolute value of a floating point value is easier to calculate than
> that of an integer: it is obtained by either clearing the sign or xoring it
> with itself. Accordingly, Arm, LoongArch, RISC-V have dedicated instructions
> to manipulate f
The absolute value of a floating point value is easier to calculate than
that of an integer: it is obtained by either clearing the sign or xoring it
with itself. Accordingly, Arm, LoongArch, RISC-V have dedicated instructions
to manipulate float sign bits. x86-64 has ANDPS.
As per C11 appendix F,