Home
last modified time | relevance | path

Searched refs:Cst (Results 1 – 25 of 31) sorted by relevance

12

/external/llvm/tools/llvm-c-test/
Decho.cpp220 static LLVMValueRef clone_constant_impl(LLVMValueRef Cst, LLVMModuleRef M);
222 static LLVMValueRef clone_constant(LLVMValueRef Cst, LLVMModuleRef M) { in clone_constant() argument
223 LLVMValueRef Ret = clone_constant_impl(Cst, M); in clone_constant()
224 check_value_kind(Ret, LLVMGetValueKind(Cst)); in clone_constant()
228 static LLVMValueRef clone_constant_impl(LLVMValueRef Cst, LLVMModuleRef M) { in clone_constant_impl() argument
229 if (!LLVMIsAConstant(Cst)) in clone_constant_impl()
233 if (LLVMIsAGlobalValue(Cst)) { in clone_constant_impl()
234 const char *Name = LLVMGetValueName(Cst); in clone_constant_impl()
237 if (LLVMIsAFunction(Cst)) { in clone_constant_impl()
238 check_value_kind(Cst, LLVMFunctionValueKind); in clone_constant_impl()
[all …]
/external/llvm/lib/Target/AArch64/
DAArch64PromoteConstant.cpp250 static bool shouldConvertUse(const Constant *Cst, const Instruction *Instr, in shouldConvertUse() argument
316 static bool shouldConvertImpl(const Constant *Cst) { in shouldConvertImpl() argument
317 if (isa<const UndefValue>(Cst)) in shouldConvertImpl()
327 if (Cst->isZeroValue()) in shouldConvertImpl()
334 if (Cst->getType()->isVectorTy()) in shouldConvertImpl()
336 return isConstantUsingVectorTy(Cst->getType()); in shouldConvertImpl()
543 Constant *Cst = dyn_cast<Constant>(U); in runOnFunction() local
547 if (!Cst || isa<GlobalValue>(Cst) || isa<ConstantExpr>(Cst)) in runOnFunction()
551 if (!shouldConvert(*Cst, PromotionCache)) in runOnFunction()
556 if (!shouldConvertUse(Cst, &I, OpNo)) in runOnFunction()
[all …]
DAArch64AddressTypePromotion.cpp321 if (const ConstantInt *Cst = dyn_cast<ConstantInt>(Opnd)) { in propagateSignExtension() local
324 Cst->getSExtValue())); in propagateSignExtension()
/external/swiftshader/third_party/LLVM/include/llvm/MC/
DMCValue.h39 int64_t Cst; variable
42 int64_t getConstant() const { return Cst; } in getConstant()
59 R.Cst = Val;
67 R.Cst = Val; in get()
/external/llvm/include/llvm/MC/
DMCValue.h42 int64_t Cst; variable
46 int64_t getConstant() const { return Cst; } in getConstant()
66 R.Cst = Val;
75 R.Cst = Val; in get()
/external/swiftshader/third_party/LLVM/lib/Target/PowerPC/
DPPCCodeEmitter.cpp153 intptr_t Cst = 0; in GetRelocation() local
156 Cst = -(intptr_t)MovePCtoLROffset - 4; in GetRelocation()
162 Cst, isa<Function>(MO.getGlobal())); in GetRelocation()
165 RelocID, MO.getSymbolName(), Cst); in GetRelocation()
168 RelocID, MO.getIndex(), Cst); in GetRelocation()
176 RelocID, MO.getIndex(), Cst); in GetRelocation()
/external/llvm/lib/Transforms/Scalar/
DReassociate.cpp1792 Constant *Cst = nullptr; in OptimizeExpression() local
1796 Cst = Cst ? ConstantExpr::get(Opcode, C, Cst) : C; in OptimizeExpression()
1800 return Cst; in OptimizeExpression()
1805 if (Cst && Cst != ConstantExpr::getBinOpIdentity(Opcode, I->getType())) { in OptimizeExpression()
1806 if (Cst == ConstantExpr::getBinOpAbsorber(Opcode, I->getType())) in OptimizeExpression()
1807 return Cst; in OptimizeExpression()
1808 Ops.push_back(ValueEntry(0, Cst)); in OptimizeExpression()
/external/llvm/lib/Transforms/InstCombine/
DInstCombineCasts.cpp523 Value *A = nullptr; ConstantInt *Cst = nullptr; in visitTrunc() local
525 match(Src, m_LShr(m_ZExt(m_Value(A)), m_ConstantInt(Cst)))) { in visitTrunc()
534 if (Cst->getZExtValue() >= ASize) in visitTrunc()
540 Value *Shift = Builder->CreateLShr(A, Cst->getZExtValue()); in visitTrunc()
551 match(Src, m_LShr(m_SExt(m_Value(A)), m_ConstantInt(Cst))) && in visitTrunc()
558 if (Cst->getValue().ult(ASize)) { in visitTrunc()
559 Value *Shift = Builder->CreateAShr(A, Cst->getZExtValue()); in visitTrunc()
569 match(Src, m_And(m_Value(A), m_ConstantInt(Cst)))) { in visitTrunc()
572 ConstantExpr::getTrunc(Cst, DestTy)); in visitTrunc()
DInstCombineCompares.cpp1405 Constant *Cst = Builder->getInt1(IsICMP_NE); in FoldICmpShrCst() local
1406 return replaceInstUsesWith(ICI, Cst); in FoldICmpShrCst()
2001 Constant *Cst = Builder->getInt1(IsICMP_NE); in visitICmpInstWithInstAndIntCst() local
2002 return replaceInstUsesWith(ICI, Cst); in visitICmpInstWithInstAndIntCst()
4284 Value *X; ConstantInt *Cst; in visitICmpInst() local
4286 if (match(Op0, m_Add(m_Value(X), m_ConstantInt(Cst))) && Op1 == X) in visitICmpInst()
4287 return FoldICmpAddOpCst(I, X, Cst, I.getPredicate()); in visitICmpInst()
4290 if (match(Op1, m_Add(m_Value(X), m_ConstantInt(Cst))) && Op0 == X) in visitICmpInst()
4291 return FoldICmpAddOpCst(I, X, Cst, I.getSwappedPredicate()); in visitICmpInst()
/external/swiftshader/third_party/LLVM/lib/Transforms/InstCombine/
DInstCombineCasts.cpp466 Value *A = 0; ConstantInt *Cst = 0; in visitTrunc() local
468 match(Src, m_LShr(m_ZExt(m_Value(A)), m_ConstantInt(Cst)))) { in visitTrunc()
477 if (Cst->getZExtValue() >= ASize) in visitTrunc()
483 Value *Shift = Builder->CreateLShr(A, Cst->getZExtValue()); in visitTrunc()
492 match(Src, m_And(m_Value(A), m_ConstantInt(Cst)))) { in visitTrunc()
495 ConstantExpr::getTrunc(Cst, CI.getType())); in visitTrunc()
DInstCombineCompares.cpp966 Constant *Cst = ConstantInt::get(Type::getInt1Ty(ICI.getContext()), in FoldICmpShrCst() local
968 return ReplaceInstUsesWith(ICI, Cst); in FoldICmpShrCst()
1259 Constant *Cst = in visitICmpInstWithInstAndIntCst() local
1261 return ReplaceInstUsesWith(ICI, Cst); in visitICmpInstWithInstAndIntCst()
2559 Value *X; ConstantInt *Cst; in visitICmpInst() local
2561 if (match(Op0, m_Add(m_Value(X), m_ConstantInt(Cst))) && Op1 == X) in visitICmpInst()
2562 return FoldICmpAddOpCst(I, X, Cst, I.getPredicate(), Op0); in visitICmpInst()
2565 if (match(Op1, m_Add(m_Value(X), m_ConstantInt(Cst))) && Op0 == X) in visitICmpInst()
2566 return FoldICmpAddOpCst(I, X, Cst, I.getSwappedPredicate(), Op1); in visitICmpInst()
/external/swiftshader/third_party/LLVM/lib/Target/X86/
DX86ISelDAGToDAG.cpp748 if (ConstantSDNode *Cst = dyn_cast<ConstantSDNode>(N)) in MatchAddressRecursively() local
749 if (!FoldOffsetIntoAddress(Cst->getSExtValue(), AM)) in MatchAddressRecursively()
1774 ConstantSDNode *Cst = dyn_cast<ConstantSDNode>(N1); in Select() local
1776 if (!Cst || !ShlCst) in Select()
1779 int64_t Val = Cst->getSExtValue(); in Select()
DX86ISelLowering.cpp4305 SDValue Cst = DAG.getTargetConstant(0, MVT::i32); in getZeroVector() local
4306 Vec = DAG.getNode(ISD::BUILD_VECTOR, dl, MVT::v4i32, Cst, Cst, Cst, Cst); in getZeroVector()
4308 SDValue Cst = DAG.getTargetConstantFP(+0.0, MVT::f32); in getZeroVector() local
4309 Vec = DAG.getNode(ISD::BUILD_VECTOR, dl, MVT::v4f32, Cst, Cst, Cst, Cst); in getZeroVector()
4315 SDValue Cst = DAG.getTargetConstantFP(+0.0, MVT::f32); in getZeroVector() local
4316 SDValue Ops[] = { Cst, Cst, Cst, Cst, Cst, Cst, Cst, Cst }; in getZeroVector()
4331 SDValue Cst = DAG.getTargetConstant(~0U, MVT::i32); in getOnesVector() local
4333 Cst, Cst, Cst, Cst); in getOnesVector()
/external/llvm/lib/Target/AMDGPU/
DR600ISelLowering.cpp1085 if(ConstantSDNode *Cst = dyn_cast<ConstantSDNode>(Op)) { in isZero() local
1086 return Cst->isNullValue(); in isZero()
2227 ConstantSDNode *Cst in FoldOperand() local
2229 Consts.push_back(Cst->getZExtValue()); in FoldOperand()
2234 ConstantSDNode *Cst = cast<ConstantSDNode>(CstOffset); in FoldOperand() local
2235 Consts.push_back(Cst->getZExtValue()); in FoldOperand()
DAMDGPUISelDAGToDAG.cpp511 if (ConstantSDNode *Cst = dyn_cast<ConstantSDNode>(Addr)) { in SelectGlobalValueConstantOffset() local
512 IntPtr = CurDAG->getIntPtrConstant(Cst->getZExtValue() / 4, SDLoc(Addr), in SelectGlobalValueConstantOffset()
/external/swiftshader/third_party/LLVM/lib/Transforms/Scalar/
DReassociate.cpp214 Constant *Cst = Constant::getAllOnesValue(Neg->getType()); in LowerNegateToMultiply() local
216 Instruction *Res = BinaryOperator::CreateMul(Neg->getOperand(1), Cst, "",Neg); in LowerNegateToMultiply()
/external/llvm/lib/Target/X86/
DX86ISelDAGToDAG.cpp1130 if (ConstantSDNode *Cst = dyn_cast<ConstantSDNode>(N)) in matchAddressRecursively() local
1131 if (!foldOffsetIntoAddress(Cst->getSExtValue(), AM)) in matchAddressRecursively()
2046 ConstantSDNode *Cst = dyn_cast<ConstantSDNode>(N1); in Select() local
2048 if (!Cst || !ShlCst) in Select()
2051 int64_t Val = Cst->getSExtValue(); in Select()
/external/llvm/test/Analysis/BasicAA/
Dgep-alias.ll236 ; Make sure we recognize that u[0] and u[Global + Cst] may alias
/external/swiftshader/third_party/LLVM/lib/Transforms/Utils/
DSimplifyCFG.cpp1951 ConstantInt *Cst = cast<ConstantInt>(ICI->getOperand(1)); in TryToSimplifyUncondBranchWithICmpInIt() local
1982 if (SI->findCaseValue(Cst) != 0) { in TryToSimplifyUncondBranchWithICmpInIt()
2020 SI->addCase(Cst, NewBB); in TryToSimplifyUncondBranchWithICmpInIt()
/external/llvm/lib/Target/Hexagon/
DHexagonISelLowering.cpp2449 ConstantSDNode *Cst = dyn_cast<ConstantSDNode>(BVN->getOperand(i)); in LowerBUILD_VECTOR() local
2452 if (!Cst) { in LowerBUILD_VECTOR()
2479 if (ConstantSDNode *Cst = dyn_cast<ConstantSDNode>(Operand)) in LowerBUILD_VECTOR() local
2480 Val = Cst->getSExtValue(); in LowerBUILD_VECTOR()
/external/llvm/lib/Transforms/Instrumentation/
DMemorySanitizer.cpp2582 Constant *Cst = dyn_cast<Constant>(ArgShadow); in visitCallSite() local
2583 if (Cst && Cst->isNullValue()) ArgIsInitialized = true; in visitCallSite()
/external/llvm/lib/CodeGen/
DCodeGenPrepare.cpp3063 if (const ConstantInt *Cst = dyn_cast<ConstantInt>(Opnd)) { in promoteOperandForOther() local
3066 APInt CstVal = IsSExt ? Cst->getValue().sext(BitWidth) in promoteOperandForOther()
3067 : Cst->getValue().zext(BitWidth); in promoteOperandForOther()
/external/swiftshader/third_party/LLVM/lib/CodeGen/SelectionDAG/
DLegalizeIntegerTypes.cpp1690 const APInt &Cst = cast<ConstantSDNode>(N)->getAPIntValue(); in ExpandIntRes_Constant() local
1691 Lo = DAG.getConstant(Cst.trunc(NBitWidth), NVT); in ExpandIntRes_Constant()
1692 Hi = DAG.getConstant(Cst.lshr(NBitWidth).trunc(NBitWidth), NVT); in ExpandIntRes_Constant()
DDAGCombiner.cpp5070 SDValue Cst = DAG.getNode(ISD::BITCAST, N0.getDebugLoc(), in visitBITCAST() local
5072 Cst = DAG.getNode(ISD::AND, Cst.getDebugLoc(), VT, in visitBITCAST()
5073 Cst, DAG.getConstant(~SignBit, VT)); in visitBITCAST()
5074 AddToWorkList(Cst.getNode()); in visitBITCAST()
5076 return DAG.getNode(ISD::OR, N->getDebugLoc(), VT, X, Cst); in visitBITCAST()
/external/llvm/lib/CodeGen/SelectionDAG/
DDAGCombiner.cpp7546 SDValue Cst = DAG.getBitcast(VT, N0.getOperand(0)); in visitBITCAST() local
7547 AddToWorklist(Cst.getNode()); in visitBITCAST()
7550 SDValue XorResult = DAG.getNode(ISD::XOR, SDLoc(N0), VT, Cst, X); in visitBITCAST()
7564 return DAG.getNode(ISD::XOR, SDLoc(N), VT, Cst, FlipBits); in visitBITCAST()
7571 SDValue Cst = DAG.getBitcast(VT, N0.getOperand(0)); in visitBITCAST() local
7572 Cst = DAG.getNode(ISD::AND, SDLoc(Cst), VT, in visitBITCAST()
7573 Cst, DAG.getConstant(~SignBit, SDLoc(Cst), VT)); in visitBITCAST()
7574 AddToWorklist(Cst.getNode()); in visitBITCAST()
7576 return DAG.getNode(ISD::OR, SDLoc(N), VT, X, Cst); in visitBITCAST()

12