Arcane  4.2.2.0
Developer documentation
Loading...
Searching...
No Matches
Arcane::OneTBBTask Class Reference
Inheritance diagram for Arcane::OneTBBTask:
Collaboration diagram for Arcane::OneTBBTask:

Public Member Functions

 OneTBBTask (ITaskFunctor *f)
OneTBBTaskFunctor taskFunctor ()
void launchAndWait () override
 Launches the task and blocks until it finishes.
void launchAndWait (ConstArrayView< ITask * > tasks) override
 Launches the child tasks tasks and blocks until they finish.
void launch () override
 Method allowing to launch the task.
void wait () override
 Method allowing to wait the end of the task.

Public Attributes

ITaskFunctorm_functor = nullptr
FixedArray< char, FUNCTOR_CLASS_SIZE > m_functor_buf
Ref< tbb::task_group > m_task_group

Static Public Attributes

static const int FUNCTOR_CLASS_SIZE = 32

Protected Member Functions

ITask_createChildTask (ITaskFunctor *functor) override

Detailed Description

Definition at line 305 of file TBBTaskImplementation.cc.

Constructor & Destructor Documentation

◆ OneTBBTask()

Arcane::OneTBBTask::OneTBBTask ( ITaskFunctor * f)
inlineexplicit

Definition at line 314 of file TBBTaskImplementation.cc.

Member Function Documentation

◆ _createChildTask()

ITask * Arcane::OneTBBTask::_createChildTask ( ITaskFunctor * functor)
overrideprotectedvirtual

Implements Arcane::ITask.

Definition at line 1351 of file TBBTaskImplementation.cc.

◆ launch()

void Arcane::OneTBBTask::launch ( )
overridevirtual

Method allowing to launch the task.

\warming You must call wait() to delete this object! No warning will be displayed if you forgot to do so.

Warning
Do not mix launchAndWait() methods and launch() / wait() methods.

Implements Arcane::ITask.

Definition at line 1326 of file TBBTaskImplementation.cc.

References Arcane::makeRef().

Here is the call graph for this function:

◆ launchAndWait() [1/2]

void Arcane::OneTBBTask::launchAndWait ( )
overridevirtual

Launches the task and blocks until it finishes.

After calling this function, the task is destroyed and must not be used again.

Warning
Do not mix launchAndWait() methods and launch() / wait() methods.

Implements Arcane::ITask.

Definition at line 1291 of file TBBTaskImplementation.cc.

◆ launchAndWait() [2/2]

void Arcane::OneTBBTask::launchAndWait ( ConstArrayView< ITask * > tasks)
overridevirtual

Launches the child tasks tasks and blocks until they finish.

Warning
Do not mix launchAndWait() methods and launch() / wait() methods.

Implements Arcane::ITask.

Definition at line 1303 of file TBBTaskImplementation.cc.

References Arcane::ConstArrayView< T >::size().

Here is the call graph for this function:

◆ taskFunctor()

OneTBBTaskFunctor Arcane::OneTBBTask::taskFunctor ( )
inline

Definition at line 322 of file TBBTaskImplementation.cc.

◆ wait()

void Arcane::OneTBBTask::wait ( )
overridevirtual

Method allowing to wait the end of the task.

This method must be called after launch() method.

Warning
Do not mix launchAndWait() methods and launch() / wait() methods.

Implements Arcane::ITask.

Definition at line 1338 of file TBBTaskImplementation.cc.

Member Data Documentation

◆ FUNCTOR_CLASS_SIZE

const int Arcane::OneTBBTask::FUNCTOR_CLASS_SIZE = 32
static

Definition at line 310 of file TBBTaskImplementation.cc.

◆ m_functor

ITaskFunctor* Arcane::OneTBBTask::m_functor = nullptr

Definition at line 335 of file TBBTaskImplementation.cc.

◆ m_functor_buf

FixedArray<char, FUNCTOR_CLASS_SIZE> Arcane::OneTBBTask::m_functor_buf

Definition at line 336 of file TBBTaskImplementation.cc.

◆ m_task_group

Ref<tbb::task_group> Arcane::OneTBBTask::m_task_group

Definition at line 337 of file TBBTaskImplementation.cc.


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