WRENCH  1.11
Cyberinfrastructure Simulation Workbench
Overview Installation Getting Started WRENCH 101 WRENCH 102
Static Public Member Functions | List of all members
wrench::ParallelModel Class Reference

A virtual class (with convenient static methods) to define parallel task performance models. More...

#include <ParallelModel.h>

Inheritance diagram for wrench::ParallelModel:
wrench::AmdahlParallelModel wrench::ConstantEfficiencyParallelModel wrench::CustomParallelModel

Static Public Member Functions

static std::shared_ptr< ParallelModelAMDAHL (double alpha)
 Create an instance of an "Amdahl" parallel model. More...
 
static std::shared_ptr< ParallelModelCONSTANTEFFICIENCY (double efficiency)
 Create an instance of a "Constant Efficiency" parallel model. More...
 
static std::shared_ptr< ParallelModelCUSTOM (std::function< std::vector< double >(double, long)> lambda)
 Create an instance of a "Custom" parallel model. More...
 

Detailed Description

A virtual class (with convenient static methods) to define parallel task performance models.

Member Function Documentation

◆ AMDAHL()

std::shared_ptr< ParallelModel > wrench::ParallelModel::AMDAHL ( double  alpha)
static

Create an instance of an "Amdahl" parallel model.

Parameters
alphathe fraction (i.e., a number between 0.0 and 1.0) of the task's work that is perfectly parallelizable. Setting this value to 0 means that the task is purely sequential, and setting it to 1 means that the task is perfectly parallelizable.
Returns
a model instance

◆ CONSTANTEFFICIENCY()

std::shared_ptr< ParallelModel > wrench::ParallelModel::CONSTANTEFFICIENCY ( double  efficiency)
static

Create an instance of a "Constant Efficiency" parallel model.

Parameters
efficiencythe parallel efficiency (which does not depend on the number of threads/cores).
Returns
a model instance

◆ CUSTOM()

std::shared_ptr< ParallelModel > wrench::ParallelModel::CUSTOM ( std::function< std::vector< double >(double, long)>  lambda)
static

Create an instance of a "Custom" parallel model.

Parameters
lambdaa function that, when given a total flop amount and a number of threads, returns a vector of per-thread work amounts
Returns
a model instance

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