1 ; RUN: opt %s -argpromotion -S -o - | FileCheck %s
2 ; RUN: opt %s -passes=argpromotion -S -o - | FileCheck %s
5 target datalayout = "e-m:e-i64:64-f80:128-n8:16:32:64-S128"
7 %pair = type { i32, i32 }
9 declare i8* @foo(%pair*)
11 define internal void @bar(%pair* byval %Data) {
12 ; CHECK: define internal void @bar(i32 %Data.0, i32 %Data.1)
13 ; CHECK: %Data = alloca %pair
15 ; CHECK: call i8* @foo(%pair* %Data)
16 tail call i8* @foo(%pair* %Data)
20 define void @zed(%pair* byval %Data) {
21 call void @bar(%pair* byval %Data)