From 2015236dfcd40f0b93e7d9f6dc4c380dc88bf3c0 Mon Sep 17 00:00:00 2001 From: Tom Stellard Date: Mon, 16 Jul 2012 14:17:19 +0000 Subject: test/CodeGen/R600: Add some basic tests v6 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160273 91177308-0d34-0410-b5e6-96231b3b80d8 --- test/CodeGen/R600/fsub.ll | 15 +++++++++++++++ 1 file changed, 15 insertions(+) create mode 100644 test/CodeGen/R600/fsub.ll (limited to 'test/CodeGen/R600/fsub.ll') diff --git a/test/CodeGen/R600/fsub.ll b/test/CodeGen/R600/fsub.ll new file mode 100644 index 0000000..8e43128 --- /dev/null +++ b/test/CodeGen/R600/fsub.ll @@ -0,0 +1,15 @@ +;RUN: llc < %s -march=r600 -mcpu=redwood | diff %s.check - + + +define void @test() { + %r0 = call float @llvm.R600.load.input(i32 0) + %r1 = call float @llvm.R600.load.input(i32 1) + %r2 = fsub float %r0, %r1 + call void @llvm.AMDGPU.store.output(float %r2, i32 0) + ret void +} + +declare float @llvm.R600.load.input(i32) readnone + +declare void @llvm.AMDGPU.store.output(float, i32) + -- cgit v1.1