summaryrefslogtreecommitdiff
path: root/test/CodeGen/x86-64-inline-asm.c
diff options
context:
space:
mode:
authorJoey Gouly <joey.gouly@gmail.com>2014-06-05 21:23:42 +0000
committerJoey Gouly <joey.gouly@gmail.com>2014-06-05 21:23:42 +0000
commit9266985b619ddd85632a0616af41f0e917646c24 (patch)
treec15b22ab3bce40bd3116c8574eecb858ca23966f /test/CodeGen/x86-64-inline-asm.c
parentf6a54b977d50f16291be44ec26715f1e6a2d543d (diff)
downloadclang-9266985b619ddd85632a0616af41f0e917646c24.tar.gz
When an inline-asm diagnostic is reported by the backend, report it with the
correct severity. Previously all inline-asm diagnostics were reported as errors. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@210286 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/CodeGen/x86-64-inline-asm.c')
-rw-r--r--test/CodeGen/x86-64-inline-asm.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/test/CodeGen/x86-64-inline-asm.c b/test/CodeGen/x86-64-inline-asm.c
new file mode 100644
index 0000000000..666d4c0822
--- /dev/null
+++ b/test/CodeGen/x86-64-inline-asm.c
@@ -0,0 +1,7 @@
+// REQUIRES: x86-registered-target
+// RUN: %clang_cc1 -triple x86_64 %s -S -o /dev/null 2>&1 | FileCheck %s
+// RUN: not %clang_cc1 -triple x86_64 %s -S -o /dev/null -Werror 2>&1 | FileCheck %s --check-prefix=CHECK-Werror
+void f() {
+ asm("movaps %xmm3, (%esi, 2)"); // CHECK: warning: scale factor without index register is ignored
+ // CHECK-Werror: error: scale factor without index register is ignored
+}