blob: b3c94859ef8ffc639d588cde3c2f2d4702de22a2 [file] [log] [blame]
Misha Brukmane78760e2003-09-16 15:29:54 +00001; RUN: llvm-as < %s | opt -simplifycfg
Chris Lattnerd7490bc2002-09-24 16:02:44 +00002
3int %test(int %A, int %B, bool %cond) {
4J:
5 %C = add int %A, 12
6 br bool %cond, label %L, label %L
7L:
8 %Q = phi int [%C, %J], [%C, %J] ; PHI node is obviously redundant
9 %D = add int %C, %B
10 %E = add int %Q, %D
11 ret int %E
12}