LLVM: llvm::GenericCycle< ContextT > Class Template Reference (original) (raw)

A possibly irreducible generalization of a Loop. More...

#include "[llvm/ADT/GenericCycleInfo.h](GenericCycleInfo%5F8h%5Fsource.html)"

Public Types
using BlockT = typename ContextT::BlockT
using FunctionT = typename ContextT::FunctionT
using const_child_iterator_base
Iteration over child cycles.
using const_block_iterator = typename BlockSetVectorT::const_iterator
Iteration over blocks in the cycle (including entry blocks).
using const_entry_iterator
Iteration over entry blocks.
using const_reverse_entry_iterator
Public Member Functions
GenericCycle ()=default
bool isReducible () const
Whether the cycle is a natural loop.
BlockT * getHeader () const
const SmallVectorImpl< BlockT * > & getEntries () const
void clearCache () const
Clear the cache of the cycle.
bool isEntry (const BlockT *Block) const
Return whether Block is an entry block of the cycle.
void setSingleEntry (BlockT *Block)
Replace all entries with Block as single entry.
bool contains (const BlockT *Block) const
Return whether Block is contained in the cycle.
bool contains (const GenericCycle *C) const
Returns true iff this cycle contains C.
const GenericCycle * getParentCycle () const
GenericCycle * getParentCycle ()
unsigned getDepth () const
void getExitBlocks (SmallVectorImpl< BlockT * > &TmpStorage) const
Return all of the successor blocks of this cycle.
void getExitingBlocks (SmallVectorImpl< BlockT * > &TmpStorage) const
Return all blocks of this cycle that have successor outside of this cycle.
BlockT * getCyclePreheader () const
Return the preheader block for this cycle.
BlockT * getCyclePredecessor () const
If the cycle has exactly one entry with exactly one predecessor, return it, otherwise return nullptr.
void verifyCycle () const
Verify that this is actually a well-formed cycle in the CFG.
void verifyCycleNest () const
Verify the parent-child relations of this cycle.
const_child_iterator child_begin () const
const_child_iterator child_end () const
size_t getNumChildren () const
iterator_range< const_child_iterator > children () const
const_block_iterator block_begin () const
const_block_iterator block_end () const
size_t getNumBlocks () const
iterator_range< const_block_iterator > blocks () const
const_entry_iterator entry_begin () const
const_entry_iterator entry_end () const
size_t getNumEntries () const
iterator_range< const_entry_iterator > entries () const
const_reverse_entry_iterator entry_rbegin () const
const_reverse_entry_iterator entry_rend () const
Printable printEntries (const ContextT &Ctx) const
Printable print (const ContextT &Ctx) const
Friends
template
class GenericCycleInfo
template
class GenericCycleInfoCompute

template
class llvm::GenericCycle< ContextT >

A possibly irreducible generalization of a Loop.

Definition at line 44 of file GenericCycleInfo.h.

BlockT

template

const_block_iterator

template

Iteration over blocks in the cycle (including entry blocks).

Definition at line 201 of file GenericCycleInfo.h.

const_child_iterator_base

template

const_entry_iterator

template

Initial value:

typename SuperClass::const_iterator const_iterator

Iteration over entry blocks.

Definition at line 217 of file GenericCycleInfo.h.

const_reverse_entry_iterator

template

Initial value:

std::reverse_iterator< const_iterator > const_reverse_iterator

Definition at line 225 of file GenericCycleInfo.h.

FunctionT

template

template

block_begin()

template

block_end()

template

blocks()

template

child_begin()

template

child_end()

template

children()

template

clearCache()

template

contains() [1/2]

template

contains() [2/2]

entries()

template

entry_begin()

template

entry_end()

template

entry_rbegin()

template

entry_rend()

template

getCyclePredecessor()

template

auto llvm::GenericCycle< ContextT >::getCyclePredecessor ( ) const

getCyclePreheader()

template

auto llvm::GenericCycle< ContextT >::getCyclePreheader ( ) const

getDepth()

template

getEntries()

template

getExitBlocks()

Return all of the successor blocks of this cycle.

These are the blocks outside of the current cycle which are branched to.

Definition at line 48 of file GenericCycleImpl.h.

References llvm::append_range(), llvm::SmallVectorTemplateCommon< T, typename >::begin(), llvm::Block, blocks, llvm::SmallVectorImpl< T >::clear(), contains(), llvm::SmallVectorTemplateCommon< T, typename >::end(), llvm::SmallVectorImpl< T >::resize(), llvm::SmallVectorTemplateCommon< T, typename >::size(), and llvm::successors().

Referenced by verifyCycle().

getExitingBlocks()

getHeader()

template

getNumBlocks()

template

getNumChildren()

template

getNumEntries()

template

getParentCycle() [1/2]

template

getParentCycle() [2/2]

template

isEntry()

template

isReducible()

template

print()

template

printEntries()

template

setSingleEntry()

template

verifyCycle()

Verify that this is actually a well-formed cycle in the CFG.

Definition at line 130 of file GenericCycleImpl.h.

References llvm::any_of(), assert(), B(), llvm::SmallVectorTemplateCommon< T, typename >::begin(), blocks, llvm::children(), contains(), llvm::SmallPtrSetImpl< PtrType >::count(), llvm::dbgs(), llvm::depth_first(), llvm::depth_first_ext(), llvm::SmallVectorTemplateCommon< T, typename >::end(), entries(), getExitBlocks(), getHeader(), getNumBlocks(), getParent(), llvm::detail::DenseSetImpl< ValueT, MapTy, ValueInfoT >::insert(), llvm::df_iterator_default_set< NodeRef, SmallSize >::insert(), llvm::SmallPtrSetImpl< PtrType >::insert(), llvm::inverse_children(), llvm_unreachable, llvm::SmallPtrSetImplBase::size(), and verifyCycleNest().

verifyCycleNest()

template

void llvm::GenericCycle< ContextT >::verifyCycleNest ( ) const

GenericCycleInfo

template

template

GenericCycleInfoCompute

template

template


The documentation for this class was generated from the following files: