Painless
A framework to ease parallelization of sequential CDCL SAT solvers
Loading...
Searching...
No Matches
SharingStrategyFactory Struct Reference

Factory class for creating and managing sharing strategies. More...

#include <SharingStrategyFactory.hpp>

Collaboration diagram for SharingStrategyFactory:

Static Public Member Functions

static void instantiateLocalStrategies (int strategyNumber, std::vector< std::shared_ptr< SharingStrategy > > &localStrategies, std::vector< std::shared_ptr< SolverCdclInterface > > &cdclSolvers)
 Instantiate local sharing strategies.
 
static void instantiateGlobalStrategies (int strategyNumber, std::vector< std::shared_ptr< GlobalSharingStrategy > > &globalStrategies)
 Instantiate global sharing strategies.
 
static void launchSharers (std::vector< std::shared_ptr< SharingStrategy > > &sharingStrategies, std::vector< std::unique_ptr< Sharer > > &sharers)
 Launch sharer threads for the given sharing strategies.
 
static void addEntitiesToLocal (std::vector< std::shared_ptr< SharingStrategy > > &localStrategies, std::vector< std::shared_ptr< SolverCdclInterface > > &newSolvers)
 Add new entities (solvers) to existing local strategies.
 

Static Public Attributes

static int selectedLocal
 The selected local sharing strategy number.
 
static int selectedGlobal
 The selected global sharing strategy number.
 

Detailed Description

Factory class for creating and managing sharing strategies.

Member Function Documentation

◆ addEntitiesToLocal()

static void SharingStrategyFactory::addEntitiesToLocal ( std::vector< std::shared_ptr< SharingStrategy > > & localStrategies,
std::vector< std::shared_ptr< SolverCdclInterface > > & newSolvers )
static

Add new entities (solvers) to existing local strategies.

Parameters
localStrategiesVector of existing local strategies.
newSolversVector of new CDCL solvers to be added.

◆ instantiateGlobalStrategies()

static void SharingStrategyFactory::instantiateGlobalStrategies ( int strategyNumber,
std::vector< std::shared_ptr< GlobalSharingStrategy > > & globalStrategies )
static

Instantiate global sharing strategies.

Parameters
strategyNumberThe number of the strategy to instantiate.
globalStrategiesVector to store the created global strategies.

◆ instantiateLocalStrategies()

static void SharingStrategyFactory::instantiateLocalStrategies ( int strategyNumber,
std::vector< std::shared_ptr< SharingStrategy > > & localStrategies,
std::vector< std::shared_ptr< SolverCdclInterface > > & cdclSolvers )
static

Instantiate local sharing strategies.

Parameters
strategyNumberThe number of the strategy to instantiate.
localStrategiesVector to store the created local strategies.
cdclSolversVector of CDCL solvers to be used in the strategies.

◆ launchSharers()

static void SharingStrategyFactory::launchSharers ( std::vector< std::shared_ptr< SharingStrategy > > & sharingStrategies,
std::vector< std::unique_ptr< Sharer > > & sharers )
static

Launch sharer threads for the given sharing strategies.

Parameters
sharingStrategiesVector of sharing strategies to be executed.
sharersVector to store the created sharer objects.

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