Logo ROOT   6.21/01
Reference Guide
ROOT::Internal::TPoolManager Class Reference

Definition at line 53 of file TPoolManager.hxx.

Public Member Functions

 ~TPoolManager ()
 Terminates the scheduler instantiated within ROOT. More...
 

Static Public Member Functions

static UInt_t GetPoolSize ()
 Returns the number of threads running when the scheduler has been instantiated within ROOT. More...
 

Private Member Functions

 TPoolManager (UInt_t nThreads=0)
 Initializes the scheduler within ROOT. More...
 

Private Attributes

tbb::task_scheduler_init * fSched = nullptr
 
bool mustDelete = true
 

Static Private Attributes

static UInt_t fgPoolSize = 0
 

Friends

std::shared_ptr< TPoolManagerGetPoolManager (UInt_t nThreads)
 Get a shared pointer to the manager. More...
 

#include <ROOT/TPoolManager.hxx>

Constructor & Destructor Documentation

◆ ~TPoolManager()

ROOT::Internal::TPoolManager::~TPoolManager ( )

Terminates the scheduler instantiated within ROOT.

Definition at line 80 of file TPoolManager.cxx.

◆ TPoolManager()

ROOT::Internal::TPoolManager::TPoolManager ( UInt_t  nThreads = 0)
private

Initializes the scheduler within ROOT.

If the scheduler has already been initialized by the user before invoking the constructor it won't change its behaviour and it won't terminate it, but it will still keep record of the number of threads passed as a parameter.

Definition at line 68 of file TPoolManager.cxx.

Member Function Documentation

◆ GetPoolSize()

UInt_t ROOT::Internal::TPoolManager::GetPoolSize ( )
static

Returns the number of threads running when the scheduler has been instantiated within ROOT.

Definition at line 91 of file TPoolManager.cxx.

Friends And Related Function Documentation

◆ GetPoolManager

std::shared_ptr<TPoolManager> GetPoolManager ( UInt_t  nThreads = 0)
friend

Get a shared pointer to the manager.

Initialize the manager with nThreads if not active. If active, the number of threads, even if specified otherwise, will remain the same.

The number of threads will be able to change calling the factory function again after the last remaining shared_ptr owning the object is destroyed or reasigned, which will trigger the destructor of the manager.

Definition at line 97 of file TPoolManager.cxx.

Member Data Documentation

◆ fgPoolSize

UInt_t ROOT::Internal::TPoolManager::fgPoolSize = 0
staticprivate

Definition at line 65 of file TPoolManager.hxx.

◆ fSched

tbb::task_scheduler_init* ROOT::Internal::TPoolManager::fSched = nullptr
private

Definition at line 67 of file TPoolManager.hxx.

◆ mustDelete

bool ROOT::Internal::TPoolManager::mustDelete = true
private

Definition at line 66 of file TPoolManager.hxx.


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