Commit Graph

18 Commits

Author SHA1 Message Date
Trevor Gross
fbd6907358 Add integer to f128 conversions 2024-10-30 12:25:24 -05:00
Trevor Gross
51dd4da053 Refactor integer to float conversion
Extract some common routines to separate functions in order to
deduplicate code and remove some of the magic.
2024-10-30 12:25:22 -05:00
Trevor Gross
1dc50415cd Add an apfloat fallback for int to float tests 2024-10-30 12:22:57 -05:00
Sbstn Bcht
69406c118a
Remove unsupported *vfp functions (#678)
Remove all *vfp functions and related tests since LLVM no longer emits them.

Link: https://github.com/rust-lang/compiler-builtins/pull/626

[ Reword commit message - Trevor ]
2024-09-03 22:55:44 -04:00
Kleis Auke Wolthuizen
13cc7daf05 Fix CI for targets that conditionally disable f16 or f128 support 2024-08-12 14:56:59 +02:00
Trevor Gross
e0e6243b21 Update float conversion tests
Since there are more platforms that do not have symbols present, we need
to use `rustc_apfloat` for more conversion tests. Make use of the
fallback like other tests, and refactor so each test gets its own
function.

Previously we were testing both apfloat and system conversion methods
when possible. This changes to only test one or the other, depending on
whether or not the system version is available. This seems reasonable
because it is consistent with all other tests, but we should consider
updating all tests to check both at some point.

This also includes an adjustment of PowerPC configuration to account for
the linking errors at [1].

[1]: https://github.com/rust-lang/compiler-builtins/issues/655
2024-08-03 02:07:06 -04:00
Trevor Gross
c7bd2a5655 Add ppc_alias to the intrinsics! macro
PowerPC platforms use `kf` rather than `tf` for `f128`. Add a way to
alias this in the macro to make the code cleaner.

This also fixes the names of `fixunstf*` and `fixtf*` on Power PC
(`fixunskf*` and `fixkf*` are correct).
2024-05-21 03:55:37 -04:00
Trevor Gross
ccd179b231 Add f128 float to integer conversion functions
Add the following:

- `__fixtfsi`
- `__fixtfdi`
- `__fixtfti`
- `__fixunstfsi`
- `__fixunstfdi`
- `__fixunstfti`
2024-05-20 20:01:33 -04:00
Trevor Gross
aaaf62bd6b Add an apfloat fallback for float to integer tests 2024-05-20 20:01:19 -04:00
Trevor Gross
f82e1f14fc Rework the test crate to separate individual tests
Currently, tests of the same kind are grouped together across all types
into a single function. This makes it difficult to understand exactly
what failed in CI.

Change test macros to create separate functions for separate types so
failures are more fine grained.
2024-05-18 04:37:55 -04:00
Trevor Gross
a82491ed54 Correct f128 extend and truncate symbol names on powerpc
PowerPC uses `kf` instead of `tf`:
<https://gcc.gnu.org/wiki/Ieee128PowerPC>
2024-05-15 07:19:17 -05:00
Trevor Gross
54d96150b5 Update cfg to fix warnings 2024-05-11 09:56:55 +02:00
beetrees
229babb1d0 Add builtins for f16/f128 float conversions 2024-05-02 13:49:24 +02:00
Amanieu d'Antras
7db8c0581d Disable another test on powerpc 2023-03-29 21:49:08 +01:00
Amanieu d'Antras
a71b0e4493 Disable broken powerpc64 test due to https://github.com/rust-lang/rust/issues/88520 2021-10-15 02:11:12 +02:00
Amanieu d'Antras
189b987a25 Revert "Disable AArch64 FP-to-int tests"
This reverts commit 9e76b9115fa9571501d378b6329ce557266908b7.
2021-04-23 18:54:12 +01:00
Amanieu d'Antras
880ec8bb83 Disable AArch64 FP-to-int tests
This is a temporary workaround for https://github.com/rust-lang/rust/issues/83467
2021-04-02 12:36:57 +01:00
Aaron Kutch
69a3c571f7 Completely overhaul fuzz testing
adds testing for almost every numerical intrinsic
2020-12-08 11:42:28 -06:00