Home | History | Annotate | Download | only in IR

Lines Matching refs:CI2

918         if (ConstantInt *CI2 = dyn_cast<ConstantInt>(C2))
919 if (CI2->isOne())
952 if (ConstantInt *CI2 = dyn_cast<ConstantInt>(C2)) {
955 if (CI2->equalsInt(0)) return C1; // X + 0 == X
958 if (CI2->equalsInt(0)) return C1; // X - 0 == X
961 if (CI2->equalsInt(0)) return C2; // X * 0 == 0
962 if (CI2->equalsInt(1))
967 if (CI2->equalsInt(1))
969 if (CI2->equalsInt(0))
970 return UndefValue::get(CI2->getType()); // X / 0 == undef
974 if (CI2->equalsInt(1))
975 return Constant::getNullValue(CI2->getType()); // X % 1 == 0
976 if (CI2->equalsInt(0))
977 return UndefValue::get(CI2->getType()); // X % 0 == undef
980 if (CI2->isZero()) return C2; // X & 0 == 0
981 if (CI2->isAllOnesValue())
987 unsigned DstWidth = CI2->getType()->getBitWidth();
991 if ((PossiblySetBits & CI2->getValue()) == PossiblySetBits)
1006 unsigned DstWidth = CI2->getType()->getBitWidth();
1011 if ((CI2->getValue() & BitsNotSet) == CI2->getValue())
1012 return Constant::getNullValue(CI2->getType());
1018 if (CI2->equalsInt(0)) return C1; // X | 0 == X
1019 if (CI2->isAllOnesValue())
1023 if (CI2->equalsInt(0)) return C1; // X ^ 0 == X
1031 assert(CI2->equalsInt(1));
1054 if (ConstantInt *CI2 = dyn_cast<ConstantInt>(C2)) {
1056 const APInt &C2V = CI2->getValue();
1067 assert(!CI2->isNullValue() && "Div by zero handled above");
1070 assert(!CI2->isNullValue() && "Div by zero handled above");
1075 assert(!CI2->isNullValue() && "Div by zero handled above");
1078 assert(!CI2->isNullValue() && "Div by zero handled above");