LLVM  10.0.0
Classes | Public Member Functions | Friends | List of all members
llvm::AliasSet Class Reference

#include "llvm/Analysis/AliasSetTracker.h"

Inheritance diagram for llvm::AliasSet:
[legend]
Collaboration diagram for llvm::AliasSet:
[legend]

Classes

class  iterator
 Define an iterator for alias sets... this is just a forward iterator. More...
 

Public Member Functions

 AliasSet (const AliasSet &)=delete
 
AliasSet & operator= (const AliasSet &)=delete
 
bool isRef () const
 Accessors... More...
 
bool isMod () const
 
bool isMustAlias () const
 
bool isMayAlias () const
 
bool isForwardingAliasSet () const
 Return true if this alias set should be ignored as part of the AliasSetTracker object. More...
 
void mergeSetIn (AliasSet &AS, AliasSetTracker &AST)
 Merge the specified alias set into this alias set. More...
 
iterator begin () const
 
iterator end () const
 
bool empty () const
 
unsigned size ()
 
Instruction * getUniqueInstruction ()
 If this alias set is known to contain a single instruction and only a single unique instruction, return it. More...
 
void print (raw_ostream &OS) const
 
void dump () const
 
AliasResult aliasesPointer (const Value *Ptr, LocationSize Size, const AAMDNodes &AAInfo, AliasAnalysis &AA) const
 If the specified pointer "may" (or must) alias one of the members in the set return the appropriate AliasResult. More...
 
bool aliasesUnknownInst (const Instruction *Inst, AliasAnalysis &AA) const
 
- Public Member Functions inherited from llvm::ilist_node_impl< ilist_detail::compute_node_options< AliasSet, Options... >::type >
self_iterator getIterator ()
 
const_self_iterator getIterator () const
 
reverse_self_iterator getReverseIterator ()
 
const_reverse_self_iterator getReverseIterator () const
 
bool isSentinel () const
 Check whether this is the sentinel node. More...
 

Friends

class AliasSetTracker
 

Additional Inherited Members

- Protected Types inherited from llvm::ilist_node_impl< ilist_detail::compute_node_options< AliasSet, Options... >::type >
using self_iterator = ilist_iterator< ilist_detail::compute_node_options< AliasSet, Options... >::type, false, false >
 
using const_self_iterator = ilist_iterator< ilist_detail::compute_node_options< AliasSet, Options... >::type, false, true >
 
using reverse_self_iterator = ilist_iterator< ilist_detail::compute_node_options< AliasSet, Options... >::type, true, false >
 
using const_reverse_self_iterator = ilist_iterator< ilist_detail::compute_node_options< AliasSet, Options... >::type, true, true >
 
- Protected Member Functions inherited from llvm::ilist_node_impl< ilist_detail::compute_node_options< AliasSet, Options... >::type >
 ilist_node_impl ()=default
 

Detailed Description

Definition at line 48 of file AliasSetTracker.h.

Constructor & Destructor Documentation

◆ AliasSet()

llvm::AliasSet::AliasSet ( const AliasSet &  )
delete

Member Function Documentation

◆ aliasesPointer()

AliasResult AliasSet::aliasesPointer ( const Value *  Ptr,
LocationSize  Size,
const AAMDNodes &  AAInfo,
AliasAnalysis &  AA 
) const

If the specified pointer "may" (or must) alias one of the members in the set return the appropriate AliasResult.

aliasesPointer - If the specified pointer "may" (or must) alias one of the members in the set return the appropriate AliasResult.

Otherwise return NoAlias.

Definition at line 199 of file AliasSetTracker.cpp.

References llvm::AAResults::alias(), assert(), begin(), llvm::numbers::e, E, end(), llvm::AAResults::getModRefInfo(), I, llvm::isModOrRefSet(), llvm::MayAlias, and llvm::NoAlias.

Referenced by llvm::AliasSet::iterator::operator++().

◆ aliasesUnknownInst()

bool AliasSet::aliasesUnknownInst ( const Instruction *  Inst,
AliasAnalysis &  AA 
) const

◆ begin()

iterator llvm::AliasSet::begin ( ) const
inline

◆ dump()

LLVM_DUMP_METHOD void AliasSet::dump ( ) const

Definition at line 710 of file AliasSetTracker.cpp.

References llvm::dbgs(), and print().

Referenced by llvm::AliasSetTracker::end(), and size().

◆ empty()

bool llvm::AliasSet::empty ( ) const
inline

Definition at line 225 of file AliasSetTracker.h.

Referenced by print().

◆ end()

iterator llvm::AliasSet::end ( ) const
inline

◆ getUniqueInstruction()

Instruction * AliasSet::getUniqueInstruction ( )

If this alias set is known to contain a single instruction and only a single unique instruction, return it.

Otherwise, return nullptr.

Definition at line 264 of file AliasSetTracker.cpp.

References assert(), begin(), end(), llvm::Value::user_begin(), llvm::Value::user_empty(), and llvm::Value::user_end().

Referenced by llvm::canSinkOrHoistInst(), and size().

◆ isForwardingAliasSet()

bool llvm::AliasSet::isForwardingAliasSet ( ) const
inline

Return true if this alias set should be ignored as part of the AliasSetTracker object.

Definition at line 215 of file AliasSetTracker.h.

References mergeSetIn().

◆ isMayAlias()

bool llvm::AliasSet::isMayAlias ( ) const
inline

Definition at line 211 of file AliasSetTracker.h.

◆ isMod()

bool llvm::AliasSet::isMod ( ) const
inline

Definition at line 209 of file AliasSetTracker.h.

Referenced by pointerInvalidatedByLoop().

◆ isMustAlias()

bool llvm::AliasSet::isMustAlias ( ) const
inline

Definition at line 210 of file AliasSetTracker.h.

Referenced by mergeSetIn().

◆ isRef()

bool llvm::AliasSet::isRef ( ) const
inline

Accessors...

Definition at line 208 of file AliasSetTracker.h.

◆ mergeSetIn()

void AliasSet::mergeSetIn ( AliasSet &  AS,
AliasSetTracker &  AST 
)

Merge the specified alias set into this alias set.

mergeSetIn - Merge the specified alias set into this alias set.

Definition at line 53 of file AliasSetTracker.cpp.

References llvm::AAResults::alias(), assert(), llvm::AliasSetTracker::getAliasAnalysis(), isMustAlias(), llvm::MustAlias, llvm::NoAlias, P, Size, size(), and std::swap().

Referenced by llvm::AliasSetTracker::clear(), and isForwardingAliasSet().

◆ operator=()

AliasSet& llvm::AliasSet::operator= ( const AliasSet &  )
delete

◆ print()

void AliasSet::print ( raw_ostream &  OS) const

◆ size()

unsigned llvm::AliasSet::size ( )
inline

Definition at line 229 of file AliasSetTracker.h.

References dump(), getUniqueInstruction(), and print().

Referenced by mergeSetIn().

Friends And Related Function Documentation

◆ AliasSetTracker

friend class AliasSetTracker
friend

Definition at line 49 of file AliasSetTracker.h.

Referenced by llvm::AliasSetTracker::dump().


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