Home
last modified time | relevance | path

Searched refs:UndefValue (Results 1 – 25 of 98) sorted by relevance

1234

/freebsd-9-stable/contrib/llvm/lib/Transforms/InstCombine/
DInstCombineVectorOps.cpp68 return UndefValue::get(VTy->getElementType()); in FindScalarElement()
93 return UndefValue::get(VTy->getElementType()); in FindScalarElement()
193 return ReplaceInstUsesWith(EI, UndefValue::get(EI.getType())); in visitExtractElementInst()
266 return ReplaceInstUsesWith(EI, UndefValue::get(EI.getType())); in visitExtractElementInst()
333 if (isa<UndefValue>(V)) { in CollectSingleShuffleElements()
334 Mask.assign(NumElts, UndefValue::get(Type::getInt32Ty(V->getContext()))); in CollectSingleShuffleElements()
361 if (isa<UndefValue>(ScalarOp)) { // inserting undef into vector. in CollectSingleShuffleElements()
366 Mask[InsertedIdx] = UndefValue::get(Type::getInt32Ty(V->getContext())); in CollectSingleShuffleElements()
412 if (isa<UndefValue>(V)) { in CollectShuffleElements()
413 Mask.assign(NumElts, UndefValue::get(Type::getInt32Ty(V->getContext()))); in CollectShuffleElements()
[all …]
DInstCombineCalls.cpp372 UndefValue::get(LHS->getType()), in visitCallInst()
386 UndefValue::get(LHS->getType()), in visitCallInst()
407 if (isa<UndefValue>(II->getArgOperand(1))) in visitCallInst()
408 return ReplaceInstUsesWith(CI, UndefValue::get(II->getType())); in visitCallInst()
414 UndefValue::get(II->getArgOperand(0)->getType()), in visitCallInst()
427 if (isa<UndefValue>(II->getArgOperand(0)) || in visitCallInst()
428 isa<UndefValue>(II->getArgOperand(1))) in visitCallInst()
429 return ReplaceInstUsesWith(CI, UndefValue::get(II->getType())); in visitCallInst()
435 UndefValue::get(II->getArgOperand(0)->getType()), in visitCallInst()
466 UndefValue::get(LHS->getType()), in visitCallInst()
[all …]
DInstCombineLoadStoreAlloca.cpp195 } else if (isa<UndefValue>(AI.getArraySize())) { in visitAllocaInst()
383 new StoreInst(UndefValue::get(LI.getType()), in visitLoadInst()
385 return ReplaceInstUsesWith(LI, UndefValue::get(LI.getType())); in visitLoadInst()
391 if (isa<UndefValue>(Op) || in visitLoadInst()
396 new StoreInst(UndefValue::get(LI.getType()), in visitLoadInst()
398 return ReplaceInstUsesWith(LI, UndefValue::get(LI.getType())); in visitLoadInst()
649 if (!isa<UndefValue>(Val)) { in visitStoreInst()
650 SI.setOperand(0, UndefValue::get(Val->getType())); in visitStoreInst()
658 if (isa<UndefValue>(Val)) in visitStoreInst()
DInstCombineSimplifyDemanded.cpp133 if (isa<UndefValue>(V)) in SimplifyDemandedUseBits()
135 return UndefValue::get(VTy); in SimplifyDemandedUseBits()
923 if (isa<UndefValue>(V)) { in SimplifyDemandedVectorElts()
931 return UndefValue::get(V->getType()); in SimplifyDemandedVectorElts()
944 Constant *Undef = UndefValue::get(EltTy); in SimplifyDemandedVectorElts()
957 if (isa<UndefValue>(Elt)) { // Already undef. in SimplifyDemandedVectorElts()
1086 Elts.push_back(UndefValue::get(Type::getInt32Ty(I->getContext()))); in SimplifyDemandedVectorElts()
1268 UndefValue::get(II->getType()), TmpV, in SimplifyDemandedVectorElts()
DInstCombinePHI.cpp683 return ReplaceInstUsesWith(FirstPhi, UndefValue::get(FirstPhi.getType())); in SliceUpIllegalIntegerPHI()
784 Value *Undef = UndefValue::get(FirstPhi.getType()); in SliceUpIllegalIntegerPHI()
817 return ReplaceInstUsesWith(PN, UndefValue::get(PN.getType())); in visitPHINode()
829 return ReplaceInstUsesWith(PN, UndefValue::get(PN.getType())); in visitPHINode()
/freebsd-9-stable/contrib/llvm/lib/IR/
DConstantFold.cpp512 if (isa<UndefValue>(V)) { in ConstantFoldCastInstruction()
519 return UndefValue::get(DestTy); in ConstantFoldCastInstruction()
721 if (isa<UndefValue>(Cond)) { in ConstantFoldSelectInstruction()
722 if (isa<UndefValue>(V1)) return V1; in ConstantFoldSelectInstruction()
725 if (isa<UndefValue>(V1)) return V2; in ConstantFoldSelectInstruction()
726 if (isa<UndefValue>(V2)) return V1; in ConstantFoldSelectInstruction()
745 if (isa<UndefValue>(Val)) // ee(undef, x) -> undef in ConstantFoldExtractElementInstruction()
746 return UndefValue::get(Val->getType()->getVectorElementType()); in ConstantFoldExtractElementInstruction()
750 if (isa<UndefValue>(Idx)) in ConstantFoldExtractElementInstruction()
751 return UndefValue::get(Val->getType()->getVectorElementType()); in ConstantFoldExtractElementInstruction()
[all …]
DConstants.cpp196 if (const UndefValue *UV = dyn_cast<UndefValue>(this)) in getAggregateElement()
693 UndefValue *UndefValue::getSequentialElement() const { in getSequentialElement()
694 return UndefValue::get(getType()->getSequentialElementType()); in getSequentialElement()
699 UndefValue *UndefValue::getStructElement(unsigned Elt) const { in getStructElement()
700 return UndefValue::get(getType()->getStructElementType(Elt)); in getStructElement()
705 UndefValue *UndefValue::getElementValue(Constant *C) const { in getElementValue()
713 UndefValue *UndefValue::getElementValue(unsigned Idx) const { in getElementValue()
760 if (isa<UndefValue>(C) && rangeOnlyContains(V.begin(), V.end(), C)) in get()
761 return UndefValue::get(Ty); in get()
883 isUndef = isa<UndefValue>(V[0]); in get()
[all …]
/freebsd-9-stable/contrib/llvm/lib/Transforms/IPO/
DIPConstantPropagation.cpp142 if (V == 0) V = UndefValue::get(AI->getType()); in PropagateConstantsIntoArguments()
173 RetVals.push_back(UndefValue::get(STy->getElementType(i))); in PropagateConstantReturn()
175 RetVals.push_back(UndefValue::get(F.getReturnType())); in PropagateConstantReturn()
195 if (isa<UndefValue>(V)) in PropagateConstantReturn()
200 if (isa<UndefValue>(RV)) { in PropagateConstantReturn()
/freebsd-9-stable/contrib/llvm/lib/Transforms/Scalar/
DSCCP.cpp230 if (!isa<UndefValue>(GV->getInitializer())) in TrackValueOfGlobalVariable()
379 if (!isa<UndefValue>(V)) in getValueState()
408 else if (isa<UndefValue>(Elt)) in getStructValueState()
955 markConstant(&I,ConstantExpr::getInsertElement(UndefValue::get(I.getType()), in visitInsertElementInst()
979 V1State.getConstant() : UndefValue::get(I.getType()); in visitShuffleVectorInst()
981 V2State.getConstant() : UndefValue::get(I.getType()); in visitShuffleVectorInst()
983 MaskState.getConstant() : UndefValue::get(I.getOperand(2)->getType()); in visitShuffleVectorInst()
1458 if (isa<UndefValue>(BI->getCondition())) { in ResolvedUndefsIn()
1480 if (isa<UndefValue>(SI->getCondition())) { in ResolvedUndefsIn()
1542 Inst->replaceAllUsesWith(UndefValue::get(Inst->getType())); in DeleteInstructionInBlock()
[all …]
DJumpThreading.cpp310 if (UndefValue *U = dyn_cast<UndefValue>(Val)) in getKnownConstant()
424 isa<UndefValue>(LHSVals[i].first)) { in ComputeValueKnownInPredecessors()
431 isa<UndefValue>(RHSVals[i].first)) { in ComputeValueKnownInPredecessors()
576 assert(isa<UndefValue>(Cond) && "Unexpected condition value"); in ComputeValueKnownInPredecessors()
705 if (isa<UndefValue>(Condition)) { in ProcessBlock()
870 if (AvailableVal == LI) AvailableVal = UndefValue::get(LI->getType()); in SimplifyPartiallyRedundantLoad()
1118 if (isa<UndefValue>(Val)) in ProcessThreadableEdges()
1262 if (isa<UndefValue>(XorOpValues[i].first)) in ProcessBranchOnXOR()
1283 !isa<UndefValue>(XorOpValues[i].first)) in ProcessBranchOnXOR()
1295 BO->replaceAllUsesWith(UndefValue::get(BO->getType())); in ProcessBranchOnXOR()
DStructurizeCFG.cpp162 UndefValue *BoolUndef;
273 BoolUndef = UndefValue::get(Boolean); in INITIALIZE_PASS_DEPENDENCY()
526 Value *Undef = UndefValue::get(Phi.getType()); in addPhiValues()
549 Value *Undef = UndefValue::get(Phi->getType()); in setPhiValues()
859 Value *Undef = UndefValue::get(II->getType()); in rebuildSSA()
/freebsd-9-stable/contrib/llvm/lib/Transforms/Utils/
DLocal.cpp299 return isa<UndefValue>(II->getArgOperand(1)); in isInstructionTriviallyDead()
306 return C->isNullValue() || isa<UndefValue>(C); in isInstructionTriviallyDead()
385 I->replaceAllUsesWith(UndefValue::get(I->getType())); in RecursivelyDeleteDeadPHINode()
482 if (NewVal == PN) NewVal = UndefValue::get(PN->getType()); in MergeBasicBlockIntoOnlyPred()
524 return First == Second || isa<UndefValue>(First) || isa<UndefValue>(Second); in CanMergeValues()
604 if (!isa<UndefValue>(OldVal)) { in selectIncomingValueForBlock()
633 if (!isa<UndefValue>(V)) in gatherIncomingValuesToPhi()
648 if (!isa<UndefValue>(V)) continue; in replaceUndefValuesInPhi()
1143 BBI->replaceAllUsesWith(UndefValue::get(BBI->getType())); in changeToUnreachable()
1204 if (isa<UndefValue>(Ptr) || in markAliveBlocks()
[all …]
DSSAUpdater.cpp130 return UndefValue::get(ProtoType); in GetValueInMiddleOfBlock()
260 return UndefValue::get(Updater->ProtoType); in GetUndefVal()
448 if (NewVal == ALoad) NewVal = UndefValue::get(NewVal->getType()); in run()
DValueMapper.cpp172 if (isa<UndefValue>(C)) in MapValue()
173 return VM[V] = UndefValue::get(NewTy); in MapValue()
DPromoteMemoryToRegister.cpp403 ReplVal = UndefValue::get(LI->getType()); in rewriteSingleStoreAlloca()
485 LI->replaceAllUsesWith(UndefValue::get(LI->getType())); in promoteSingleBlockAlloca()
635 Values[i] = UndefValue::get(Allocas[i]->getAllocatedType()); in run()
661 A->replaceAllUsesWith(UndefValue::get(A->getType())); in run()
756 Value *UndefVal = UndefValue::get(SomePHI->getType()); in run()
/freebsd-9-stable/contrib/llvm/lib/Analysis/
DLint.cpp381 Assert1(!isa<UndefValue>(UnderlyingObject), in visitMemoryReference()
475 Assert1(!isa<UndefValue>(I.getOperand(0)) || in visitXor()
476 !isa<UndefValue>(I.getOperand(1)), in visitXor()
481 Assert1(!isa<UndefValue>(I.getOperand(0)) || in visitSub()
482 !isa<UndefValue>(I.getOperand(1)), in visitSub()
509 if (isa<UndefValue>(V)) in isZero()
533 if (isa<UndefValue>(Elem)) in isZero()
628 return UndefValue::get(V->getType()); in findValueImpl()
DMemoryBuiltins.cpp427 if (UndefValue *UV = dyn_cast<UndefValue>(V)) in compute()
580 SizeOffsetType ObjectSizeOffsetVisitor::visitUndefValue(UndefValue&) { in visitUndefValue() argument
759 OffsetPHI->replaceAllUsesWith(UndefValue::get(IntTy)); in visitPHINode()
761 SizePHI->replaceAllUsesWith(UndefValue::get(IntTy)); in visitPHINode()
DConstantFolding.cpp273 if (isa<ConstantAggregateZero>(C) || isa<UndefValue>(C)) in ReadDataFromGlobal()
444 return UndefValue::get(IntType); in FoldReinterpretLoadFromConstPtr()
537 if (isa<UndefValue>(GV->getInitializer())) in ConstantFoldLoadFromConstPtr()
538 return UndefValue::get(ResTy); in ConstantFoldLoadFromConstPtr()
852 if (isa<UndefValue>(Incoming)) in ConstantFoldInstruction()
870 return CommonValue ? CommonValue : UndefValue::get(PN->getType()); in ConstantFoldInstruction()
1516 if (isa<UndefValue>(Operands[0])) { in ConstantFoldCall()
1626 return UndefValue::get(Ty); in ConstantFoldCall()
1630 return UndefValue::get(Ty); in ConstantFoldCall()
DInstructionSimplify.cpp389 if (TV && isa<UndefValue>(TV)) in ThreadBinOpOverSelect()
391 if (FV && isa<UndefValue>(FV)) in ThreadBinOpOverSelect()
746 return UndefValue::get(Op0->getType()); in SimplifySubInst()
1211 return UndefValue::get(Op0->getType()); in SimplifyRem()
1318 return UndefValue::get(Op0->getType()); in SimplifyShift()
1881 if (LHS == RHS || isa<UndefValue>(RHS)) in SimplifyICmpInst()
2620 if (isa<UndefValue>(RHS)) // fcmp pred X, undef -> undef in SimplifyFCmpInst()
2621 return UndefValue::get(GetCompareTy(LHS)); in SimplifyFCmpInst()
2709 if (isa<UndefValue>(CondVal)) { // select undef, X, Y -> X or Y in SimplifySelectInst()
2714 if (isa<UndefValue>(TrueVal)) // select C, undef, X -> X in SimplifySelectInst()
[all …]
/freebsd-9-stable/contrib/llvm/include/llvm/IR/
DConstants.h1129 class UndefValue : public Constant {
1131 UndefValue(const UndefValue &) LLVM_DELETED_FUNCTION;
1133 explicit UndefValue(Type *T) : Constant(T, UndefValueVal, 0, 0) {}
1143 static UndefValue *get(Type *T);
1147 UndefValue *getSequentialElement() const;
1151 UndefValue *getStructElement(unsigned Elt) const;
1155 UndefValue *getElementValue(Constant *C) const;
1159 UndefValue *getElementValue(unsigned Idx) const;
/freebsd-9-stable/contrib/llvm/lib/Transforms/Vectorize/
DBBVectorize.cpp677 if (!isa<UndefValue>(IENext->getOperand(0)) && in isPureIEChain()
1908 if (isa<UndefValue>(SI->getOperand(1))) in findBestDAGFor()
1940 if (isa<UndefValue>(SI->getOperand(1))) in findBestDAGFor()
2252 Mask[v+MaskOffset] = UndefValue::get(Type::getInt32Ty(Context)); in fillNewShuffleMask()
2318 UndefValue::get(ArgTypeL->getScalarType())); in expandIEChain()
2328 Value *LIEPrev = UndefValue::get(ArgTypeH); in expandIEChain()
2330 if (isa<UndefValue>(VectElemts[i])) continue; in expandIEChain()
2340 LOp = LIENext ? (Value*) LIENext : UndefValue::get(ArgTypeH); in expandIEChain()
2401 if (I2 == I1 || isa<UndefValue>(I2)) in getReplacementInput()
2420 if (!isa<UndefValue>(I4)) { in getReplacementInput()
[all …]
/freebsd-9-stable/contrib/llvm/tools/llvm-stress/
Dllvm-stress.cpp159 return UndefValue::get(Tp); in getRandomConstant()
192 return UndefValue::get(Tp); in getRandomValue()
203 return UndefValue::get(pickPointerType()); in getRandomPointerValue()
214 return UndefValue::get(pickVectorType()); in getRandomVectorValue()
445 CI = UndefValue::get(I32); in Act()
/freebsd-9-stable/contrib/llvm/lib/CodeGen/
DAnalysis.cpp335 if (isa<UndefValue>(RetVal)) in slotOnlyDiscardsData()
526 if (isa<UndefValue>(Ret->getOperand(0))) return true; in returnTypeIsEligibleForTailCall()
588 CallVal = UndefValue::get(SlotType); in returnTypeIsEligibleForTailCall()
/freebsd-9-stable/contrib/llvm/lib/Target/R600/
DSIAnnotateControlFlow.cpp53 UndefValue *BoolUndef;
123 BoolUndef = UndefValue::get(Boolean); in doInitialization()
/freebsd-9-stable/contrib/llvm/lib/ExecutionEngine/
DExecutionEngine.cpp540 if (isa<UndefValue>(C)) { in getConstantValue()
564 const Constant *ElemUndef = UndefValue::get(ElemTy); in getConstantValue()
892 if (!isa<UndefValue>(CV->getOperand(i))) in getConstantValue()
914 if (!isa<UndefValue>(CV->getOperand(i))) in getConstantValue()
936 if (!isa<UndefValue>(CV->getOperand(i))) in getConstantValue()
1133 if (isa<UndefValue>(Init)) in InitializeMemory()

1234