blob: 25a242a559974e47cf16f833492b686825f4088c [file] [log] [blame]
Chris Lattnerc917d102002-06-24 17:45:37 +00001; -simplifycfg is not folding blocks if there is a PHI node involved. This
2; should be fixed eventually
3
Michael Gottesman41e4ac42013-01-31 01:04:23 +00004; RUN: opt < %s -simplifycfg -S | FileCheck %s
Chris Lattnerc917d102002-06-24 17:45:37 +00005
Tanya Lattner5f4b3552008-03-10 07:21:50 +00006define i32 @main(i32 %argc) {
7; <label>:0
Michael Gottesman41e4ac42013-01-31 01:04:23 +00008; CHECK-NOT: br label %InlinedFunctionReturnNode
Tanya Lattner5f4b3552008-03-10 07:21:50 +00009 br label %InlinedFunctionReturnNode
10InlinedFunctionReturnNode: ; preds = %0
11 %X = phi i32 [ 7, %0 ] ; <i32> [#uses=1]
12 %Y = add i32 %X, %argc ; <i32> [#uses=1]
13 ret i32 %Y
Chris Lattnerc917d102002-06-24 17:45:37 +000014}
15