1 ; RUN: opt < %s -instsimplify -S | FileCheck %s
3 define i64 @pow2(i32 %x) {
6 %x2 = and i32 %x, %negx
7 %e = zext i32 %x2 to i64
9 %e2 = and i64 %e, %nege
14 define i64 @pow2b(i32 %x) {
15 ; CHECK-LABEL: @pow2b(
17 %e = zext i32 %sh to i64
19 %e2 = and i64 %e, %nege
24 define i32 @sub_neg_nuw(i32 %x, i32 %y) {
25 ; CHECK-LABEL: @sub_neg_nuw(
26 %neg = sub nuw i32 0, %y
27 %sub = sub i32 %x, %neg