aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChad Rosier <mcrosier@apple.com>2013-03-18 23:32:33 +0000
committerChad Rosier <mcrosier@apple.com>2013-03-18 23:32:33 +0000
commit2317dc8842e7b5ad0dc56723ff45ab2cf73abb35 (patch)
tree8d6778b7822200e7d210912ab87acd9db8684081
parentabc0bea57d4e659d5cde178a4bb426acc48f999e (diff)
Test case for r177347.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@177349 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r--test/CodeGen/ms-inline-asm.c13
1 files changed, 13 insertions, 0 deletions
diff --git a/test/CodeGen/ms-inline-asm.c b/test/CodeGen/ms-inline-asm.c
index 7f130d697b..b17e71751f 100644
--- a/test/CodeGen/ms-inline-asm.c
+++ b/test/CodeGen/ms-inline-asm.c
@@ -357,4 +357,17 @@ void t31() {
// CHECK: call void asm sideeffect inteldialect "popad", "~{dirflag},~{fpsr},~{flags}"() [[NUW]]
}
+void t32() {
+ int i;
+ __asm mov eax, i
+ __asm mov eax, dword ptr i
+ __asm mov ax, word ptr i
+ __asm mov al, byte ptr i
+// CHECK: t32
+// CHECK: call void asm sideeffect inteldialect "mov eax, dword ptr $0", "*m,~{eax},~{dirflag},~{fpsr},~{flags}"(i32* %{{.*}}) [[NUW]]
+// CHECK: call void asm sideeffect inteldialect "mov eax, dword ptr $0", "*m,~{eax},~{dirflag},~{fpsr},~{flags}"(i32* %{{.*}}) [[NUW]]
+// CHECK: call void asm sideeffect inteldialect "mov ax, word ptr $0", "*m,~{ax},~{dirflag},~{fpsr},~{flags}"(i32* %{{.*}}) [[NUW]]
+// CHECK: call void asm sideeffect inteldialect "mov al, byte ptr $0", "*m,~{al},~{dirflag},~{fpsr},~{flags}"(i32* %{{.*}}) [[NUW]]
+}
+
// CHECK: attributes [[NUW]] = { nounwind }