LLVM 19.0.0git
|
A templated base class for SmallPtrSet
which provides the typesafe interface that is common across all small sizes.
More...
#include "llvm/ADT/SmallPtrSet.h"
Inherits llvm::SmallPtrSetImplBase.
Inherited by llvm::SmallPtrSet< BasicBlockT *, 8 >, llvm::SmallPtrSet< const BasicBlock *, 8 >, llvm::SmallPtrSet< const BasicBlockT *, 32 >, llvm::SmallPtrSet< const MachineBasicBlock *, 8 >, llvm::SmallPtrSet< typename GraphTraits< std::conditional_t< IsConst, const BlockT, BlockT > * >::NodeRef, 8 >, llvm::SmallPtrSet< PointeeType *, N >, llvm::SmallPtrSet< typename GraphTraits< GraphT >::NodeRef >, llvm::SmallPtrSet< typename GraphTraits< T >::NodeRef, 8 >, llvm::SmallPtrSet< typename GraphTraits< GraphT >::NodeRef, 8 >, llvm::SmallPtrSet< NodeRef, 8 >, llvm::SmallPtrSet< const MDNode *, 8 >, llvm::SmallPtrSet< Instruction *, 4 >, llvm::SmallPtrSet< llvm::MachineBasicBlock *, 16 >, llvm::SmallPtrSet< llvm::LiveRange *, 8 >, llvm::SmallPtrSet< const llvm::AllocaInst *, 8 >, llvm::SmallPtrSet< CallBase *, 2 >, llvm::SmallPtrSet< AssumeInst *, 4 >, llvm::SmallPtrSet< const MachineInstr *, 16 >, llvm::SmallPtrSet< const llvm::GlobalVariable *, 2 >, llvm::SmallPtrSet< const llvm::GlobalVariable *, 1 >, llvm::SmallPtrSet< llvm::BasicBlock *, 8 >, llvm::SmallPtrSet< const llvm::Value *, 16 >, llvm::SmallPtrSet< const llvm::MachineBasicBlock *, 2 >, llvm::SmallPtrSet< llvm::Function *, 16 >, llvm::SmallPtrSet< llvm::GlobalObject *, 2 >, llvm::SmallPtrSet< const llvm::MDNode *, 32 >, llvm::SmallPtrSet< llvm::Instruction *, 32 >, llvm::SmallPtrSet< llvm::Use *, 16 >, llvm::SmallPtrSet< const MDNode *, 4 >, llvm::SmallPtrSet< llvm::GlobalVariable *, 8 >, llvm::SmallPtrSet< llvm::Constant *, 8 >, llvm::SmallPtrSet< llvm::GlobalValue *, 4 >, llvm::SmallPtrSet< const llvm::BasicBlock *, 4 >, llvm::SmallPtrSet< const llvm::DbgDeclareInst *, 8 >, llvm::SmallPtrSet< const llvm::DbgVariableRecord *, 8 >, llvm::SmallPtrSet< llvm::Function *, 32 >, llvm::SmallPtrSet< llvm::MachineInstr *, 4 >, llvm::SmallPtrSet< const BlockT *, 4 >, llvm::SmallPtrSet< const BlockT *, 32 >, llvm::SmallPtrSet< const CycleT *, 16 >, llvm::SmallPtrSet< const InstructionT *, 32 >, llvm::SmallPtrSet< llvm::GlobalValue *, 32 >, llvm::SmallPtrSet< const llvm::GlobalValue *, 8 >, llvm::SmallPtrSet< const Loop *, 2 >, llvm::SmallPtrSet< llvm::Instruction *, 16 >, llvm::SmallPtrSet< const llvm::Value *, 32 >, llvm::SmallPtrSet< const llvm::Function *, 8 >, llvm::SmallPtrSet< llvm::InterleaveGroup< llvm::Instruction > *, 4 >, llvm::SmallPtrSet< const llvm::BasicBlock *, 16 >, llvm::SmallPtrSet< llvm::Module *, 4 >, llvm::SmallPtrSet< llvm::MachineInstr *, 32 >, llvm::SmallPtrSet< const llvm::VNInfo *, 4 >, llvm::SmallPtrSet< const BlockT *, 8 >, llvm::SmallPtrSet< llvm::PHINode *, 4 >, llvm::SmallPtrSet< llvm::Type *, 16 >, llvm::SmallPtrSet< llvm::Instruction *, 4 >, llvm::SmallPtrSet< const PHINode *, 8 >, llvm::SmallPtrSet< llvm::Value *, 4 >, llvm::SmallPtrSet< const llvm::Instruction *, 8 >, llvm::SmallPtrSet< const llvm::MCSymbol *, 32 >, llvm::SmallPtrSet< Module *, 4 >, llvm::SmallPtrSet< const llvm::LazyCallGraph::Node *, 1 >, llvm::SmallPtrSet< llvm::MachineRegisterInfo::Delegate *, 1 >, llvm::SmallPtrSet< const Value *, 8 >, llvm::SmallPtrSet< llvm::Instruction *, 8 >, llvm::SmallPtrSet< void *, 2 >, llvm::SmallPtrSet< llvm::AnalysisKey *, 2 >, llvm::SmallPtrSet< llvm::Value *, 16 >, llvm::SmallPtrSet< const llvm::SCEV *, 8 >, llvm::SmallPtrSet< llvm::BasicBlock *, 2 >, llvm::SmallPtrSet< const llvm::Type *, 4 >, llvm::SmallPtrSet< const llvm::Value *, 6 >, llvm::SmallPtrSet< const llvm::PHINode *, 6 >, llvm::SmallPtrSet< const llvm::SCEVAddRecExpr *, 16 >, llvm::SmallPtrSet< const llvm::SCEVPredicate *, 4 >, llvm::SmallPtrSet< const llvm::Instruction *, 4 >, llvm::SmallPtrSet< llvm::BasicBlock *, 16 >, llvm::SmallPtrSet< llvm::MachineBasicBlock *, 8 >, llvm::SmallPtrSet< llvm::cl::SubCommand *, 1 >, llvm::SmallPtrSet< llvm::Use *, 8 >, llvm::SmallPtrSet< llvm::Instruction *, 2 >, llvm::SmallPtrSet< Value *, 16 >, and llvm::SmallPtrSet< PtrType, SmallSize >.
Public Types | |
using | iterator = SmallPtrSetIterator< PtrType > |
using | const_iterator = SmallPtrSetIterator< PtrType > |
using | key_type = ConstPtrType |
using | value_type = PtrType |
![]() | |
using | size_type = unsigned |
Public Member Functions | |
SmallPtrSetImpl (const SmallPtrSetImpl &)=delete | |
std::pair< iterator, bool > | insert (PtrType Ptr) |
Inserts Ptr if and only if there is no element in the container equal to Ptr. | |
iterator | insert (iterator, PtrType Ptr) |
Insert the given pointer with an iterator hint that is ignored. | |
bool | erase (PtrType Ptr) |
Remove pointer from the set. | |
template<typename UnaryPredicate > | |
bool | remove_if (UnaryPredicate P) |
Remove elements that match the given predicate. | |
size_type | count (ConstPtrType Ptr) const |
count - Return 1 if the specified pointer is in the set, 0 otherwise. | |
iterator | find (ConstPtrType Ptr) const |
bool | contains (ConstPtrType Ptr) const |
template<typename IterT > | |
void | insert (IterT I, IterT E) |
void | insert (std::initializer_list< PtrType > IL) |
iterator | begin () const |
iterator | end () const |
![]() | |
SmallPtrSetImplBase & | operator= (const SmallPtrSetImplBase &)=delete |
bool | empty () const |
size_type | size () const |
void | clear () |
![]() | |
void | incrementEpoch () |
Protected Member Functions | |
SmallPtrSetImplBase (const void **SmallStorage, const SmallPtrSetImplBase &that) | |
SmallPtrSetImplBase (const void **SmallStorage, unsigned SmallSize, SmallPtrSetImplBase &&that) | |
SmallPtrSetImplBase (const void **SmallStorage, unsigned SmallSize) | |
![]() | |
SmallPtrSetImplBase (const void **SmallStorage, const SmallPtrSetImplBase &that) | |
SmallPtrSetImplBase (const void **SmallStorage, unsigned SmallSize, SmallPtrSetImplBase &&that) | |
SmallPtrSetImplBase (const void **SmallStorage, unsigned SmallSize) | |
~SmallPtrSetImplBase () | |
const void ** | EndPointer () const |
std::pair< const void *const *, bool > | insert_imp (const void *Ptr) |
insert_imp - This returns true if the pointer was new to the set, false if it was already in the set. | |
bool | erase_imp (const void *Ptr) |
erase_imp - If the set contains the specified pointer, remove it and return true, otherwise return false. | |
const void *const * | find_imp (const void *Ptr) const |
Returns the raw pointer needed to construct an iterator. | |
bool | isSmall () const |
void | swap (SmallPtrSetImplBase &RHS) |
swap - Swaps the elements of two sets. | |
void | CopyFrom (const SmallPtrSetImplBase &RHS) |
void | MoveFrom (unsigned SmallSize, SmallPtrSetImplBase &&RHS) |
Additional Inherited Members | |
![]() | |
static void * | getTombstoneMarker () |
static void * | getEmptyMarker () |
![]() | |
const void ** | SmallArray |
SmallArray - Points to a fixed size set of buckets, used in 'small mode'. | |
const void ** | CurArray |
CurArray - This is the current set of buckets. | |
unsigned | CurArraySize |
CurArraySize - The allocated size of CurArray, always a power of two. | |
unsigned | NumNonEmpty |
Number of elements in CurArray that contain a value or are a tombstone. | |
unsigned | NumTombstones |
Number of tombstones in CurArray. | |
A templated base class for SmallPtrSet
which provides the typesafe interface that is common across all small sizes.
This is particularly useful for passing around between interface boundaries to avoid encoding a particular small size in the interface boundary.
Definition at line 323 of file SmallPtrSet.h.
using llvm::SmallPtrSetImpl< PtrType >::const_iterator = SmallPtrSetIterator<PtrType> |
Definition at line 334 of file SmallPtrSet.h.
using llvm::SmallPtrSetImpl< PtrType >::iterator = SmallPtrSetIterator<PtrType> |
Definition at line 333 of file SmallPtrSet.h.
using llvm::SmallPtrSetImpl< PtrType >::key_type = ConstPtrType |
Definition at line 335 of file SmallPtrSet.h.
using llvm::SmallPtrSetImpl< PtrType >::value_type = PtrType |
Definition at line 336 of file SmallPtrSet.h.
|
delete |
|
inline |
Definition at line 432 of file SmallPtrSet.h.
References llvm::SmallPtrSetImplBase::CurArray, llvm::SmallPtrSetImplBase::EndPointer(), and llvm::shouldReverseIterate().
Referenced by collectInstructionsInBetween(), llvm::LoopVectorizationCostModel::collectValuesToIgnore(), ComputeLiveInBlocks(), findBBsToSinkInto(), llvm::objcarc::findSingleDependency(), if(), iterativelySimplifyCFG(), llvm::MergeBlockSuccessorsIntoGivenBlocks(), PeepholePPC64ZExtGather(), llvm::LoopVectorizationLegality::prepareToFoldTailByMasking(), llvm::ARMConstantPoolConstant::promotedGlobals(), llvm::RecurrenceDescriptor::RecurrenceDescriptor(), llvm::SCCPSolver::removeNonFeasibleEdges(), llvm::AbstractDependenceGraphBuilder< GraphType >::simplify(), and llvm::LLVMContextImpl::~LLVMContextImpl().
|
inline |
Definition at line 418 of file SmallPtrSet.h.
References llvm::SmallPtrSetImplBase::EndPointer(), llvm::SmallPtrSetImplBase::find_imp(), and Ptr.
Referenced by AddAliasScopeMetadata(), llvm::LoopSafetyInfo::allLoopPathsLeadToBlock(), llvm::InterleavedAccessInfo::analyzeInterleaving(), llvm::SampleProfileInference< FT >::apply(), llvm::ScalarEvolution::canReuseInstruction(), checkIfSupported(), llvm::CloneAndPruneIntoFromInst(), collectPromotionCandidates(), llvm::filterDeadComdatFunctions(), llvm::findPHICopyInsertPoint(), llvm::memtag::forAllReachableExits(), llvm::LLVMContext::generateMachineFunctionNum(), generateNewInstTree(), llvm::SCEVExpander::getAllInsertedInstructions(), llvm::MDNode::getMostGenericAliasScope(), hasCallsInBlocksBetween(), llvm::GenericUniformityAnalysisImpl< ContextT >::hasDivergentTerminator(), llvm::hasPartialIVCondition(), llvm::PreservedAnalyses::intersect(), llvm::GenericDomTreeUpdater< DerivedT, DomTreeT, PostDomTreeT >::isBBPendingDeletion(), isConstReg(), llvm::GenericUniformityAnalysisImpl< ContextT >::isDivergent(), llvm::slpvectorizer::BoUpSLP::isGathered(), AliasScopeTracker::isNoAliasScopeDeclDead(), llvm::slpvectorizer::BoUpSLP::isNotScheduled(), isReachableImpl(), llvm::ModifiedPostOrder< ContextT >::isReducibleCycleHeader(), mayLoopAccessLocation(), mbbHasBackEdge(), llvm::MergeBlockIntoPredecessor(), peelToTurnInvariantLoadsDerefencebale(), llvm::refineInstruction(), llvm::SCCPSolver::removeNonFeasibleEdges(), removeUnreachableFunctions(), llvm::slpvectorizer::BoUpSLP::VLOperands::reorder(), rewriteFunction(), llvm::LoopFullUnrollPass::run(), llvm::LiveVariables::runOnMachineFunction(), StripSymbolNames(), llvm::TryToSimplifyUncondBranchFromEmptyBlock(), UpdatePHINodes(), ValidateMVEStore(), llvm::slpvectorizer::BoUpSLP::vectorizeTree(), and llvm::ScalarEvolution::verify().
|
inline |
count - Return 1 if the specified pointer is in the set, 0 otherwise.
Definition at line 412 of file SmallPtrSet.h.
References llvm::SmallPtrSetImplBase::EndPointer(), llvm::SmallPtrSetImplBase::find_imp(), and Ptr.
Referenced by AddAliasScopeMetadata(), addArgumentAttrs(), llvm::MachineRegisterInfo::addDelegate(), llvm::RecurrenceDescriptor::AddReductionVar(), llvm::LoopSafetyInfo::allLoopPathsLeadToBlock(), alwaysInlineImpl(), llvm::CodeMetrics::analyzeBasicBlock(), analyzeLoopUnrollCost(), llvm::SampleProfileInference< FT >::apply(), llvm::RecurrenceDescriptor::areAllUsesIn(), llvm::MemoryDepChecker::areDepsSafe(), bothUsedInPHI(), buildClonedLoops(), llvm::ForwardDominanceFrontierBase< BlockT >::calculate(), llvm::LoopVectorizationCostModel::calculateRegisterUsage(), CanPropagatePredecessorsForPHIs(), canProveExitOnFirstIteration(), CanRedirectPredsOfEmptyBBToSucc(), checkForCyclesHelper(), checkOuterLoopInsts(), checkPHIs(), llvm::CloneFunctionInto(), collectCastInstrs(), collectLeaves(), llvm::DomTreeNodeBase< NodeT >::compare(), completeEphemeralValues(), ComputeLiveInBlocks(), llvm::computeMinimumValueSizes(), ComputePostOrders(), llvm::JumpThreadingPass::computeValueKnownInPredecessorsImpl(), llvm::LoopBase< BlockT, LoopT >::contains(), llvm::WebAssemblyException::contains(), llvm::containsIrreducibleCFG(), llvm::OpenMPIRBuilder::createParallel(), deleteIfDead(), determinePointerAccessAttrs(), llvm::LiveRangeEdit::didRematerialize(), dominatesMergePoint(), llvm::SMSchedule::earliestCycleInChain(), llvm::EliminateUnreachableBlocks(), llvm::findAllocaForValue(), findBestInsertionSet(), findBestNonTrivialUnswitchCandidate(), findDependencies(), llvm::FindFunctionBackedges(), FoldTwoEntryPHINode(), llvm::ReachingDefAnalysis::getGlobalUses(), llvm::ReachingDefAnalysis::getLiveOuts(), llvm::AArch64InstrInfo::getOutliningTypeImpl(), getSingleLiveInSuccBB(), llvm::slpvectorizer::BoUpSLP::getTreeCost(), getTrueOrFalseValue(), getUnwindDestToken(), llvm::RecurrenceDescriptor::hasMultipleUsesOf(), llvm::hasOutsideLoopUser(), llvm::SDNode::hasPredecessorHelper(), hasSameSuccessors(), InsertRootInitializers(), llvm::MDNode::intersect(), llvm::intersectAccessGroups(), isAllDILocation(), llvm::Loop::isAnnotatedParallel(), llvm::SCCPInstVisitor::isArgumentTrackedFunction(), llvm::SparseSolver< LatticeKey, LatticeVal, KeyInfo >::isBlockExecutable(), llvm::LoopVectorizationLegality::isCastedInductionVariable(), isDILocationReachable(), llvm::LoopVectorizationLegality::isFixedOrderRecurrence(), llvm::IVUsers::isIVUserOrOperand(), llvm::LiveVariables::isLiveOut(), llvm::DomTreeBuilder::SemiNCAInfo< DomTreeT >::isPermutation(), isReachableAmongDominated(), isReachableImpl(), IsSafeAndProfitableToMove(), llvm::isSafeToUnrollAndJam(), isSuccOrder(), isUnmergeableGlobal(), llvm::SMSchedule::latestCycleInChain(), llvm::SelectionDAG::LegalizeOp(), LinearizeExprTree(), mayLoopAccessLocation(), moveHeaderPhiOperandsToForeBlocks(), llvm::SCCPInstVisitor::mustPreserveReturn(), llvm::mustTriggerUB(), llvm::nonStrictlyPostDominate(), optimizeLoopExitWithUnknownExitCount(), partitionLoopBlocks(), llvm::LoopVectorizationLegality::prepareToFoldTailByMasking(), llvm::InstCombinerImpl::prepareWorklist(), llvm::PreservedAnalyses::PreservedAnalysisChecker::preserved(), llvm::PreservedAnalyses::PreservedAnalysisChecker::preservedSet(), llvm::AlignmentFromAssumptionsPass::processAssumption(), processHeaderPhiOperands(), recomputeLoopBlockSet(), recordConditions(), llvm::objcopy::macho::Object::removeSections(), llvm::removeUnreachableBlocks(), llvm::SPIRVMergeRegionExitTargets::replaceBranchTargets(), llvm::replaceSignedInst(), llvm::MachineRegisterInfo::resetDelegate(), llvm::SCCPInstVisitor::resetLatticeValueFor(), rewriteDebugUsers(), llvm::MemDerefPrinterPass::run(), llvm::ModuleToPostOrderCGSCCPassAdaptor::run(), runImpl(), llvm::JumpThreadingPass::runImpl(), runMoveAutoInit(), llvm::SPIRVMergeRegionExitTargets::runOnConvergenceRegionNoRecurse(), llvm::BreakFalseDeps::runOnMachineFunction(), SafeToMergeTerminators(), separateNestedLoop(), simplifyLoopInst(), llvm::JumpThreadingPass::simplifyPartiallyRedundantLoad(), sink(), llvm::LoopNest::skipEmptyBlockUntil(), llvm::InstCombinerImpl::SliceUpIllegalIntegerPHI(), sortBlocks(), splitPredecessorsOfLoopExit(), stripLoopMDLoc(), llvm::UnrollAndJamLoop(), updateCGAndAnalysisManagerForPass(), llvm::MemorySSAUpdater::updateForClonedLoop(), UpdatePHINodes(), updatePostorderSequenceForEdgeInsertion(), updatePredecessorProfileMetadata(), llvm::AssumptionCacheTracker::verifyAnalysis(), llvm::MemorySSA::verifyDominationNumbers(), llvm::yaml::WebAssemblyFunctionInfo::WebAssemblyFunctionInfo(), and llvm::MemorySSAUpdater::wireOldPredecessorsToNewImmediatePredecessor().
|
inline |
Definition at line 437 of file SmallPtrSet.h.
References llvm::SmallPtrSetImplBase::EndPointer().
Referenced by llvm::LoopVectorizationCostModel::collectValuesToIgnore(), ComputeLiveInBlocks(), findBBsToSinkInto(), if(), iterativelySimplifyCFG(), peelToTurnInvariantLoadsDerefencebale(), PeepholePPC64ZExtGather(), llvm::LoopVectorizationLegality::prepareToFoldTailByMasking(), llvm::ARMConstantPoolConstant::promotedGlobals(), llvm::RecurrenceDescriptor::RecurrenceDescriptor(), and llvm::AbstractDependenceGraphBuilder< GraphType >::simplify().
|
inline |
Remove pointer from the set.
Returns whether the pointer was in the set. Invalidates iterators if true is returned. To remove elements while iterating over the set, use remove_if() instead.
Definition at line 361 of file SmallPtrSet.h.
References llvm::SmallPtrSetImplBase::erase_imp(), and Ptr.
Referenced by llvm::ARMFrameLowering::adjustForSegmentedStacks(), buildClonedLoops(), llvm::LoopVectorizationCostModel::calculateRegisterUsage(), checkForCyclesHelper(), collectInstructionsInBetween(), ComputePostOrders(), llvm::FindFunctionBackedges(), llvm::slpvectorizer::BoUpSLP::getSpillCost(), hasCallsInBlocksBetween(), llvm::SelectionDAG::Legalize(), llvm::MergeBlockSuccessorsIntoGivenBlocks(), optimizeLoopExitWithUnknownExitCount(), llvm::LanaiInstrInfo::optimizeSelect(), llvm::ARMBaseInstrInfo::optimizeSelect(), llvm::RISCVInstrInfo::optimizeSelect(), rebuildLoopAfterUnswitch(), llvm::LoopBase< BlockT, LoopT >::removeBlockFromLoop(), llvm::WebAssemblyException::removeFromBlocksSet(), llvm::MachineRegisterInfo::resetDelegate(), llvm::AbstractDependenceGraphBuilder< GraphType >::simplify(), SinkCommonCodeFromPredecessors(), and llvm::MemorySSA::verifyDominationNumbers().
|
inline |
Definition at line 415 of file SmallPtrSet.h.
References llvm::SmallPtrSetImplBase::find_imp(), and Ptr.
Referenced by peelToTurnInvariantLoadsDerefencebale().
|
inline |
Insert the given pointer with an iterator hint that is ignored.
This is identical to calling insert(Ptr), but allows SmallPtrSet to be used by std::insert_iterator and std::inserter().
Definition at line 352 of file SmallPtrSet.h.
References llvm::SmallPtrSetImpl< PtrType >::insert(), and Ptr.
|
inline |
Definition at line 423 of file SmallPtrSet.h.
References E, I, and llvm::SmallPtrSetImpl< PtrType >::insert().
|
inline |
Inserts Ptr if and only if there is no element in the container equal to Ptr.
The bool component of the returned pair is true if and only if the insertion takes place, and the iterator component of the pair points to the element equal to Ptr.
Definition at line 344 of file SmallPtrSet.h.
References llvm::SmallPtrSetImplBase::insert_imp(), and Ptr.
Referenced by AddAliasScopeMetadata(), llvm::AAExecutionDomain::ExecutionDomainTy::addAlignedBarrier(), addArgumentAttrs(), llvm::SCCPInstVisitor::addArgumentTrackedFunction(), llvm::AAExecutionDomain::ExecutionDomainTy::addAssumeInst(), llvm::WebAssemblyException::addBlock(), llvm::LoopBase< BlockT, LoopT >::addBlockEntry(), llvm::MachineRegisterInfo::addDelegate(), llvm::AArch64FunctionInfo::addLOHDirective(), llvm::RecurrenceDescriptor::AddReductionVar(), llvm::WebAssemblyException::addToBlocksSet(), llvm::SCCPInstVisitor::addToMustPreserveReturnsInFunctions(), llvm::SCCPInstVisitor::addTrackedFunction(), llvm::IVUsers::AddUsersIfInteresting(), llvm::slpvectorizer::BoUpSLP::ShuffleInstructionBuilder::adjustExtracts(), llvm::VPlanTransforms::adjustFixedOrderRecurrences(), llvm::ARMFrameLowering::adjustForSegmentedStacks(), llvm::PreservedAnalyses::all(), llvm::LoopSafetyInfo::allLoopPathsLeadToBlock(), AllUsesOfValueWillTrapIfNull(), alwaysInlineImpl(), llvm::SPIRV::ConvergenceRegionAnalyzer::analyze(), analyzeGlobalAux(), llvm::InterleavedAccessInfo::analyzeInterleaving(), llvm::ModifiedPostOrder< ContextT >::appendBlock(), appendSpeculatableOperands(), llvm::ScalarEvolution::applyLoopGuards(), llvm::MemoryDepChecker::areDepsSafe(), buildClonedLoopBlocks(), buildClonedLoops(), llvm::SampleProfileLoaderBaseImpl< FT >::buildEdges(), llvm::buildModuleSummaryIndex(), llvm::ForwardDominanceFrontierBase< BlockT >::calculate(), llvm::IDFCalculatorBase< NodeTy, IsPostDom >::calculate(), llvm::LoopVectorizationCostModel::calculateRegisterUsage(), llvm::DomTreeUpdater::callbackDeleteBB(), canonicalizePHIOperands(), canProveExitOnFirstIteration(), canRenameUntilSecondLoad(), canRenameUpToDef(), canReturn(), llvm::ScalarEvolution::canReuseInstruction(), llvm::PatternMatch::undef_match::check(), llvm::Attributor::checkForAllUses(), checkForCyclesHelper(), checkIfSupported(), checkMixedPrecision(), checkPHIs(), CleanupConstantGlobalUsers(), clearAssumptionsOfUsers(), llvm::CloneAndPruneIntoFromInst(), llvm::CloneFunctionInto(), llvm::OpenMPIRBuilder::OutlineInfo::collectBlocks(), collectCastInstrs(), llvm::CodeMetrics::collectEphemeralValues(), collectEscapedLocals(), collectHomogenousInstGraphLoopInvariants(), llvm::LoopVectorizationCostModel::collectInLoopReductions(), collectInstructionsInBetween(), collectLeaves(), collectMDInDomain(), collectPHINodes(), collectPromotionCandidates(), collectSRATypes(), collectTransitivePredecessors(), llvm::FunctionComparator::compare(), llvm::DomTreeNodeBase< NodeT >::compare(), completeEphemeralValues(), computeFunctionSummary(), computeHeuristicUnrollFactor(), ComputeLiveInBlocks(), llvm::computeMinimumValueSizes(), computePath(), ComputePostOrders(), computeUnlikelySuccessors(), llvm::JumpThreadingPass::computeValueKnownInPredecessorsImpl(), ConstHasGlobalValuePredicate(), contains(), llvm::containsIrreducibleCFG(), containsNewBackedge(), llvm::StructType::containsScalableVectorType(), llvm::ScalarEvolution::convertSCEVToAddRecWithPredicates(), llvm::SelectionDAG::copyExtraInfo(), llvm::AbstractDependenceGraphBuilder< GraphType >::createDefUseEdges(), llvm::DomTreeUpdater::deleteBB(), llvm::MachineDomTreeUpdater::deleteBB(), llvm::detachDeadBlocks(), determinePointerAccessAttrs(), llvm::AsmPrinter::doFinalization(), dominatesMergePoint(), DumpNodesr(), llvm::SMSchedule::earliestCycleInChain(), llvm::AsmPrinter::emitJumpTableInfo(), llvm::VETargetLowering::emitSjLjDispatchBlock(), llvm::Evaluator::EvaluateFunction(), llvm::filterDeadComdatFunctions(), llvm::DIBuilder::finalize(), FindAllMemoryUses(), llvm::findAllocaForValue(), findArgParts(), findBBsToSinkInto(), findBestInsertionSet(), findBestNonTrivialUnswitchCandidate(), findDbgIntrinsics(), findDependencies(), findExtractedOutputToOverallOutputMapping(), llvm::MustBeExecutedContextExplorer::findForwardJoinPoint(), llvm::FindFunctionBackedges(), findLoopComponents(), llvm::HexagonInstrInfo::findLoopInstr(), findNonImmUse(), findPartitions(), llvm::findPHICopyInsertPoint(), findRefEdges(), FindUsedValues(), findUsedValues(), llvm::findValuesAffectedByCondition(), llvm::InstCombinerImpl::foldFreezeIntoRecurrence(), llvm::memtag::forAllReachableExits(), forEachUser(), llvm::ScalarEvolution::forgetBlockAndLoopDispositions(), llvm::ScalarEvolution::forgetValue(), llvm::formDedicatedExitBlocks(), llvm::FunctionPropertiesUpdater::FunctionPropertiesUpdater(), generateReproducer(), llvm::Attributor::getAssumedSimplifiedValues(), getCallArgsTotalAllocaSize(), getEdgeKind(), llvm::BasicTTIImplBase< T >::getEstimatedNumberOfCaseClusters(), llvm::ReachingDefAnalysis::getGlobalReachingDefs(), llvm::ReachingDefAnalysis::getGlobalUses(), llvm::ReachingDefAnalysis::getLiveOuts(), llvm::LexicalScopes::getMachineBasicBlocks(), llvm::MDNode::getMostGenericAliasScope(), llvm::MemoryDependenceResults::getNonLocalCallDependency(), llvm::BasicTTIImplBase< T >::getOperandsScalarizationOverhead(), getOutliningPenalty(), llvm::BasicBlock::getPostdominatingDeoptimizeCall(), getPostIndexedLoadStoreOp(), llvm::slpvectorizer::BoUpSLP::getSpillCost(), GetStringLengthH(), llvm::slpvectorizer::BoUpSLP::getTreeCost(), getTypeSizeImpl(), llvm::getUnderlyingObjects(), llvm::getUnderlyingObjectsForCodeGen(), llvm::getUniqueExitBlocksHelper(), getUnwindDestToken(), llvm::slpvectorizer::BoUpSLP::getVectorElementSize(), llvm::guessSuccessors(), HandleInlinedLandingPad(), HandleMergeInputChains(), HasAddressTaken(), hasCallsInBlocksBetween(), hasCFUser(), hasConcreteDef(), hasConcreteDefImpl(), hasHardUserWithinLoop(), llvm::hasPartialIVCondition(), llvm::SDNode::hasPredecessorHelper(), llvm::SmallPtrSetImpl< PtrType >::insert(), llvm::df_iterator_default_set< NodeRef, SmallSize >::insert(), llvm::MemorySSAUpdater::insertDef(), llvm::LazyCallGraph::RefSCC::insertIncomingRefEdge(), InsertIntrinsicCalls(), InsertRootInitializers(), isAllDILocation(), llvm::LazyCallGraph::RefSCC::isAncestorOf(), llvm::LazyCallGraph::SCC::isAncestorOf(), llvm::Loop::isAnnotatedParallel(), llvm::IsBlockFollowedByDeoptOrUnreachable(), isBlockValidForExtraction(), isConstReg(), isDeadPHICycle(), isDereferenceableAndAlignedPointer(), isDILocationReachable(), isEphemeralValueOf(), llvm::RecurrenceDescriptor::isFixedOrderRecurrence(), llvm::isGuardAsWidenableBranch(), isHighCostExpansion(), isInertARCValue(), isKnownNonNullFromDominatingCondition(), llvm::LiveVariables::isLiveOut(), isLocalAlloca(), isNonEqualPHIs(), isNonEscapingGlobalNoAliasWithLoad(), isObjectSizeLessThanOrEq(), isOnlyCopiedFromConstantMemory(), isPotentiallyReachable(), isReachableAmongDominated(), isReachableImpl(), llvm::isSafeToDestroyConstant(), isSafeToMove(), llvm::isSafeToMoveBefore(), IsScalarTBAANodeImpl(), isSignExtendedW(), isSimpleEnoughValueToCommit(), llvm::StructType::isSized(), IsStoredObjCPointer(), isSuccOrder(), isSuspendReachableFrom(), isUniformlyReached(), iterativelySimplifyCFG(), llvm::SMSchedule::latestCycleInChain(), llvm::LazyCallGraph::LazyCallGraph(), llvm::SelectionDAG::Legalize(), llvm::SelectionDAG::LegalizeOp(), LinearizeExprTree(), lookThroughAnd(), llvm::LoopBase< BlockT, LoopT >::LoopBase(), markAliveBlocks(), MarkBlocksLiveIn(), llvm::ARMFunctionInfo::markGlobalAsPromotedToConstantPool(), llvm::LiveRangeEdit::markRematerialized(), llvm::CombinerHelper::matchExtendThroughPhis(), llvm::MergeBasicBlockIntoOnlyPred(), llvm::MergeBlockIntoPredecessor(), mergeConditionalStores(), llvm::SelectionDAG::MorphNodeTo(), llvm::nonStrictlyPostDominate(), llvm::SmallPtrSet< PtrType, SmallSize >::operator=(), optimizeGlobalsInModule(), optimizeLoopExitWithUnknownExitCount(), llvm::LanaiInstrInfo::optimizeSelect(), llvm::ARMBaseInstrInfo::optimizeSelect(), llvm::Thumb2InstrInfo::optimizeSelect(), llvm::RISCVInstrInfo::optimizeSelect(), parseCondition(), partitionLoopBlocks(), partitionOuterLoopBlocks(), peelToTurnInvariantLoadsDerefencebale(), PeepholePPC64ZExtGather(), PerformMVEVLDCombine(), performNEONPostLDSTCombine(), performPostLD1Combine(), PHIsEqualValue(), llvm::LoopVectorizationLegality::prepareToFoldTailByMasking(), llvm::InstCombinerImpl::prepareWorklist(), llvm::AlignmentFromAssumptionsPass::processAssumption(), processHeaderPhiOperands(), processSwitches(), PushDefUseChildren(), PushLoopPHIs(), rebuildLoopAfterUnswitch(), recomputeLoopBlockSet(), recordConditions(), llvm::RecursivelyDeleteDeadPHINode(), recursivelyDeleteDeadRecipes(), recursivelyVisitUsers(), llvm::AssumptionCache::registerAssumption(), llvm::AMDGPU::removeFnAttrFromReachable(), llvm::SCCPSolver::removeNonFeasibleEdges(), llvm::objcopy::macho::Object::removeSections(), removeSwitchAfterSelectFold(), llvm::LiveRange::RenumberValues(), llvm::slpvectorizer::BoUpSLP::VLOperands::reorder(), llvm::slpvectorizer::BoUpSLP::reorderBottomToTop(), replaceLoopPHINodesWithPreheaderValues(), llvm::replaceSignedInst(), llvm::Value::replaceUsesWithIf(), rewrite(), rewriteAccessChain(), llvm::SSAUpdaterBulk::RewriteAllUses(), rewriteDebugUsers(), rollbackRestoreSplit(), llvm::MemDerefPrinterPass::run(), llvm::LoopFullUnrollPass::run(), llvm::OpenMPOptPass::run(), llvm::HipStdParAcceleratorCodeSelectionPass::run(), runImpl(), llvm::JumpThreadingPass::runImpl(), runMoveAutoInit(), llvm::SPIRVMergeRegionExitTargets::runOnConvergenceRegionNoRecurse(), llvm::LoopVectorizationCostModel::setCostBasedWideningDecision(), llvm::MCAssembler::setIsThumbFunc(), llvm::DbgVariableRecord::setKillLocation(), llvm::DbgVariableIntrinsic::setKillLocation(), setLoopComponents(), llvm::AbstractDependenceGraphBuilder< GraphType >::simplify(), simplifyLoopInst(), simplifyOneLoop(), llvm::JumpThreadingPass::simplifyPartiallyRedundantLoad(), sink(), SinkCommonCodeFromPredecessors(), sinkInstruction(), sinkLifetimeStartMarkers(), sinkRecurrenceUsersAfterPrevious(), llvm::LoopNest::skipEmptyBlockUntil(), llvm::InstCombinerImpl::SliceUpIllegalIntegerPHI(), llvm::SmallPtrSet< PtrType, SmallSize >::SmallPtrSet(), SoleWriteToDeadLocal(), sortOpts(), llvm::SplitBlockAndInsertIfThenElse(), llvm::splitBlockBefore(), SplitBlockImpl(), SRAGlobal(), stripDebugLocFromLoopID(), StripPointerGEPsAndCasts(), SwitchToLookupTable(), llvm::IVStrideUse::transformToPostInc(), tryInterleave(), tryToElideArgumentCopy(), llvm::TryToSimplifyUncondBranchFromEmptyBlock(), llvm::InstCombinerImpl::tryToSinkInstructionDbgVariableRecords(), tryToSplitRestore(), llvm::UnrollAndJamLoop(), unswitchAllTrivialConditions(), unswitchTrivialSwitch(), UpdateAnalysisInformation(), updateCallerBFI(), updateCGAndAnalysisManagerForPass(), updateForAIXShLibTLSModelOpt(), updateLiveness(), updatePredecessorProfileMetadata(), UpdateSSA(), usersDominator(), llvm::PeelingModuloScheduleExpander::validateAgainstModuloScheduleExpander(), ValidateMVEStore(), valueIsOnlyUsedLocallyOrStoredToOneGlobal(), llvm::ScalarEvolution::verify(), llvm::AssumptionCacheTracker::verifyAnalysis(), visitDomSubTree(), llvm::InstCombinerImpl::visitLandingPadInst(), llvm::InstCombinerImpl::visitPHINode(), visitPointers(), llvm::LazyCallGraph::visitReferences(), llvm::TBAAVerifier::visitTBAAMetadata(), llvm::yaml::WebAssemblyFunctionInfo::WebAssemblyFunctionInfo(), llvm::VirtRegAuxInfo::weightCalcHelper(), llvm::PredicateInfo::~PredicateInfo(), and llvm::VPInterleavedAccessInfo::~VPInterleavedAccessInfo().
|
inline |
Definition at line 428 of file SmallPtrSet.h.
References llvm::SmallPtrSetImpl< PtrType >::insert().
|
inline |
Remove elements that match the given predicate.
This method is a safe replacement for the following pattern, which is not valid, because the erase() calls would invalidate the iterator:
for (PtrType *Ptr : Set) if (Pred(P)) Set.erase(P);
Returns whether anything was removed. It is safe to read the set inside the predicate function. However, the predicate must not modify the set itself, only indicate a removal by returning true.
Definition at line 378 of file SmallPtrSet.h.
References llvm::SmallPtrSetImplBase::CurArray, E, llvm::SmallPtrSetImplBase::EndPointer(), llvm::SmallPtrSetImplBase::getEmptyMarker(), llvm::SmallPtrSetImplBase::getTombstoneMarker(), llvm::DebugEpochBase::incrementEpoch(), llvm::SmallPtrSetImplBase::isSmall(), llvm::SmallPtrSetImplBase::NumNonEmpty, llvm::SmallPtrSetImplBase::NumTombstones, P, Ptr, and llvm::SmallPtrSetImplBase::SmallArray.
|
protected |
Definition at line 71 of file SmallPtrSet.cpp.
|
inlineexplicitprotected |
Definition at line 76 of file SmallPtrSet.h.
|
protected |
Definition at line 73 of file SmallPtrSet.cpp.