1 ; RUN: llc < %s -mtriple=i686-pc-win32 | FileCheck %s
3 %Foo = type { i32, i32 }
5 declare void @f(ptr inalloca(%Foo) %b)
10 %b = alloca inalloca %Foo
13 %f2 = getelementptr %Foo, ptr %b, i32 0, i32 1
16 ; CHECK: movl %esp, %eax
17 ; CHECK: movl $13, (%eax)
18 ; CHECK: movl $42, 4(%eax)
19 call void @f(ptr inalloca(%Foo) %b)
24 declare void @inreg_with_inalloca(i32 inreg %a, ptr inalloca(%Foo) %b)
29 %b = alloca inalloca %Foo
32 %f2 = getelementptr %Foo, ptr %b, i32 0, i32 1
35 ; CHECK: movl %esp, %eax
36 ; CHECK: movl $13, (%eax)
37 ; CHECK: movl $42, 4(%eax)
38 call void @inreg_with_inalloca(i32 inreg 1, ptr inalloca(%Foo) %b)
39 ; CHECK: movl $1, %eax
40 ; CHECK: calll _inreg_with_inalloca
44 declare x86_thiscallcc void @thiscall_with_inalloca(ptr %a, ptr inalloca(%Foo) %b)
49 %b = alloca inalloca %Foo
52 %f2 = getelementptr %Foo, ptr %b, i32 0, i32 1
55 ; CHECK: movl %esp, %eax
56 ; CHECK-DAG: movl $13, (%eax)
57 ; CHECK-DAG: movl $42, 4(%eax)
58 call x86_thiscallcc void @thiscall_with_inalloca(ptr null, ptr inalloca(%Foo) %b)
59 ; CHECK-DAG: xorl %ecx, %ecx
60 ; CHECK: calll _thiscall_with_inalloca