1 ; This test makes sure that these instructions are properly eliminated.
4 ; RUN: if as < %s | opt -instcombine | dis | grep and
12 %B = and int %A, 0 ; zero result
17 %B = and int %A, -1 ; noop
21 bool %test3(bool %A) {
22 %B = and bool %A, false ; always = false
26 bool %test4(bool %A) {
27 %B = and bool %A, true ; noop
36 bool %test6(bool %A) {
41 int %test7(int %A) { ; A & ~A == 0
42 %NotA = xor int %A, -1
43 %B = and int %A, %NotA
47 ubyte %test8(ubyte %A) { ; AND associates