DDD
1.9.0.20240826145154
|
Public Types | |
typedef std::set< GHom > | param_t |
typedef param_t::const_iterator | param_it |
typedef std::pair< GHom, param_t > | partition |
typedef std::map< int, partition > | partition_cache_type |
Public Member Functions | |
Monotonic (const std::set< GHom > ¶m, int ref=0) | |
param_t & | get_parameters () |
const GHom::range_t | get_range () const |
The range returns the dual of skip_variable, default implem considers that all variables are affected by this homomorphism. More... | |
partition | get_partition (int var) |
GHom | invert (const GDDD &pot) const |
returns the predescessor homomorphism, using pot to determine variable domains More... | |
bool | operator== (const _GHom &h) const |
Comparator. More... | |
size_t | hash () const |
Hash key computation. More... | |
bool | is_selector () const |
The isSelector predicate indicates a homomorphism that only selects paths in the SDD (no modifications, no additions) Tagging with isSelector() allows to enable optimizations and makes the homomorphism eligible as "condition" in ITE construct. More... | |
_GHom * | clone () const |
bool | skip_variable (int var) const |
The skip_variable predicate indicates which variables are "don't care" with respect to this SHom. More... | |
GDDD | eval (const GDDD &d) const |
The computation function responsible for evaluation over a node. More... | |
void | mark () const |
For garbage collection. Used in first phase of garbage collection. More... | |
void | print (std::ostream &os) const |
GDDD | has_image_skip (const GDDD &) const |
bool | operator< (const _GHom &h) const |
Ordering between _GHom. It is the chronological ordering of creation. More... | |
virtual GDDD | has_image (const GDDD &) const |
virtual GHom | negate () const |
returns a negation of a selector homomorphism h, such that h.negate() (d) = d - h(d) More... | |
virtual GHom | compose (const GHom &r) const |
Static Public Member Functions | |
static const _GHom * | get_concret (const GHom &ghom) |
Private Member Functions | |
GDDD | eval_skip (const GDDD &) const |
Private Attributes | |
param_t | parameters |
partition_cache_type | partition_cache |
int | refCounter |
For garbage collection. More... | |
bool | marking |
For garbage collection. More... | |
bool | immediat |
For operation cache management. More... | |
size_t | creation_counter |
Counter of objects created (see constructors). More... | |
typedef param_t::const_iterator Monotonic::param_it |
typedef std::set<GHom> Monotonic::param_t |
typedef std::pair< GHom , param_t > Monotonic::partition |
typedef std::map<int,partition> Monotonic::partition_cache_type |
|
inlinevirtual |
Implements _GHom.
References Monotonic().
Reimplemented in _VarCompVar, and _VarCompState.
References GHom::id, and GDDD::null.
Referenced by _VarCompState::compose(), _VarCompVar::compose(), and GHom::compose().
The computation function responsible for evaluation over a node.
Users should not directly use this. Normal behavior is to use GShom::operator() that encapsulates this call with operation caching.
Implements _GHom.
References GDDD::null, GDDD::one, partition_cache, skip_variable(), GDDD::top, and GDDD::variable().
References GDDD::begin(), GDDD::end(), _GHom::eval(), GHom::id, GDDD::null, GDDD::one, _GHom::skip_variable(), GDDD::top, and GDDD::variable().
Referenced by GHom::eval().
References GHom::concret.
Referenced by Add::Add(), addCompositionParameter(), _VarCompState::compose(), _VarCompVar::compose(), And::eval(), Fixpoint::eval(), Fixpoint::has_image(), Inter::skip_variable(), NotCond::skip_variable(), Add::skip_variable(), skip_variable(), Compose::skip_variable(), RightConcat::skip_variable(), and Fixpoint::skip_variable().
|
inline |
References parameters.
|
inline |
References partition_cache, and skip_variable().
|
inlinevirtual |
The range returns the dual of skip_variable, default implem considers that all variables are affected by this homomorphism.
Reimplemented from _GHom.
References parameters.
Reimplemented in Fixpoint, RightConcat, LeftConcat, And, Add, NotCond, Inter, Identity, and StrongHom.
References _GHom::GHom.
Referenced by Inter::has_image(), And::has_image(), Fixpoint::has_image(), and _GHom::has_image_skip().
References GDDD::begin(), GDDD::end(), _GHom::has_image(), GHom::has_image(), GHom::id, GDDD::null, GDDD::one, _GHom::skip_variable(), GDDD::top, and GDDD::variable().
|
inlinevirtual |
Hash key computation.
It is essential for good hash table operation that the spread of the keys be as good as possible. Also, fast hash key computation is a good design goal. Note that bad hash functions will yield more collisions, thus equality comparisons which may be quite costly.
Implements _GHom.
References parameters.
returns the predescessor homomorphism, using pot to determine variable domains
Reimplemented from _GHom.
|
inlinevirtual |
|
inlinevirtual |
For garbage collection. Used in first phase of garbage collection.
Reimplemented from _GHom.
References parameters, and partition_cache.
|
virtualinherited |
returns a negation of a selector homomorphism h, such that h.negate() (d) = d - h(d)
Reimplemented in _VarCompState, And, Add, NotCond, Inter, Constant, and Identity.
References _GHom::GHom.
Referenced by GHom::negate().
|
inherited |
Ordering between _GHom. It is the chronological ordering of creation.
References _GHom::creation_counter.
|
inlinevirtual |
Comparator.
Used in case of hash collision. Should be appropriately defined in derived classes, in particular in user defined homomorphisms.
Implements _GHom.
References parameters.
|
inlinevirtual |
Implements _GHom.
References parameters.
|
inlinevirtual |
The skip_variable predicate indicates which variables are "don't care" with respect to this SHom.
This is defined as a StrongHom with : phi(var,val) { if ( skip_variable(var) ) return GShom( var, val, this ); else { real behavior } }
Reimplemented from _GHom.
References _GHom::get_concret(), monotonic(), parameters, partition_cache, and _GHom::skip_variable().
Referenced by eval(), and get_partition().
|
privateinherited |
Counter of objects created (see constructors).
This is used for the ordering between homomorphisms.
Referenced by _GHom::_GHom(), and _GHom::operator<().
|
mutableprivateinherited |
For operation cache management.
If immediat==true, eval is called without attempting a cache hit. Currently only the constant homomorphism has this attribute set to true.
Referenced by GHom::operator()().
|
mutableprivateinherited |
For garbage collection.
Used in the two phase garbage collection process. A Hom that is not marked after the first pass over the unicity table, will be sweeped in the second phase. Outside of garbage collection routine, marking should always bear the value false.
Referenced by GHom::garbage(), and GHom::mark().
|
private |
Referenced by get_parameters(), get_range(), hash(), mark(), operator==(), print(), and skip_variable().
|
mutableprivate |
Referenced by eval(), get_partition(), mark(), and skip_variable().
|
mutableprivateinherited |
For garbage collection.
Counts the number of times a _GShom is referenced from the context of an Shom.
Referenced by Hom::Hom(), Hom::operator=(), GHom::refCounter(), and Hom::~Hom().