Page MenuHomeFreeBSD

riscv: Add a soft-float implementation of fabs()
ClosedPublic

Authored by arichardson on Mar 1 2021, 11:30 AM.
Tags
None
Referenced Files
Unknown Object (File)
Wed, Jun 18, 3:19 PM
Unknown Object (File)
Wed, Jun 18, 5:04 AM
Unknown Object (File)
Sat, Jun 14, 11:13 PM
Unknown Object (File)
May 23 2025, 2:05 AM
Unknown Object (File)
May 15 2025, 9:11 PM
Unknown Object (File)
Apr 16 2025, 9:41 PM
Unknown Object (File)
Mar 12 2025, 6:34 PM
Unknown Object (File)
Feb 23 2025, 7:05 PM
Subscribers

Details

Summary

We could just use a C implementation using __builtin_fabs(), but using
this assembly version guarantees that there is no additional prolog/epilog
code. Additionally, clang generates worse code for masking off the top bit
than GCC: https://bugs.llvm.org/show_bug.cgi?id=49377.

Test Plan

Should fix RISCV64 softfloat world build

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 37471
Build 34360: arc lint + arc unit