PandA-2024.02
Public Member Functions | Static Public Member Functions | Private Attributes
SymbRange Class Reference

This is an interval that contains a symbolic limit, which is given by the bounds of a program name, e.g. More...

Inheritance diagram for SymbRange:
Inheritance graph
[legend]
Collaboration diagram for SymbRange:
Collaboration graph
[legend]

Public Member Functions

 SymbRange (const RangeConstRef &range, const tree_nodeConstRef &bound, kind pred)
 
 ~SymbRange () override=default
 
 SymbRange (const SymbRange &)=delete
 
 SymbRange (SymbRange &&)=delete
 
SymbRangeoperator= (const SymbRange &)=delete
 
SymbRangeoperator= (SymbRange &&)=delete
 
ValueRangeType getValueId () const override
 
kind getOperation () const
 Returns the opcode of the operation that create this interval. More...
 
const tree_nodeConstRefgetBound () const
 Returns the node which is the bound of this interval. More...
 
RangeConstRef solveFuture (const VarNode *bound, const VarNode *sink) const
 Replace symbolic bound with hard-wired constants. More...
 
void print (std::ostream &OS) const override
 Prints the content of the interval. More...
 
- Public Member Functions inherited from ValueRange
 ValueRange (const RangeConstRef &range)
 
virtual ~ValueRange ()=default
 
 ValueRange (const ValueRange &)=delete
 
 ValueRange (ValueRange &&)=delete
 
ValueRangeoperator= (const ValueRange &)=delete
 
ValueRangeoperator= (ValueRange &&)=delete
 
RangeConstRef getRange () const
 Returns the range of this interval. More...
 
void setRange (const RangeConstRef &newRange)
 Sets the range of this interval to another range. More...
 
std::string ToString () const
 

Static Public Member Functions

static bool classof (SymbRange const *)
 
static bool classof (ValueRange const *BI)
 
- Static Public Member Functions inherited from ValueRange
static bool classof (ValueRange const *)
 

Private Attributes

const tree_nodeConstRef bound
 The bound. It is a node which limits the interval of this range. More...
 
kind pred
 The predicate of the operation in which this interval takes part. More...
 

Detailed Description

This is an interval that contains a symbolic limit, which is given by the bounds of a program name, e.g.

: [-inf, ub(b) + 1].

Definition at line 1605 of file Range_Analysis.cpp.

Constructor & Destructor Documentation

◆ SymbRange() [1/3]

SymbRange::SymbRange ( const RangeConstRef &  range,
const tree_nodeConstRef bound,
kind  pred 
)

Definition at line 1654 of file Range_Analysis.cpp.

◆ ~SymbRange()

SymbRange::~SymbRange ( )
overridedefault

◆ SymbRange() [2/3]

SymbRange::SymbRange ( const SymbRange )
delete

◆ SymbRange() [3/3]

SymbRange::SymbRange ( SymbRange &&  )
delete

Member Function Documentation

◆ classof() [1/2]

static bool SymbRange::classof ( SymbRange const *  )
inlinestatic

Definition at line 1628 of file Range_Analysis.cpp.

◆ classof() [2/2]

static bool SymbRange::classof ( ValueRange const *  BI)
inlinestatic

Definition at line 1632 of file Range_Analysis.cpp.

References ValueRange::getValueId(), and SymbRangeId.

Here is the call graph for this function:

◆ getBound()

const tree_nodeConstRef& SymbRange::getBound ( ) const
inline

Returns the node which is the bound of this interval.

Definition at line 1643 of file Range_Analysis.cpp.

References ValueRange::print().

Referenced by print().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ getOperation()

kind SymbRange::getOperation ( ) const
inline

Returns the opcode of the operation that create this interval.

Definition at line 1638 of file Range_Analysis.cpp.

Referenced by print(), and solveFuture().

Here is the caller graph for this function:

◆ getValueId()

ValueRangeType SymbRange::getValueId ( ) const
inlineoverridevirtual

Reimplemented from ValueRange.

Definition at line 1624 of file Range_Analysis.cpp.

References SymbRangeId.

◆ operator=() [1/2]

SymbRange& SymbRange::operator= ( const SymbRange )
delete

◆ operator=() [2/2]

SymbRange& SymbRange::operator= ( SymbRange &&  )
delete

◆ print()

void SymbRange::print ( std::ostream &  OS) const
overridevirtual

Prints the content of the interval.

Pretty print.

Reimplemented from ValueRange.

Definition at line 1838 of file Range_Analysis.cpp.

References CASE_CPP_NODES, CASE_CST_NODES, CASE_DECL_NODES, CASE_FAKE_NODES, CASE_GIMPLE_NODES, CASE_MISCELLANEOUS, CASE_PRAGMA_NODES, CASE_QUATERNARY_EXPRESSION, CASE_TERNARY_EXPRESSION, CASE_TYPE_NODES, CASE_UNARY_EXPRESSION, getBound(), and getOperation().

Referenced by OpNode::getSink().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ solveFuture()

RangeConstRef SymbRange::solveFuture ( const VarNode bound,
const VarNode sink 
) const

Field Documentation

◆ bound

const tree_nodeConstRef SymbRange::bound
private

The bound. It is a node which limits the interval of this range.

Definition at line 1609 of file Range_Analysis.cpp.

◆ pred

kind SymbRange::pred
private

The predicate of the operation in which this interval takes part.

It is useful to know how we can constrain this interval after we fix the intersects.

Definition at line 1613 of file Range_Analysis.cpp.


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

Generated on Mon Feb 12 2024 13:04:05 for PandA-2024.02 by doxygen 1.8.13