Home | History | Annotate | Download | only in Analysis

Lines Matching full:instruction

32                                        Instruction::CastOps Op,
45 Instruction *Ret = NULL;
77 // instruction with different dominance properties than a cast
89 Instruction::CastOps Op = CastInst::getCastOpcode(V, false, Ty, false);
90 assert((Op == Instruction::BitCast ||
91 Op == Instruction::PtrToInt ||
92 Op == Instruction::IntToPtr) &&
98 if (Op == Instruction::BitCast) {
107 if ((Op == Instruction::PtrToInt || Op == Instruction::IntToPtr) &&
110 if ((CI->getOpcode() == Instruction::PtrToInt ||
111 CI->getOpcode() == Instruction::IntToPtr) &&
116 if ((CE->getOpcode() == Instruction::PtrToInt ||
117 CE->getOpcode() == Instruction::IntToPtr) &&
140 // Cast the instruction immediately after the instruction.
141 Instruction *I = cast<Instruction>(V);
152 Value *SCEVExpander::InsertBinop(Instruction::BinaryOps Opcode,
162 // Scanning starts from the last instruction before the insertion point.
193 Instruction *BO = cast<Instruction>(Builder.CreateBinOp(Opcode, LHS, RHS));
520 assert(!isa<Instruction>(V) ||
521 SE.DT->dominates(cast<Instruction>(V), Builder.GetInsertPoint()));
534 // Scanning starts from the last instruction before the insertion point.
543 if (IP->getOpcode() == Instruction::GetElementPtr &&
646 if (const Instruction *I = dyn_cast<Instruction>(U->getValue()))
648 // A non-instruction has no relevant loops.
745 if (!isa<Instruction>(U->getValue()))
755 NewOps.push_back(isa<Instruction>(Sum) ? SE.getUnknown(Sum) :
764 Sum = InsertBinop(Instruction::Sub, Sum, W);
772 Sum = InsertBinop(Instruction::Add, Sum, W);
806 Prod = InsertBinop(Instruction::Sub, Constant::getNullValue(Ty), Prod);
814 Prod = InsertBinop(Instruction::Mul, Prod, W);
829 return InsertBinop(Instruction::LShr, LHS,
834 return InsertBinop(Instruction::UDiv, LHS, RHS);
861 bool SCEVExpander::isNormalAddRecExprPHI(PHINode *PN, Instruction *IncV,
872 if (Instruction *OInst = dyn_cast<Instruction>(OI))
876 // Advance to the next instruction.
877 IncV = dyn_cast<Instruction>(IncV->getOperand(0));
899 Instruction *SCEVExpander::getIVIncOperand(Instruction *IncV,
900 Instruction *InsertPos,
909 case Instruction::Add:
910 case Instruction::Sub: {
911 Instruction *OInst = dyn_cast<Instruction>(IncV->getOperand(1));
913 return dyn_cast<Instruction>(IncV->getOperand(0));
916 case Instruction::BitCast:
917 return dyn_cast<Instruction>(IncV->getOperand(0));
918 case Instruction::GetElementPtr:
919 for (Instruction::op_iterator I = IncV->op_begin()+1, E = IncV->op_end();
923 if (Instruction *OInst = dyn_cast<Instruction>(*I)) {
943 return dyn_cast<Instruction>(IncV->getOperand(0));
950 bool SCEVExpander::hoistIVInc(Instruction *IncV, Instruction *InsertPos) {
961 SmallVector<Instruction*, 4> IVIncs;
963 Instruction *Oper = getIVIncOperand(IncV, InsertPos, /*allowScale*/true);
972 for (SmallVectorImpl<Instruction*>::reverse_iterator I = IVIncs.rbegin(),
984 bool SCEVExpander::isExpandedAddRecExprPHI(PHINode *PN, Instruction *IncV,
986 for(Instruction *IVOper = IncV;
1046 Instruction *IncV =
1047 cast<Instruction>(PN->getIncomingValueForBlock(LatchBlock));
1066 IncV = cast<Instruction>(IncV->getOperand(0));
1097 assert(!isa<Instruction>(StartV) ||
1098 SE.DT->properlyDominates(cast<Instruction>(StartV)->getParent(),
1134 Instruction *InsertPos = L == IVIncInsertLoop ?
1219 if (isa<Instruction>(Result)
1220 && !SE.DT->dominates(cast<Instruction>(Result),
1295 llvm::next(BasicBlock::iterator(cast<Instruction>(V)));
1349 // Insert a unit add instruction right before the terminator
1351 Instruction *Add = BinaryOperator::CreateAdd(CanonicalIV, One,
1478 Instruction *IP) {
1497 Instruction *InsertPt = Builder.GetInsertPoint();
1525 std::map<std::pair<const SCEV *, Instruction *>, TrackingVH<Value> >::iterator
1653 Instruction *OrigInc =
1654 cast<Instruction>(OrigPhiRef->getIncomingValueForBlock(LatchBlock));
1655 Instruction *IsomorphicInc =
1656 cast<Instruction>(Phi->getIncomingValueForBlock(LatchBlock));
1686 Instruction *IP = isa<PHINode>(OrigInc)
1687 ? (Instruction*)L->getHeader()->getFirstInsertionPt()
1717 // instruction, but the important thing is that we prove the denominator is