Add truncf16 and truncf128

Use the generic algorithms to provide implementations for these
routines.
This commit is contained in:
Trevor Gross
2025-01-12 04:12:56 +00:00
parent 6ac06a97e5
commit b558b365d3
13 changed files with 61 additions and 5 deletions

View File

@@ -9,7 +9,7 @@ const ALL_OPERATIONS_NESTED: &[(FloatTy, Signature, Option<Signature>, &[&str])]
FloatTy::F16,
Signature { args: &[Ty::F16], returns: &[Ty::F16] },
None,
&["fabsf16"],
&["fabsf16", "truncf16"],
),
(
// `fn(f32) -> f32`
@@ -40,7 +40,7 @@ const ALL_OPERATIONS_NESTED: &[(FloatTy, Signature, Option<Signature>, &[&str])]
FloatTy::F128,
Signature { args: &[Ty::F128], returns: &[Ty::F128] },
None,
&["fabsf128"],
&["fabsf128", "truncf128"],
),
(
// `(f16, f16) -> f16`