Reid Spencer | d0e30dc | 2006-12-02 04:23:10 +0000 | [diff] [blame^] | 1 | ; RUN: llvm-upgrade < %s | llvm-as | opt -adce | llvm-dis | not grep call |
Chris Lattner | 854c086 | 2005-02-17 19:27:44 +0000 | [diff] [blame] | 2 | |
3 | ; The call is not live just because the PHI uses the call retval! | ||||
4 | |||||
5 | int %test(int %X) { | ||||
6 | br label %Done | ||||
7 | |||||
8 | DeadBlock: | ||||
9 | %Y = call int %test(int 0) | ||||
10 | br label %Done | ||||
11 | |||||
12 | Done: | ||||
13 | %Z = phi int [%X, %0], [%Y, %DeadBlock] | ||||
14 | ret int %Z | ||||
15 | } |