[clang] [compiler-rt] [llvm] [SystemZ] Add support for half (fp16) (PR #109164)
Trevor Gross via llvm-commits
llvm-commits at lists.llvm.org
Thu Apr 3 16:23:16 PDT 2025
================
@@ -126,3 +138,23 @@ define void @f9(ptr %cptr, ptr %aptr, ptr %bptr) {
store fp128 %c, ptr %cptr
ret void
}
+
+; Test f16 copies in which the sign comes from an f16.
+define half @f10(half %a, half %b) {
+; CHECK-LABEL: f10:
+; CHECK: brasl %r14, copysignh at PLT
----------------
tgross35 wrote:
This is kind of a weird test, is it meant to ensure that LLVM can recognize calls to `libm` functions and replace them with assembly lowerings if that is more optimal? If that is the goal then `copysignh` doesn't seem to be doing anything and maybe it should be a FIXME (it should be `copysignf16` anyway). If that isn't the goal then I don't know why the other tests aren't calling `@llvm.copysign.f32` and similar.
https://github.com/llvm/llvm-project/pull/109164
More information about the llvm-commits
mailing list