This class defines a few utility functions common to DDD.
More...
#include <MemoryManager.h>
|
static unsigned int | nbDDD () |
| Returns the size of the unicity table for DDD. More...
|
|
static unsigned int | nbDED () |
| Returns the size of the cache unicity table for DDD. More...
|
|
static unsigned int | nbHom () |
| Returns the size of the unicity table for DDD Homomorphisms. More...
|
|
static unsigned int | nbSDD () |
| Returns the size of the unicity table for SDD. More...
|
|
static unsigned int | nbSDED () |
| Returns the size of the cache unicity table for SDD. More...
|
|
static unsigned int | nbShom () |
| Returns the size of the unicity table for SDD Homomorphisms. More...
|
|
static void | mark (const GDDD &g) |
| Convenience function to mark a node as non collectible. More...
|
|
static void | mark (const GHom &h) |
| Convenience function to mark a Hom as non collectible. More...
|
|
static bool | should_garbage () |
| tester for memory management routine triggering in a top level fixpoint More...
|
|
static void | garbage () |
| Garbage collection function. More...
|
|
static void | pstats (bool reinit=true) |
| Prints some statistics about use of unicity tables, also reinitializes peak sizes. More...
|
|
static void | setGCThreshold (size_t nbKbyte) |
|
static size_t | getPeakMemory () |
|
static void | addHook (GCHook *hook) |
|
This class defines a few utility functions common to DDD.
Note that all functions are declared static, so this is more of a namespace than a class. One important function is garbage(), only this MemoryManager::garbage() should be caled : avoid GHom::garbage(), DED::garbage(), GDDD::garbage() (and SDD versions of the same, they should not be called directly.
◆ hooks_it
◆ hooks_t
◆ addHook()
static void MemoryManager::addHook |
( |
GCHook * |
hook | ) |
|
|
inlinestatic |
◆ garbage()
static void MemoryManager::garbage |
( |
| ) |
|
|
inlinestatic |
Garbage collection function.
Call this to reclaim intermediate nodes, unused operations and related cache. Note that this function is quite costly, and it totally destroys the cache
References GDDD::garbage(), DED::garbage(), GHom::garbage(), IntDataSet::garbage(), MLHom::garbage(), GSDD::garbage(), SDED::garbage(), GShom::garbage(), and hooks_.
Referenced by Fixpoint::eval(), and sns::Fixpoint::eval().
◆ getPeakMemory()
static size_t MemoryManager::getPeakMemory |
( |
| ) |
|
|
inlinestatic |
◆ mark() [1/2]
static void MemoryManager::mark |
( |
const GDDD & |
g | ) |
|
|
inlinestatic |
Convenience function to mark a node as non collectible.
- Todo:
- : track usage and check whether this is useful, SDD version undefined.
References GDDD::mark().
◆ mark() [2/2]
static void MemoryManager::mark |
( |
const GHom & |
h | ) |
|
|
inlinestatic |
Convenience function to mark a Hom as non collectible.
- Todo:
- : track usage and check whether this is useful, SDD version undefined.
References GHom::mark().
◆ nbDDD()
static unsigned int MemoryManager::nbDDD |
( |
| ) |
|
|
inlinestatic |
◆ nbDED()
static unsigned int MemoryManager::nbDED |
( |
| ) |
|
|
inlinestatic |
◆ nbHom()
static unsigned int MemoryManager::nbHom |
( |
| ) |
|
|
inlinestatic |
◆ nbSDD()
static unsigned int MemoryManager::nbSDD |
( |
| ) |
|
|
inlinestatic |
◆ nbSDED()
static unsigned int MemoryManager::nbSDED |
( |
| ) |
|
|
inlinestatic |
◆ nbShom()
static unsigned int MemoryManager::nbShom |
( |
| ) |
|
|
inlinestatic |
◆ pstats()
static void MemoryManager::pstats |
( |
bool |
reinit = true | ) |
|
|
inlinestatic |
◆ setGCThreshold()
static void MemoryManager::setGCThreshold |
( |
size_t |
nbKbyte | ) |
|
|
inlinestatic |
◆ should_garbage()
static bool MemoryManager::should_garbage |
( |
| ) |
|
|
inlinestatic |
◆ hooks_
◆ last_mem
size_t MemoryManager::last_mem = 1300000 |
|
staticprivate |
The documentation for this class was generated from the following files: