[ms-inline asm] Add a helpful assert.
llvm-svn: 161890
diff --git a/clang/test/CodeGen/ms-inline-asm.c b/clang/test/CodeGen/ms-inline-asm.c
index 8c3e5f7..18a2e8a 100644
--- a/clang/test/CodeGen/ms-inline-asm.c
+++ b/clang/test/CodeGen/ms-inline-asm.c
@@ -9,7 +9,9 @@
void t2() {
// CHECK: @t2
-// CHECK: call void asm sideeffect "nop\0Anop\0Anop", "~{dirflag},~{fpsr},~{flags}"() nounwind ia_nsdialect
+// CHECK: call void asm sideeffect "nop", "~{dirflag},~{fpsr},~{flags}"() nounwind ia_nsdialect
+// CHECK: call void asm sideeffect "nop", "~{dirflag},~{fpsr},~{flags}"() nounwind ia_nsdialect
+// CHECK: call void asm sideeffect "nop", "~{dirflag},~{fpsr},~{flags}"() nounwind ia_nsdialect
// CHECK: ret void
__asm nop
__asm nop
@@ -18,14 +20,17 @@
void t3() {
// CHECK: @t3
-// CHECK: call void asm sideeffect "nop\0Anop\0Anop", "~{dirflag},~{fpsr},~{flags}"() nounwind ia_nsdialect
+// CHECK: call void asm sideeffect "nop", "~{dirflag},~{fpsr},~{flags}"() nounwind ia_nsdialect
+// CHECK: call void asm sideeffect "nop", "~{dirflag},~{fpsr},~{flags}"() nounwind ia_nsdialect
+// CHECK: call void asm sideeffect "nop", "~{dirflag},~{fpsr},~{flags}"() nounwind ia_nsdialect
// CHECK: ret void
__asm nop __asm nop __asm nop
}
void t4(void) {
// CHECK: @t4
-// CHECK: call void asm sideeffect "mov ebx, eax\0Amov ecx, ebx", "~{dirflag},~{fpsr},~{flags}"() nounwind ia_nsdialect
+// CHECK: call void asm sideeffect "mov ebx, eax", "~{dirflag},~{fpsr},~{flags}"() nounwind ia_nsdialect
+// CHECK: call void asm sideeffect "mov ecx, ebx", "~{dirflag},~{fpsr},~{flags}"() nounwind ia_nsdialect
// CHECK: ret void
__asm mov ebx, eax
__asm mov ecx, ebx
@@ -33,8 +38,8 @@
void t5(void) {
// CHECK: @t5
-// CHECK: call void asm sideeffect "mov ebx, eax\0Amov ecx, ebx", "~{dirflag},~{fpsr},~{flags}"() nounwind ia_nsdialect
+// CHECK: call void asm sideeffect "mov ebx, eax", "~{dirflag},~{fpsr},~{flags}"() nounwind ia_nsdialect
+// CHECK: call void asm sideeffect "mov ecx, ebx", "~{dirflag},~{fpsr},~{flags}"() nounwind ia_nsdialect
// CHECK: ret void
__asm mov ebx, eax __asm mov ecx, ebx
}
-
diff --git a/clang/test/Parser/ms-inline-asm.c b/clang/test/Parser/ms-inline-asm.c
index 2d18195..6820f3e 100644
--- a/clang/test/Parser/ms-inline-asm.c
+++ b/clang/test/Parser/ms-inline-asm.c
@@ -11,13 +11,13 @@
__asm { // expected-warning {{MS-style inline assembly is not supported}}
int 0x2c ; } asm comments are fun! }{
}
- __asm {} // no warning as this gets merged with the previous inline asm
+ __asm {} // expected-warning {{MS-style inline assembly is not supported}}
}
int t6() {
__asm int 3 ; } comments for single-line asm // expected-warning {{MS-style inline assembly is not supported}}
- __asm {} // no warning as this gets merged with the previous inline asm
+ __asm {} // expected-warning {{MS-style inline assembly is not supported}}
- __asm int 4 // no warning as this gets merged with the previous inline asm
+ __asm int 4 // expected-warning {{MS-style inline assembly is not supported}}
return 10;
}
int t7() {
@@ -28,10 +28,10 @@
}
}
void t8() {
- __asm nop __asm nop __asm nop // expected-warning {{MS-style inline assembly is not supported}}
+ __asm nop __asm nop __asm nop // expected-warning {{MS-style inline assembly is not supported}} expected-warning {{MS-style inline assembly is not supported}} expected-warning {{MS-style inline assembly is not supported}}
}
void t9() {
- __asm nop __asm nop ; __asm nop // expected-warning {{MS-style inline assembly is not supported}}
+ __asm nop __asm nop ; __asm nop // expected-warning {{MS-style inline assembly is not supported}} expected-warning {{MS-style inline assembly is not supported}}
}
int t_fail() { // expected-note {{to match this}}
__asm