diff options
| author | Dimitry Andric <dim@FreeBSD.org> | 2016-08-17 19:33:52 +0000 |
|---|---|---|
| committer | Dimitry Andric <dim@FreeBSD.org> | 2016-08-17 19:33:52 +0000 |
| commit | a7fe922b98bb45be7dce7c1cfe668ec27eeddc74 (patch) | |
| tree | e9648f5bddc775b842e53141d7c9748482f7115a /test/CodeGen/AMDGPU/llvm.amdgcn.fdiv.fast.ll | |
| parent | c3aee98e721333f265a88d6bf348e6e468f027d4 (diff) | |
Vendor import of llvm release_39 branch r278877:vendor/llvm/llvm-release_39-r278877
Notes
svn path=/vendor/llvm/dist/; revision=304298
svn path=/vendor/llvm/llvm-release_39-r278877/; revision=304299; tag=vendor/llvm/llvm-release_39-r278877
Diffstat (limited to 'test/CodeGen/AMDGPU/llvm.amdgcn.fdiv.fast.ll')
| -rw-r--r-- | test/CodeGen/AMDGPU/llvm.amdgcn.fdiv.fast.ll | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/test/CodeGen/AMDGPU/llvm.amdgcn.fdiv.fast.ll b/test/CodeGen/AMDGPU/llvm.amdgcn.fdiv.fast.ll new file mode 100644 index 000000000000..54d7848da3bf --- /dev/null +++ b/test/CodeGen/AMDGPU/llvm.amdgcn.fdiv.fast.ll @@ -0,0 +1,18 @@ +; RUN: llc -march=amdgcn -verify-machineinstrs < %s | FileCheck %s + +declare float @llvm.amdgcn.fdiv.fast(float, float) #0 + +; CHECK-LABEL: {{^}}test_fdiv_fast: +; CHECK: v_cndmask_b32_e32 v{{[0-9]+}}, 1.0, v{{[0-9]+}}, vcc +; CHECK: v_mul_f32_e32 +; CHECK: v_rcp_f32_e32 +; CHECK: v_mul_f32_e32 +; CHECK: v_mul_f32_e32 +define void @test_fdiv_fast(float addrspace(1)* %out, float %a, float %b) #1 { + %fdiv = call float @llvm.amdgcn.fdiv.fast(float %a, float %b) + store float %fdiv, float addrspace(1)* %out + ret void +} + +attributes #0 = { nounwind readnone } +attributes #1 = { nounwind } |
