blob: 439ea545468e013ad0f8088bd40a37757bfdd887 [file] [log] [blame]
Daniel Dunbare0ae2b22009-09-07 19:26:18 +00001; RUN: bugpoint %s -output-prefix %t -bugpoint-crashcalls -silence-passes
Dan Gohman4d541e42010-06-07 20:58:11 +00002; RUN: llvm-dis %t-reduced-simplified.bc -o - | FileCheck %s
Chris Lattner484147d2003-06-24 23:40:27 +00003
Reid Spencer660c4f92007-03-19 18:08:42 +00004; Test to make sure that arguments are removed from the function if they are
Dan Gohmand0a6a8c2010-06-07 20:28:37 +00005; unnecessary. And clean up any types that that frees up too.
6
7; CHECK: target triple
8; CHECK-NOT: struct.anon
9%struct.anon = type { i32 }
Chris Lattner484147d2003-06-24 23:40:27 +000010
Reid Spencer660c4f92007-03-19 18:08:42 +000011declare i32 @test2()
12
Dan Gohmanb9539742010-06-07 20:20:33 +000013; CHECK: define void @test() {
Dan Gohmand0a6a8c2010-06-07 20:28:37 +000014define i32 @test(i32 %A, %struct.anon* %B, float %C) {
Reid Spencer660c4f92007-03-19 18:08:42 +000015 call i32 @test2()
16 ret i32 %1
Chris Lattner484147d2003-06-24 23:40:27 +000017}