Frobby  0.9.5
Public Member Functions | Protected Member Functions | Private Member Functions | Private Attributes | List of all members
MsmStrategy Class Reference

#include <MsmStrategy.h>

Inheritance diagram for MsmStrategy:
SliceStrategyCommon SliceStrategy OptimizeStrategy

Public Member Functions

 MsmStrategy (TermConsumer *consumer, const SplitStrategy *splitStrategy)
 
 MsmStrategy (TermConsumer *consumer, const SplitStrategy *splitStrategy, const Ideal &initialSubtract)
 
virtual void run (const Ideal &ideal)
 Run the Slice algorithm. More...
 
virtual bool processSlice (TaskEngine &tasks, auto_ptr< Slice > slice)
 Process the parameter slice. More...
 
- Public Member Functions inherited from SliceStrategyCommon
 SliceStrategyCommon (const SplitStrategy *splitStrategy)
 
virtual ~SliceStrategyCommon ()
 
virtual void freeSlice (auto_ptr< Slice > slice)
 It is allowed to delete returned slices directly, but it is better to use freeSlice. More...
 
virtual void setUseIndependence (bool use)
 This method should only be called before calling run(). More...
 
virtual void setUseSimplification (bool use)
 This method should only be called before calling run(). More...
 
- Public Member Functions inherited from SliceStrategy
virtual ~SliceStrategy ()
 

Protected Member Functions

virtual void getPivot (Term &pivot, Slice &slice)
 Used by pivotSplit to obtain a pivot. More...
 
virtual void getPivot (Term &pivot, Slice &slice, const TermGrader &grader)
 
- Protected Member Functions inherited from SliceStrategyCommon
virtual bool simplify (Slice &slice)
 Simplifies slice and returns true if it changed. More...
 
auto_ptr< SlicenewSlice ()
 Returns a slice from the cache that freeSlice adds to, or allocate a new one using allocateSlice. More...
 
virtual void pivotSplit (auto_ptr< Slice > slice)
 Takes over ownership of slice. More...
 
bool getUseIndependence () const
 Returns true if independence splits should be performed when possible. More...
 
bool getUseSimplification () const
 Returns true if slices should be simplified. More...
 

Private Member Functions

auto_ptr< MsmSlicenewMsmSlice ()
 
virtual auto_ptr< SliceallocateSlice ()
 Directly allocate a slice of the correct type using new. More...
 
virtual bool debugIsValidSlice (Slice *slice)
 Check that this slice is valid for use with this strategy. More...
 
void labelSplit (auto_ptr< Slice > slice)
 
void independenceSplit (auto_ptr< Slice > slice)
 
size_t getLabelSplitVariable (const Slice &slice)
 

Private Attributes

IndependenceSplitter _indep
 
TermConsumer_consumer
 
auto_ptr< Ideal_initialSubtract
 

Additional Inherited Members

- Protected Attributes inherited from SliceStrategyCommon
const SplitStrategy_split
 
TaskEngine _tasks
 This keeps track of pending tasks to process. More...
 

Detailed Description

Definition at line 37 of file MsmStrategy.h.

Constructor & Destructor Documentation

◆ MsmStrategy() [1/2]

MsmStrategy::MsmStrategy ( TermConsumer consumer,
const SplitStrategy splitStrategy 
)

Definition at line 28 of file MsmStrategy.cpp.

◆ MsmStrategy() [2/2]

MsmStrategy::MsmStrategy ( TermConsumer consumer,
const SplitStrategy splitStrategy,
const Ideal initialSubtract 
)

Definition at line 36 of file MsmStrategy.cpp.

Member Function Documentation

◆ allocateSlice()

auto_ptr< Slice > MsmStrategy::allocateSlice ( )
privatevirtual

Directly allocate a slice of the correct type using new.

Implements SliceStrategyCommon.

Definition at line 94 of file MsmStrategy.cpp.

◆ debugIsValidSlice()

bool MsmStrategy::debugIsValidSlice ( Slice slice)
privatevirtual

Check that this slice is valid for use with this strategy.

No check need be performed unless DEBUG is defined, making it acceptable to check things using ASSERT. This method should not be called if DEBUG is not defined.

Implements SliceStrategyCommon.

Definition at line 98 of file MsmStrategy.cpp.

◆ getLabelSplitVariable()

size_t MsmStrategy::getLabelSplitVariable ( const Slice slice)
private

◆ getPivot() [1/2]

void MsmStrategy::getPivot ( Term pivot,
Slice slice 
)
protectedvirtual

Used by pivotSplit to obtain a pivot.

Implements SliceStrategyCommon.

Reimplemented in OptimizeStrategy.

Definition at line 286 of file MsmStrategy.cpp.

◆ getPivot() [2/2]

void MsmStrategy::getPivot ( Term pivot,
Slice slice,
const TermGrader grader 
)
protectedvirtual

Definition at line 293 of file MsmStrategy.cpp.

◆ independenceSplit()

void MsmStrategy::independenceSplit ( auto_ptr< Slice slice)
private

Definition at line 259 of file MsmStrategy.cpp.

◆ labelSplit()

void MsmStrategy::labelSplit ( auto_ptr< Slice slice)
private

Definition at line 104 of file MsmStrategy.cpp.

◆ newMsmSlice()

auto_ptr< MsmSlice > MsmStrategy::newMsmSlice ( )
private

Definition at line 88 of file MsmStrategy.cpp.

◆ processSlice()

bool MsmStrategy::processSlice ( TaskEngine tasks,
auto_ptr< Slice slice 
)
virtual

Process the parameter slice.

Returns true if this is a base case and false otherwise.

Implements SliceStrategy.

Definition at line 68 of file MsmStrategy.cpp.

◆ run()

void MsmStrategy::run ( const Ideal ideal)
virtual

Run the Slice algorithm.

Implements SliceStrategy.

Definition at line 45 of file MsmStrategy.cpp.

Member Data Documentation

◆ _consumer

TermConsumer* MsmStrategy::_consumer
private

Definition at line 63 of file MsmStrategy.h.

◆ _indep

IndependenceSplitter MsmStrategy::_indep
private

Definition at line 62 of file MsmStrategy.h.

◆ _initialSubtract

auto_ptr<Ideal> MsmStrategy::_initialSubtract
private

Definition at line 65 of file MsmStrategy.h.


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