Lines Matching refs:Fold
35 /// Fold - Fold the constant using target specific information.
36 Constant *Fold(Constant *C) const {
52 return Fold(ConstantExpr::getAdd(LHS, RHS, HasNUW, HasNSW));
55 return Fold(ConstantExpr::getFAdd(LHS, RHS));
59 return Fold(ConstantExpr::getSub(LHS, RHS, HasNUW, HasNSW));
62 return Fold(ConstantExpr::getFSub(LHS, RHS));
66 return Fold(ConstantExpr::getMul(LHS, RHS, HasNUW, HasNSW));
69 return Fold(ConstantExpr::getFMul(LHS, RHS));
72 return Fold(ConstantExpr::getUDiv(LHS, RHS, isExact));
75 return Fold(ConstantExpr::getSDiv(LHS, RHS, isExact));
78 return Fold(ConstantExpr::getFDiv(LHS, RHS));
81 return Fold(ConstantExpr::getURem(LHS, RHS));
84 return Fold(ConstantExpr::getSRem(LHS, RHS));
87 return Fold(ConstantExpr::getFRem(LHS, RHS));
91 return Fold(ConstantExpr::getShl(LHS, RHS, HasNUW, HasNSW));
94 return Fold(ConstantExpr::getLShr(LHS, RHS, isExact));
97 return Fold(ConstantExpr::getAShr(LHS, RHS, isExact));
100 return Fold(ConstantExpr::getAnd(LHS, RHS));
103 return Fold(ConstantExpr::getOr(LHS, RHS));
106 return Fold(ConstantExpr::getXor(LHS, RHS));
111 return Fold(ConstantExpr::get(Opc, LHS, RHS));
120 return Fold(ConstantExpr::getNeg(C, HasNUW, HasNSW));
123 return Fold(ConstantExpr::getFNeg(C));
126 return Fold(ConstantExpr::getNot(C));
135 return Fold(ConstantExpr::getGetElementPtr(C, IdxList));
141 return Fold(ConstantExpr::getGetElementPtr(C, Idx));
145 return Fold(ConstantExpr::getGetElementPtr(C, IdxList));
150 return Fold(ConstantExpr::getInBoundsGetElementPtr(C, IdxList));
156 return Fold(ConstantExpr::getInBoundsGetElementPtr(C, Idx));
160 return Fold(ConstantExpr::getInBoundsGetElementPtr(C, IdxList));
170 return C; // avoid calling Fold
171 return Fold(ConstantExpr::getCast(Op, C, DestTy));
176 return C; // avoid calling Fold
177 return Fold(ConstantExpr::getIntegerCast(C, DestTy, isSigned));
181 return C; // avoid calling Fold
182 return Fold(ConstantExpr::getPointerCast(C, DestTy));
186 return C; // avoid calling Fold
187 return Fold(ConstantExpr::getFPCast(C, DestTy));
200 return C; // avoid calling Fold
201 return Fold(ConstantExpr::getZExtOrBitCast(C, DestTy));
205 return C; // avoid calling Fold
206 return Fold(ConstantExpr::getSExtOrBitCast(C, DestTy));
210 return C; // avoid calling Fold
211 return Fold(ConstantExpr::getTruncOrBitCast(C, DestTy));
220 return Fold(ConstantExpr::getCompare(P, LHS, RHS));
224 return Fold(ConstantExpr::getCompare(P, LHS, RHS));
232 return Fold(ConstantExpr::getSelect(C, True, False));
236 return Fold(ConstantExpr::getExtractElement(Vec, Idx));
241 return Fold(ConstantExpr::getInsertElement(Vec, NewElt, Idx));
246 return Fold(ConstantExpr::getShuffleVector(V1, V2, Mask));
251 return Fold(ConstantExpr::getExtractValue(Agg, IdxList));
256 return Fold(ConstantExpr::getInsertValue(Agg, Val, IdxList));