Chris Lattner | 679da03 | 2002-05-06 17:00:47 +0000 | [diff] [blame] | 1 | ; This test makes sure that these instructions are properly eliminated. |
| 2 | ; |
| 3 | |
Chris Lattner | f9b9af0 | 2002-08-14 17:37:04 +0000 | [diff] [blame] | 4 | ; RUN: if as < %s | opt -instcombine -die | dis | grep xor |
Chris Lattner | 679da03 | 2002-05-06 17:00:47 +0000 | [diff] [blame] | 5 | ; RUN: then exit 1 |
| 6 | ; RUN: else exit 0 |
| 7 | ; RUN: fi |
| 8 | |
| 9 | implementation |
| 10 | |
| 11 | int "test1"(int %A) { |
Chris Lattner | f9b9af0 | 2002-08-14 17:37:04 +0000 | [diff] [blame] | 12 | %B = xor int %A |
| 13 | %C = xor int %B |
Chris Lattner | 679da03 | 2002-05-06 17:00:47 +0000 | [diff] [blame] | 14 | ret int %C |
| 15 | } |
| 16 | |