1 ; RUN: llc < %s -mtriple=aarch64-unknown-unknown | FileCheck %s
3 define i1 @andn_cmp(i32 %x, i32 %y) {
4 ; CHECK-LABEL: andn_cmp:
6 ; CHECK-NEXT: bics wzr, w1, w0
7 ; CHECK-NEXT: cset w0, eq
10 %notx = xor i32 %x, -1
11 %and = and i32 %notx, %y
12 %cmp = icmp eq i32 %and, 0
16 define i1 @and_cmp(i32 %x, i32 %y) {
17 ; CHECK-LABEL: and_cmp:
19 ; CHECK-NEXT: bics wzr, w1, w0
20 ; CHECK-NEXT: cset w0, eq
24 %cmp = icmp eq i32 %and, %y
28 define i1 @and_cmp_const(i32 %x) {
29 ; CHECK-LABEL: and_cmp_const:
31 ; CHECK-NEXT: mov w8, #43
32 ; CHECK-NEXT: bics wzr, w8, w0
33 ; CHECK-NEXT: cset w0, eq
37 %cmp = icmp eq i32 %and, 43