Reid Spencer | 69ccadd | 2006-12-02 04:23:10 +0000 | [diff] [blame] | 1 | ; RUN: llvm-upgrade < %s | llvm-as | opt -reassociate -instcombine -constprop -die | llvm-dis | not grep 5 |
Chris Lattner | b064baf | 2002-05-15 21:56:51 +0000 | [diff] [blame] | 2 | |
Chris Lattner | 50e8682 | 2003-06-28 23:23:34 +0000 | [diff] [blame] | 3 | int %test(int %A, int %B) { |
Chris Lattner | b064baf | 2002-05-15 21:56:51 +0000 | [diff] [blame] | 4 | %W = add int %B, -5 |
5 | %Y = add int %A, 5 | ||||
6 | %Z = add int %W, %Y | ||||
7 | ret int %Z | ||||
8 | } |