decompiler  1.0.0
Public Member Functions | List of all members
ghidra::Widener Class Referenceabstract

Class holding a particular widening strategy for the ValueSetSolver iteration algorithm. More...

#include <rangeutil.hh>

Inheritance diagram for ghidra::Widener:
ghidra::WidenerFull ghidra::WidenerNone

Public Member Functions

virtual ~Widener (void)
 Destructor.
 
virtual int4 determineIterationReset (const ValueSet &valueSet)=0
 Upon entering a fresh partition, determine how the given ValueSet count should be reset. More...
 
virtual bool checkFreeze (const ValueSet &valueSet)=0
 Check if the given value set has been frozen for the remainder of the iteration process. More...
 
virtual bool doWidening (const ValueSet &valueSet, CircleRange &range, const CircleRange &newRange)=0
 For an iteration that isn't stabilizing attempt to widen the given ValueSet. More...
 

Detailed Description

Class holding a particular widening strategy for the ValueSetSolver iteration algorithm.

This obects gets to decide when a value set gets frozen (checkFreeze()), meaning the set doesn't change for the remaining iteration steps. It also gets to decide when and by how much value sets get artificially increased in size to accelerate reaching their stable state (doWidening()).

Member Function Documentation

◆ checkFreeze()

virtual bool ghidra::Widener::checkFreeze ( const ValueSet valueSet)
pure virtual

Check if the given value set has been frozen for the remainder of the iteration process.

Parameters
valueSetis the given value set
Returns
true if the valueSet will no longer change

Implemented in ghidra::WidenerNone, and ghidra::WidenerFull.

Referenced by ghidra::ValueSet::iterate().

◆ determineIterationReset()

virtual int4 ghidra::Widener::determineIterationReset ( const ValueSet valueSet)
pure virtual

Upon entering a fresh partition, determine how the given ValueSet count should be reset.

Parameters
valueSetis the given value set
Returns
the value of the iteration counter to reset to

Implemented in ghidra::WidenerNone, and ghidra::WidenerFull.

Referenced by ghidra::ValueSetSolver::solve().

◆ doWidening()

virtual bool ghidra::Widener::doWidening ( const ValueSet valueSet,
CircleRange range,
const CircleRange newRange 
)
pure virtual

For an iteration that isn't stabilizing attempt to widen the given ValueSet.

Change the given range based on its previous iteration so that it stabilizes more rapidly on future iterations.

Parameters
valueSetis the given value set
rangeis the previous form of the given range (and storage for the widening result)
newRangeis the current iteration of the given range
Returns
true if widening succeeded

Implemented in ghidra::WidenerNone, and ghidra::WidenerFull.

Referenced by ghidra::ValueSet::iterate().


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