Files
derek.holloway 7502bf64a4
CodeQL / Analyze (actions) (push) Canceled after 0s
CodeQL / Analyze (python) (push) Canceled after 0s
pre-commit / pre-commit (push) Canceled after 0s
Multi-Arch CI / setup (push) Canceled after 0s
Publish build_manylinux_x86_64 images / publish_build_manylinux_x86_64 (push) Canceled after 0s
Setup (Multi-Arch) / setup (push) Canceled after 0s
Multi-Arch CI / Linux::${{ fromJSON(needs.setup.outputs.linux_build_config || '{}').build_variant_label || 'skip' }} (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish no_rocm_image_ubi10 image / publish_no_rocm_image_ubi10 (push) Canceled after 0s
Multi-Arch CI / Windows::${{ fromJSON(needs.setup.outputs.windows_build_config || '{}').build_variant_label || 'skip' }} (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Multi-Arch CI / Manifest Diff (push) Canceled after 0s
TheRock Manifest Diff Report / Generate Manifest Diff Report (push) Canceled after 0s
Multi-Arch CI / CI Summary (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04 (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04_ocl_rt images / publish_no_rocm_image_ubuntu24_04_ocl_rt (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_rocgdb (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04_rocgdb images / publish_no_rocm_image_ubuntu24_04_rocgdb (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_ocl_rt (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Unit Tests / Unit Tests :: ubuntu-24.04 (push) Canceled after 0s
Unit Tests / Unit Tests :: windows-2022 (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_media (push) Canceled after 0s
Unit Tests / Unit Tests Summary (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_openmpi (push) Canceled after 0s
Flatten subprojects into a single base monorepo
2026-09-02 16:34:47 -07:00

127 lines
4.6 KiB
LLVM

; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py UTC_ARGS: --version 5
; RUN: llc -mtriple=s390x-linux-gnu < %s | FileCheck -check-prefix=LINUX %s
; FIXME: Merge with llvm.sincos.ll when zos is fixed for half.
define { half, half } @test_sincos_f16(half %a) #0 {
; LINUX-LABEL: test_sincos_f16:
; LINUX: # %bb.0:
; LINUX-NEXT: stmg %r14, %r15, 112(%r15)
; LINUX-NEXT: .cfi_offset %r14, -48
; LINUX-NEXT: .cfi_offset %r15, -40
; LINUX-NEXT: aghi %r15, -176
; LINUX-NEXT: .cfi_def_cfa_offset 336
; LINUX-NEXT: std %f8, 168(%r15) # 8-byte Spill
; LINUX-NEXT: .cfi_offset %f8, -168
; LINUX-NEXT: brasl %r14, __extendhfsf2@PLT
; LINUX-NEXT: la %r2, 164(%r15)
; LINUX-NEXT: la %r3, 160(%r15)
; LINUX-NEXT: brasl %r14, sincosf@PLT
; LINUX-NEXT: le %f0, 164(%r15)
; LINUX-NEXT: brasl %r14, __truncsfhf2@PLT
; LINUX-NEXT: le %f1, 160(%r15)
; LINUX-NEXT: ler %f8, %f0
; LINUX-NEXT: ler %f0, %f1
; LINUX-NEXT: brasl %r14, __truncsfhf2@PLT
; LINUX-NEXT: ler %f2, %f0
; LINUX-NEXT: ler %f0, %f8
; LINUX-NEXT: ld %f8, 168(%r15) # 8-byte Reload
; LINUX-NEXT: lmg %r14, %r15, 288(%r15)
; LINUX-NEXT: br %r14
%result = call { half, half } @llvm.sincos.f16(half %a)
ret { half, half } %result
}
define half @test_sincos_f16_only_use_sin(half %a) #0 {
; LINUX-LABEL: test_sincos_f16_only_use_sin:
; LINUX: # %bb.0:
; LINUX-NEXT: stmg %r14, %r15, 112(%r15)
; LINUX-NEXT: .cfi_offset %r14, -48
; LINUX-NEXT: .cfi_offset %r15, -40
; LINUX-NEXT: aghi %r15, -168
; LINUX-NEXT: .cfi_def_cfa_offset 328
; LINUX-NEXT: brasl %r14, __extendhfsf2@PLT
; LINUX-NEXT: la %r2, 160(%r15)
; LINUX-NEXT: la %r3, 164(%r15)
; LINUX-NEXT: brasl %r14, sincosf@PLT
; LINUX-NEXT: le %f0, 160(%r15)
; LINUX-NEXT: brasl %r14, __truncsfhf2@PLT
; LINUX-NEXT: lmg %r14, %r15, 280(%r15)
; LINUX-NEXT: br %r14
%result = call { half, half } @llvm.sincos.f16(half %a)
%result.0 = extractvalue { half, half } %result, 0
ret half %result.0
}
define half @test_sincos_f16_only_use_cos(half %a) #0 {
; LINUX-LABEL: test_sincos_f16_only_use_cos:
; LINUX: # %bb.0:
; LINUX-NEXT: stmg %r14, %r15, 112(%r15)
; LINUX-NEXT: .cfi_offset %r14, -48
; LINUX-NEXT: .cfi_offset %r15, -40
; LINUX-NEXT: aghi %r15, -168
; LINUX-NEXT: .cfi_def_cfa_offset 328
; LINUX-NEXT: brasl %r14, __extendhfsf2@PLT
; LINUX-NEXT: la %r2, 164(%r15)
; LINUX-NEXT: la %r3, 160(%r15)
; LINUX-NEXT: brasl %r14, sincosf@PLT
; LINUX-NEXT: le %f0, 160(%r15)
; LINUX-NEXT: brasl %r14, __truncsfhf2@PLT
; LINUX-NEXT: lmg %r14, %r15, 280(%r15)
; LINUX-NEXT: br %r14
%result = call { half, half } @llvm.sincos.f16(half %a)
%result.1 = extractvalue { half, half } %result, 1
ret half %result.1
}
define { <2 x half>, <2 x half> } @test_sincos_v2f16(<2 x half> %a) #0 {
; LINUX-LABEL: test_sincos_v2f16:
; LINUX: # %bb.0:
; LINUX-NEXT: stmg %r14, %r15, 112(%r15)
; LINUX-NEXT: .cfi_offset %r14, -48
; LINUX-NEXT: .cfi_offset %r15, -40
; LINUX-NEXT: aghi %r15, -200
; LINUX-NEXT: .cfi_def_cfa_offset 360
; LINUX-NEXT: std %f8, 192(%r15) # 8-byte Spill
; LINUX-NEXT: std %f9, 184(%r15) # 8-byte Spill
; LINUX-NEXT: std %f10, 176(%r15) # 8-byte Spill
; LINUX-NEXT: .cfi_offset %f8, -168
; LINUX-NEXT: .cfi_offset %f9, -176
; LINUX-NEXT: .cfi_offset %f10, -184
; LINUX-NEXT: ler %f8, %f2
; LINUX-NEXT: brasl %r14, __extendhfsf2@PLT
; LINUX-NEXT: la %r2, 172(%r15)
; LINUX-NEXT: la %r3, 168(%r15)
; LINUX-NEXT: brasl %r14, sincosf@PLT
; LINUX-NEXT: ler %f0, %f8
; LINUX-NEXT: brasl %r14, __extendhfsf2@PLT
; LINUX-NEXT: la %r2, 164(%r15)
; LINUX-NEXT: la %r3, 160(%r15)
; LINUX-NEXT: brasl %r14, sincosf@PLT
; LINUX-NEXT: le %f0, 172(%r15)
; LINUX-NEXT: brasl %r14, __truncsfhf2@PLT
; LINUX-NEXT: le %f1, 164(%r15)
; LINUX-NEXT: ler %f8, %f0
; LINUX-NEXT: ler %f0, %f1
; LINUX-NEXT: brasl %r14, __truncsfhf2@PLT
; LINUX-NEXT: le %f1, 168(%r15)
; LINUX-NEXT: ler %f9, %f0
; LINUX-NEXT: ler %f0, %f1
; LINUX-NEXT: brasl %r14, __truncsfhf2@PLT
; LINUX-NEXT: le %f1, 160(%r15)
; LINUX-NEXT: ler %f10, %f0
; LINUX-NEXT: ler %f0, %f1
; LINUX-NEXT: brasl %r14, __truncsfhf2@PLT
; LINUX-NEXT: ler %f6, %f0
; LINUX-NEXT: ler %f0, %f8
; LINUX-NEXT: ler %f2, %f9
; LINUX-NEXT: ler %f4, %f10
; LINUX-NEXT: ld %f8, 192(%r15) # 8-byte Reload
; LINUX-NEXT: ld %f9, 184(%r15) # 8-byte Reload
; LINUX-NEXT: ld %f10, 176(%r15) # 8-byte Reload
; LINUX-NEXT: lmg %r14, %r15, 312(%r15)
; LINUX-NEXT: br %r14
%result = call { <2 x half>, <2 x half> } @llvm.sincos.v2f16(<2 x half> %a)
ret { <2 x half>, <2 x half> } %result
}