27 lines · plain
1; XFAIL: *2; UNSUPPORTED: expensive_checks3; FIXME: asserts4; RUN: llc -mcpu=pwr9 -mtriple=powerpc64le-gnu-linux -filetype=null -enable-legalize-types-checking=0 \5; RUN: -ppc-vsr-nums-as-vr -ppc-asm-full-reg-names %s6 7define { ppc_fp128, ppc_fp128 } @test_sincospi_ppcf128(ppc_fp128 %a) {8 %result = call { ppc_fp128, ppc_fp128 } @llvm.sincospi.ppcf128(ppc_fp128 %a)9 ret { ppc_fp128, ppc_fp128 } %result10}11 12; FIXME: This could be made a tail call with the default expansion of llvm.sincospi.13define void @test_sincospi_ppcf128_void_tail_call(ppc_fp128 %a, ptr noalias %out_sin, ptr noalias %out_cos) {14 %result = tail call { ppc_fp128, ppc_fp128 } @llvm.sincospi.ppcf128(ppc_fp128 %a)15 %result.0 = extractvalue { ppc_fp128, ppc_fp128 } %result, 016 %result.1 = extractvalue { ppc_fp128, ppc_fp128 } %result, 117 store ppc_fp128 %result.0, ptr %out_sin, align 1618 store ppc_fp128 %result.1, ptr %out_cos, align 1619 ret void20}21 22; NOTE: This would need a struct-return library call for llvm.sincospi to become a tail call.23define { ppc_fp128, ppc_fp128 } @test_sincospi_ppcf128_tail_call(ppc_fp128 %a) {24 %result = tail call { ppc_fp128, ppc_fp128 } @llvm.sincospi.ppcf128(ppc_fp128 %a)25 ret { ppc_fp128, ppc_fp128 } %result26}27