X-Git-Url: http://demsky.eecs.uci.edu/git/?a=blobdiff_plain;f=test%2FCodeGen%2FX86%2Fbyval3.ll;h=d06fd8898e7fb37d99bbb1c7b74a18038eb32348;hb=e4e742a62d5efa8f69b351dde87f9a20c03503ef;hp=b3794eccb46834a129bba2518600d0c1fdd327a7;hpb=5c0d6ed325417baa5d119af9c2b6790231d8565f;p=oota-llvm.git diff --git a/test/CodeGen/X86/byval3.ll b/test/CodeGen/X86/byval3.ll index b3794eccb46..d06fd8898e7 100644 --- a/test/CodeGen/X86/byval3.ll +++ b/test/CodeGen/X86/byval3.ll @@ -1,9 +1,36 @@ -; RUN: llvm-as < %s | llc -march=x86-64 | grep rep.movsl | count 2 -; RUN: llvm-as < %s | llc -march=x86 | grep rep.movsl | count 2 +; RUN: llc < %s -mtriple=x86_64-linux -mattr=-avx | FileCheck %s -check-prefix=X64 +; X64-NOT: movsq +; X64: rep +; X64-NOT: rep +; X64: movsq +; X64-NOT: movsq +; X64: rep +; X64-NOT: rep +; X64: movsq +; X64-NOT: rep +; X64-NOT: movsq -%struct.s = type { i32, i32, i32, i32, i32, i32 } +; Win64 has not supported byval yet. -define void @g(i32 %a1, i32 %a2, i32 %a3, i32 %a4, i32 %a5, i32 %a6) { +; RUN: llc < %s -march=x86 -mattr=-avx | FileCheck %s -check-prefix=X32 +; X32-NOT: movsl +; X32: rep +; X32-NOT: rep +; X32: movsl +; X32-NOT: movsl +; X32: rep +; X32-NOT: rep +; X32: movsl +; X32-NOT: rep +; X32-NOT: movsl + +%struct.s = type { i32, i32, i32, i32, i32, i32, i32, i32, + i32, i32, i32, i32, i32, i32, i32, i32, + i32, i32, i32, i32, i32, i32, i32, i32, + i32, i32, i32, i32, i32, i32, i32, i32, + i32 } + +define void @g(i32 %a1, i32 %a2, i32 %a3, i32 %a4, i32 %a5, i32 %a6) nounwind { entry: %d = alloca %struct.s, align 16 %tmp = getelementptr %struct.s* %d, i32 0, i32 0 @@ -18,8 +45,8 @@ entry: store i32 %a5, i32* %tmp8, align 16 %tmp10 = getelementptr %struct.s* %d, i32 0, i32 5 store i32 %a6, i32* %tmp10, align 16 - call void @f( %struct.s* %d byval) - call void @f( %struct.s* %d byval) + call void @f( %struct.s* byval %d) + call void @f( %struct.s* byval %d) ret void }