Index: CodeGen/asm-inout.c
===================================================================
--- CodeGen/asm-inout.c	(revision 110738)
+++ CodeGen/asm-inout.c	(working copy)
@@ -17,3 +17,15 @@
   // CHECK: store i32 {{%[a-zA-Z0-9\.]+}}, i32* [[REGCALLRESULT]]
   asm ("foobar" : "+r"(*foo()));
 }
+
+// PR7338
+void test3(int *vout, int vin)
+{
+  // CHECK: call void asm "opr $0,$1", "=*r,r,~{di},~{dirflag},~{fpsr},~{flags}"
+asm(
+		"opr %[vout],%[vin]"
+		: [vout] "=r,=m,=r" (*vout)
+		: [vin] "r,m,r" (vin)
+		: "edi"
+		);
+}
