[cfe-commits] r166725 - /cfe/trunk/test/CodeGen/ms-inline-asm.c

Chad Rosier mcrosier at apple.com
Thu Oct 25 14:52:04 PDT 2012


Author: mcrosier
Date: Thu Oct 25 16:52:03 2012
New Revision: 166725

URL: http://llvm.org/viewvc/llvm-project?rev=166725&view=rev
Log:
[ms-inline asm] Add a test case for r166723 and r166724.

Modified:
    cfe/trunk/test/CodeGen/ms-inline-asm.c

Modified: cfe/trunk/test/CodeGen/ms-inline-asm.c
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/test/CodeGen/ms-inline-asm.c?rev=166725&r1=166724&r2=166725&view=diff
==============================================================================
--- cfe/trunk/test/CodeGen/ms-inline-asm.c (original)
+++ cfe/trunk/test/CodeGen/ms-inline-asm.c Thu Oct 25 16:52:03 2012
@@ -179,3 +179,17 @@
 // CHECK: t18
 // CHECK: call void asm sideeffect inteldialect "lea ebx, foo\0A\09mov eax, [ebx].0\0A\09mov [ebx].4, ecx", "~{eax},~{dirflag},~{fpsr},~{flags}"() nounwind
 }
+
+int t19() {
+  struct t18_type foo;
+  foo.a = 1;
+  foo.b = 2;
+  __asm {
+     lea ebx, foo
+     mov eax, [ebx].foo.a
+     mov [ebx].foo.b, ecx
+  }
+  return foo.b;
+// CHECK: t19
+// CHECK: call void asm sideeffect inteldialect "lea ebx, foo\0A\09mov eax, [ebx].0\0A\09mov [ebx].4, ecx", "~{eax},~{dirflag},~{fpsr},~{flags}"() nounwind
+}





More information about the cfe-commits mailing list