xref: /aosp_15_r20/external/llvm/test/CodeGen/X86/computeKnownBits_urem.ll (revision 9880d6810fe72a1726cb53787c6711e909410d58)
1*9880d681SAndroid Build Coastguard Worker; RUN: llc -mtriple=x86_64-linux < %s | FileCheck %s
2*9880d681SAndroid Build Coastguard Workerdefine i32 @main() #0 {
3*9880d681SAndroid Build Coastguard Workerentry:
4*9880d681SAndroid Build Coastguard Worker  %a = alloca i32, align 4
5*9880d681SAndroid Build Coastguard Worker  store i32 1, i32* %a, align 4
6*9880d681SAndroid Build Coastguard Worker  %0 = load i32, i32* %a, align 4
7*9880d681SAndroid Build Coastguard Worker  %or = or i32 1, %0
8*9880d681SAndroid Build Coastguard Worker  %and = and i32 1, %or
9*9880d681SAndroid Build Coastguard Worker  %rem = urem i32 %and, 1
10*9880d681SAndroid Build Coastguard Worker  %add = add i32 %rem, 1
11*9880d681SAndroid Build Coastguard Worker  ret i32 %add
12*9880d681SAndroid Build Coastguard Worker}
13*9880d681SAndroid Build Coastguard Worker; CHECK: $1, %eax
14*9880d681SAndroid Build Coastguard Worker; CHECK-NEXT: retq
15