summaryrefslogtreecommitdiffstats
path: root/clang/test/CodeGen/fast-math.c
diff options
context:
space:
mode:
Diffstat (limited to 'clang/test/CodeGen/fast-math.c')
-rw-r--r--clang/test/CodeGen/fast-math.c13
1 files changed, 13 insertions, 0 deletions
diff --git a/clang/test/CodeGen/fast-math.c b/clang/test/CodeGen/fast-math.c
new file mode 100644
index 00000000000..9f9a39269ed
--- /dev/null
+++ b/clang/test/CodeGen/fast-math.c
@@ -0,0 +1,13 @@
+// RUN: %clang_cc1 -ffast-math -emit-llvm -o - %s | FileCheck %s
+typedef unsigned cond_t;
+
+volatile float f0, f1, f2;
+
+void foo(void) {
+ // CHECK: define void @foo()
+
+ // CHECK: fadd fast
+ f0 = f1 + f2;
+
+ // CHECK: ret
+}
OpenPOWER on IntegriCloud