souffle
2.0.2-371-g6315b36
|
Class for SIPS cost-metric functions Each subclass represents a different heuristic used for evaluating the cost of choosing an atom next in the schedule. More...
#include <SipsMetric.h>
Public Member Functions | |
std::vector< unsigned int > | getReordering (const Clause *clause) const |
Determines the new ordering of a clause after the SIPS is applied. More... | |
virtual | ~SipsMetric ()=default |
Static Public Member Functions | |
static std::unique_ptr< SipsMetric > | create (const std::string &heuristic, const TranslationUnit &tu) |
Create a SIPS metric based on a given heuristic. More... | |
Protected Member Functions | |
virtual std::vector< double > | evaluateCosts (const std::vector< Atom * > atoms, const BindingStore &bindingStore) const =0 |
Evaluates the cost of choosing each atom next in the current schedule. More... | |
Class for SIPS cost-metric functions Each subclass represents a different heuristic used for evaluating the cost of choosing an atom next in the schedule.
Definition at line 39 of file SipsMetric.h.
|
virtualdefault |
|
static |
Create a SIPS metric based on a given heuristic.
Definition at line 68 of file SipsMetric.cpp.
|
protectedpure virtual |
Evaluates the cost of choosing each atom next in the current schedule.
atoms | atoms to choose from; may be nullptr |
bindingStore | the variables already bound to a value |
Implemented in souffle::ast::DeltaInputSips, souffle::ast::InputSips, souffle::ast::DeltaSips, souffle::ast::ProfileUseSips, souffle::ast::LeastFreeVarsSips, souffle::ast::LeastFreeSips, souffle::ast::MaxRatioSips, souffle::ast::MaxBoundSips, souffle::ast::NaiveSips, souffle::ast::AllBoundSips, and souffle::ast::StrictSips.
Referenced by getReordering().
std::vector< unsigned int > souffle::ast::SipsMetric::getReordering | ( | const Clause * | clause | ) | const |
Determines the new ordering of a clause after the SIPS is applied.
clause | clause to reorder |
Definition at line 39 of file SipsMetric.cpp.
References evaluateCosts().