Home
last modified time | relevance | path

Searched refs:PHI (Results 1 – 25 of 167) sorted by relevance

1234567

/external/llvm/lib/CodeGen/
DMachineSSAUpdater.cpp188 MachineInstrBuilder InsertedPHI = InsertNewDef(TargetOpcode::PHI, BB, in GetValueInMiddleOfBlock()
252 MachineInstr *PHI; member in llvm::SSAUpdaterTraits::PHI_iterator
257 : PHI(P), idx(1) {} in PHI_iterator()
259 : PHI(P), idx(PHI->getNumOperands()) {} in PHI_iterator()
264 unsigned getIncomingValue() { return PHI->getOperand(idx).getReg(); } in getIncomingValue()
266 return PHI->getOperand(idx+1).getMBB(); in getIncomingBlock()
269 static inline PHI_iterator PHI_begin(PhiT *PHI) { return PHI_iterator(PHI); } in PHI_begin() argument
270 static inline PHI_iterator PHI_end(PhiT *PHI) { in PHI_end() argument
271 return PHI_iterator(PHI, true); in PHI_end()
300 MachineInstr *PHI = InsertNewDef(TargetOpcode::PHI, BB, Loc, in CreateEmptyPHI() local
[all …]
DEarlyIfConversion.cpp111 MachineInstr *PHI; member
117 : PHI(phi), TReg(0), FReg(0), CondCycles(0), TCycles(0), FCycles(0) {} in PHIInfo()
413 for (unsigned i = 1; i != PI.PHI->getNumOperands(); i += 2) { in canConvertIf()
414 if (PI.PHI->getOperand(i+1).getMBB() == TPred) in canConvertIf()
415 PI.TReg = PI.PHI->getOperand(i).getReg(); in canConvertIf()
416 if (PI.PHI->getOperand(i+1).getMBB() == FPred) in canConvertIf()
417 PI.FReg = PI.PHI->getOperand(i).getReg(); in canConvertIf()
425 DEBUG(dbgs() << "Can't convert: " << *PI.PHI); in canConvertIf()
462 DEBUG(dbgs() << "If-converting " << *PI.PHI); in replacePHIInstrs()
463 unsigned DstReg = PI.PHI->getOperand(0).getReg(); in replacePHIInstrs()
[all …]
/external/llvm/lib/Transforms/Utils/
DSSAUpdater.cpp65 static bool IsEquivalentPHI(PHINode *PHI, in IsEquivalentPHI() argument
67 unsigned PHINumValues = PHI->getNumIncomingValues(); in IsEquivalentPHI()
73 if (ValueMapping[PHI->getIncomingBlock(i)] != in IsEquivalentPHI()
74 PHI->getIncomingValue(i)) { in IsEquivalentPHI()
221 PHINode *PHI; member in llvm::SSAUpdaterTraits::PHI_iterator
226 : PHI(P), idx(0) {} in PHI_iterator()
228 : PHI(P), idx(PHI->getNumIncomingValues()) {} in PHI_iterator()
233 Value *getIncomingValue() { return PHI->getIncomingValue(idx); } in getIncomingValue()
234 BasicBlock *getIncomingBlock() { return PHI->getIncomingBlock(idx); } in getIncomingBlock()
237 static PHI_iterator PHI_begin(PhiT *PHI) { return PHI_iterator(PHI); } in PHI_begin() argument
[all …]
DSimplifyCFG.cpp3313 while (PHINode *PHI = dyn_cast<PHINode>(I++)) { in FindPHIForConditionForwarding() local
3314 int Idx = PHI->getBasicBlockIndex(BB); in FindPHIForConditionForwarding()
3317 Value *InValue = PHI->getIncomingValue(Idx); in FindPHIForConditionForwarding()
3321 return PHI; in FindPHIForConditionForwarding()
3340 PHINode *PHI = FindPHIForConditionForwarding(CaseValue, CaseDest, in ForwardSwitchConditionToPHI() local
3342 if (!PHI) continue; in ForwardSwitchConditionToPHI()
3344 ForwardingNodes[PHI].push_back(PhiIndex); in ForwardSwitchConditionToPHI()
3484 while (PHINode *PHI = dyn_cast<PHINode>(I++)) { in GetCaseResults() local
3485 int Idx = PHI->getBasicBlockIndex(Pred); in GetCaseResults()
3489 Constant *ConstVal = LookupConstant(PHI->getIncomingValue(Idx), in GetCaseResults()
[all …]
DFlattenCFG.cpp127 PHINode *PHI = dyn_cast<PHINode>(BB->begin()); in FlattenParallelAndOr() local
128 if (PHI) in FlattenParallelAndOr()
264 PHI = dyn_cast<PHINode>(PS2->begin()); in FlattenParallelAndOr()
265 if (PHI) in FlattenParallelAndOr()
DInlineFunction.cpp85 PHINode *PHI = cast<PHINode>(I); in InvokeInliningInfo() local
86 UnwindDestPHIValues.push_back(PHI->getIncomingValueForBlock(InvokeBB)); in InvokeInliningInfo()
1339 PHINode *PHI = nullptr; in InlineFunction() local
1344 PHI = PHINode::Create(RTy, Returns.size(), TheCall->getName(), in InlineFunction()
1348 TheCall->replaceAllUsesWith(PHI); in InlineFunction()
1353 if (PHI) { in InlineFunction()
1356 assert(RI->getReturnValue()->getType() == PHI->getType() && in InlineFunction()
1358 PHI->addIncoming(RI->getReturnValue(), RI->getParent()); in InlineFunction()
1436 if (PHI) { in InlineFunction()
1438 if (Value *V = SimplifyInstruction(PHI, DL, nullptr, nullptr, in InlineFunction()
[all …]
/external/llvm/include/llvm/Transforms/Utils/
DSSAUpdaterImpl.h335 ValT PHI = Traits::CreateEmptyPHI(Info->BB, Info->NumPreds, Updater); in FindAvailableVals() local
336 Info->AvailableVal = PHI; in FindAvailableVals()
337 (*AvailableVals)[Info->BB] = PHI; in FindAvailableVals()
355 PhiT *PHI = Traits::ValueIsNewPHI(Info->AvailableVal, Updater); in FindAvailableVals() local
356 if (!PHI) in FindAvailableVals()
366 Traits::AddPHIOperand(PHI, PredInfo->AvailableVal, Pred); in FindAvailableVals()
369 DEBUG(dbgs() << " Inserted PHI: " << *PHI << "\n"); in FindAvailableVals()
372 if (InsertedPHIs) InsertedPHIs->push_back(PHI); in FindAvailableVals()
397 bool CheckIfPHIMatches(PhiT *PHI) { in CheckIfPHIMatches() argument
399 WorkList.push_back(PHI); in CheckIfPHIMatches()
[all …]
/external/llvm/test/Transforms/ADCE/
D2003-04-25-PHIPostDominateProblem.ll1 ; THis testcase caused an assertion failure because a PHI node did not have
3 ; PHI node is dead, so we just avoid patching up dead PHI nodes.
D2002-05-23-ZeroArgPHITest.ll3 ; into was that when the reg109 PHI was getting zero predecessors, it was
5 ; in with a dummy value before the PHI is deleted.
/external/llvm/test/Verifier/
DPhiGrouping.ll2 ; CHECK: PHI nodes not grouped at top
13 %x = add i32 %a, 0 ; Error, PHI's should be grouped!
DSelfReferential.ll2 ; CHECK: Only PHI nodes may reference their own value
/external/llvm/lib/Transforms/Scalar/
DScalarizer.cpp560 bool Scalarizer::visitPHINode(PHINode &PHI) { in visitPHINode() argument
561 VectorType *VT = dyn_cast<VectorType>(PHI.getType()); in visitPHINode()
566 IRBuilder<> Builder(PHI.getParent(), &PHI); in visitPHINode()
570 unsigned NumOps = PHI.getNumOperands(); in visitPHINode()
573 PHI.getName() + ".i" + Twine(I)); in visitPHINode()
576 Scatterer Op = scatter(&PHI, PHI.getIncomingValue(I)); in visitPHINode()
577 BasicBlock *IncomingBlock = PHI.getIncomingBlock(I); in visitPHINode()
581 gather(&PHI, Res); in visitPHINode()
DConstantHoisting.cpp446 if (auto PHI = dyn_cast<PHINode>(Inst)) { in updateOperand() local
453 BasicBlock *IncomingBB = PHI->getIncomingBlock(Idx); in updateOperand()
455 if (PHI->getIncomingBlock(i) == IncomingBB) { in updateOperand()
456 Value *IncomingVal = PHI->getIncomingValue(i); in updateOperand()
/external/llvm/test/Transforms/SimplifyCFG/
DPhiBlockMerge2.ll1 ; Test merging of blocks that only have PHI nodes in them. This tests the case
2 ; where the mergedinto block doesn't have any PHI nodes, and is in fact
DPhiEliminate.ll2 ; be able to fold PHI nodes into computation in common cases. Folding the PHI
DPHINode.ll1 ; -simplifycfg is not folding blocks if there is a PHI node involved. This
/external/llvm/test/Transforms/Mem2Reg/
D2003-10-05-DeadPHIInsertion.ll1 ; Mem2reg should not insert dead PHI nodes! The naive algorithm inserts a PHI
/external/llvm/lib/Transforms/ObjCARC/
DObjCARCContract.cpp573 if (PHINode *PHI = dyn_cast<PHINode>(U.getUser())) { in runOnFunction() local
576 BasicBlock *BB = PHI->getIncomingBlock(ValNo); in runOnFunction()
583 for (unsigned i = 0, e = PHI->getNumIncomingValues(); i != e; ++i) in runOnFunction()
584 if (PHI->getIncomingBlock(i) == BB) { in runOnFunction()
587 &PHI->getOperandUse( in runOnFunction()
590 PHI->setIncomingValue(i, Replacement); in runOnFunction()
/external/llvm/test/Transforms/SROA/
Dphi-and-select.ll63 ; into the same alloca partation continues to work with PHI speculation. This
212 ; a PHI that can be speculated.
240 ; Same as @test8 but for a select rather than a PHI node.
261 ; rewriting due to the necessity of inserting bitcasts when speculating a PHI
291 ; Same as @test10 but for a select rather than a PHI node.
412 ; PHI nodes or select nodes. This triggers subtly differently from the above
413 ; cases because the PHI node is (recursively) alive, but the select is dead.
433 ; Here we form a PHI-node by promoting the pointer alloca first, and then in
572 ; Verifies we fixed PR20822. We have a foldable PHI feeding a speculatable PHI
573 ; which requires the rewriting of the speculated PHI to handle insertion
[all …]
/external/llvm/lib/Analysis/
DMemoryBuiltins.cpp735 SizeOffsetEvalType ObjectSizeOffsetEvaluator::visitPHINode(PHINode &PHI) { in visitPHINode() argument
737 PHINode *SizePHI = Builder.CreatePHI(IntTy, PHI.getNumIncomingValues()); in visitPHINode()
738 PHINode *OffsetPHI = Builder.CreatePHI(IntTy, PHI.getNumIncomingValues()); in visitPHINode()
741 CacheMap[&PHI] = std::make_pair(SizePHI, OffsetPHI); in visitPHINode()
744 for (unsigned i = 0, e = PHI.getNumIncomingValues(); i != e; ++i) { in visitPHINode()
745 Builder.SetInsertPoint(PHI.getIncomingBlock(i)->getFirstInsertionPt()); in visitPHINode()
746 SizeOffsetEvalType EdgeData = compute_(PHI.getIncomingValue(i)); in visitPHINode()
755 SizePHI->addIncoming(EdgeData.first, PHI.getIncomingBlock(i)); in visitPHINode()
756 OffsetPHI->addIncoming(EdgeData.second, PHI.getIncomingBlock(i)); in visitPHINode()
/external/llvm/test/Transforms/InstCombine/
D2004-01-13-InstCombineInvokePHI.ll3 ; inserting a cast of the return value after the PHI instruction, but which is
4 ; used by the PHI instruction. This is bad: because of the semantics of the
/external/llvm/test/Transforms/JumpThreading/
Dthread-loads.ll81 ; predecessor ends up with two entries in the PHI node and they must share
98 ; CHECK: %[[PHI:.*]] = phi i8* [ %[[CAST]], %[[PRED:[^ ]+]] ], [ %[[CAST]], %[[PRED]] ]
99 ; CHECK-NEXT: %[[CMP:.*]] = icmp eq i8* %[[PHI]], null
/external/llvm/lib/CodeGen/SelectionDAG/
DSelectionDAGISel.cpp969 TII->get(TargetOpcode::PHI), FuncInfo->ExceptionSelectorVirtReg); in PrepareEHLandingPad()
1107 case Instruction::PHI: NumFastIselFailPHI++; return; in collectFailStats()
1470 MachineInstrBuilder PHI(*MF, FuncInfo->PHINodesToUpdate[i].first); in FinishBasicBlock() local
1471 assert(PHI->isPHI() && in FinishBasicBlock()
1473 if (!FuncInfo->MBB->isSuccessor(PHI->getParent())) in FinishBasicBlock()
1475 PHI.addReg(FuncInfo->PHINodesToUpdate[i].second).addMBB(FuncInfo->MBB); in FinishBasicBlock()
1572 MachineInstrBuilder PHI(*MF, FuncInfo->PHINodesToUpdate[pi].first); in FinishBasicBlock() local
1573 MachineBasicBlock *PHIBB = PHI->getParent(); in FinishBasicBlock()
1574 assert(PHI->isPHI() && in FinishBasicBlock()
1579 PHI.addReg(FuncInfo->PHINodesToUpdate[pi].second) in FinishBasicBlock()
[all …]
/external/llvm/include/llvm/Target/
DTargetOpcodes.h26 PHI = 0, enumerator
/external/llvm/test/CodeGen/X86/
D2010-09-30-CMOV-JumpTable-PHI.ll8 ; That causes the PHI to be updated wrong because the jumptable data structure is remembering the o…
10 ; -cgp-critical-edge-splitting=0 prevents the edge to PHI from being split.

1234567