LLVM  4.0.0
Public Member Functions | Static Public Member Functions | List of all members
llvm::SCEVEqualPredicate Class Referencefinal

This class represents an assumption that two SCEV expressions are equal, and this can be checked at run-time. More...

#include <ScalarEvolution.h>

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

Public Member Functions

 SCEVEqualPredicate (const FoldingSetNodeIDRef ID, const SCEVUnknown *LHS, const SCEVConstant *RHS)
 
bool implies (const SCEVPredicate *N) const override
 Implementation of the SCEVPredicate interface. More...
 
void print (raw_ostream &OS, unsigned Depth=0) const override
 Prints a textual representation of this predicate with an indentation of Depth. More...
 
bool isAlwaysTrue () const override
 Returns true if the predicate is always true. More...
 
const SCEVgetExpr () const override
 Returns the SCEV to which this predicate applies, or nullptr if this is a SCEVUnionPredicate. More...
 
const SCEVUnknowngetLHS () const
 Returns the left hand side of the equality. More...
 
const SCEVConstantgetRHS () const
 Returns the right hand side of the equality. More...
 
- Public Member Functions inherited from llvm::SCEVPredicate
 SCEVPredicate (const FoldingSetNodeIDRef ID, SCEVPredicateKind Kind)
 SCEV predicates. More...
 
SCEVPredicateKind getKind () const
 
virtual unsigned getComplexity () const
 Returns the estimated complexity of this predicate. More...
 
- Public Member Functions inherited from llvm::FoldingSetImpl::Node
 Node ()
 
void * getNextInBucket () const
 
void SetNextInBucket (void *N)
 

Static Public Member Functions

static bool classof (const SCEVPredicate *P)
 Methods for support type inquiry through isa, cast, and dyn_cast: More...
 

Additional Inherited Members

- Public Types inherited from llvm::SCEVPredicate
enum  SCEVPredicateKind { P_Union, P_Equal, P_Wrap }
 
- Protected Member Functions inherited from llvm::SCEVPredicate
 ~SCEVPredicate ()=default
 
 SCEVPredicate (const SCEVPredicate &)=default
 
SCEVPredicateoperator= (const SCEVPredicate &)=default
 
- Protected Attributes inherited from llvm::SCEVPredicate
SCEVPredicateKind Kind
 

Detailed Description

This class represents an assumption that two SCEV expressions are equal, and this can be checked at run-time.

We assume that the left hand side is a SCEVUnknown and the right hand side a constant.

Definition at line 242 of file ScalarEvolution.h.

Constructor & Destructor Documentation

SCEVEqualPredicate::SCEVEqualPredicate ( const FoldingSetNodeIDRef  ID,
const SCEVUnknown LHS,
const SCEVConstant RHS 
)

Definition at line 10250 of file ScalarEvolution.cpp.

Member Function Documentation

static bool llvm::SCEVEqualPredicate::classof ( const SCEVPredicate P)
inlinestatic

Methods for support type inquiry through isa, cast, and dyn_cast:

Definition at line 265 of file ScalarEvolution.h.

References llvm::SCEVPredicate::getKind(), and llvm::SCEVPredicate::P_Equal.

const SCEV * SCEVEqualPredicate::getExpr ( ) const
overridevirtual

Returns the SCEV to which this predicate applies, or nullptr if this is a SCEVUnionPredicate.

Implements llvm::SCEVPredicate.

Definition at line 10266 of file ScalarEvolution.cpp.

const SCEVUnknown* llvm::SCEVEqualPredicate::getLHS ( ) const
inline

Returns the left hand side of the equality.

Definition at line 259 of file ScalarEvolution.h.

Referenced by llvm::SCEVExpander::expandEqualPredicate().

const SCEVConstant* llvm::SCEVEqualPredicate::getRHS ( ) const
inline

Returns the right hand side of the equality.

Definition at line 262 of file ScalarEvolution.h.

Referenced by llvm::SCEVExpander::expandEqualPredicate().

bool SCEVEqualPredicate::implies ( const SCEVPredicate N) const
overridevirtual

Implementation of the SCEVPredicate interface.

Implements llvm::SCEVPredicate.

Definition at line 10255 of file ScalarEvolution.cpp.

References llvm::dyn_cast(), and N.

bool SCEVEqualPredicate::isAlwaysTrue ( ) const
overridevirtual

Returns true if the predicate is always true.

This means that no assumptions were made and nothing needs to be checked at run-time.

Implements llvm::SCEVPredicate.

Definition at line 10264 of file ScalarEvolution.cpp.

void SCEVEqualPredicate::print ( raw_ostream OS,
unsigned  Depth = 0 
) const
overridevirtual

Prints a textual representation of this predicate with an indentation of Depth.

Implements llvm::SCEVPredicate.

Definition at line 10268 of file ScalarEvolution.cpp.

References llvm::raw_ostream::indent().


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