|
Blender V4.3
|
the workscheduler More...
#include <COM_WorkScheduler.h>
Static Public Member Functions | |
Public API | |
| static void | schedule (WorkPackage *package) |
| schedule a chunk of a group to be calculated. An execution group schedules a chunk in the WorkScheduler | |
| static void | initialize (int num_cpu_threads) |
| initialize the WorkScheduler | |
| static void | deinitialize () |
| deinitialize the WorkScheduler free all allocated resources | |
| static void | start () |
| Start the execution this methods will start the WorkScheduler. Inside this method all threads are initialized. for every device a thread is created. | |
| static void | stop () |
| stop the execution All created thread by the start method are destroyed. | |
| static void | finish () |
| wait for all work to be completed. | |
| static int | get_num_cpu_threads () |
| static int | current_thread_id () |
the workscheduler
Definition at line 18 of file COM_WorkScheduler.h.
|
static |
Definition at line 303 of file COM_WorkScheduler.cc.
References BLI_thread_local_get, blender::compositor::COM_threading_model(), blender::compositor::SingleThreaded, and blender::compositor::CPUDevice::thread_id().
Referenced by blender::compositor::TextureBaseOperation::update_memory_buffer_partial().
|
static |
deinitialize the WorkScheduler free all allocated resources
Definition at line 281 of file COM_WorkScheduler.cc.
References blender::compositor::COM_threading_model(), blender::compositor::Queue, blender::compositor::SingleThreaded, blender::compositor::Task, and blender::compositor::threading_model_queue_deinitialize().
Referenced by COM_deinitialize().
|
static |
wait for all work to be completed.
Definition at line 229 of file COM_WorkScheduler.cc.
References blender::compositor::COM_threading_model(), blender::compositor::Queue, blender::compositor::SingleThreaded, blender::compositor::Task, blender::compositor::threading_model_queue_finish(), and blender::compositor::threading_model_task_finish().
Referenced by blender::compositor::ExecutionSystem::execute_work().
|
static |
Definition at line 298 of file COM_WorkScheduler.cc.
References blender::compositor::g_work_scheduler.
Referenced by blender::compositor::ExecutionSystem::ExecutionSystem().
|
static |
initialize the WorkScheduler
during initialization the mutexes are initialized. there are two mutexes (for every device type one) After mutex initialization the system is queried in order to count the number of CPUDevices to be created. For every hardware thread a CPUDevice is created.
Definition at line 263 of file COM_WorkScheduler.cc.
References blender::compositor::COM_threading_model(), blender::compositor::g_work_scheduler, blender::compositor::num_cpu_threads, blender::compositor::Queue, blender::compositor::SingleThreaded, blender::compositor::Task, and blender::compositor::threading_model_queue_initialize().
Referenced by COM_execute().
|
static |
schedule a chunk of a group to be calculated. An execution group schedules a chunk in the WorkScheduler
Definition at line 192 of file COM_WorkScheduler.cc.
References blender::compositor::COM_threading_model(), blender::compositor::Queue, blender::compositor::SingleThreaded, blender::compositor::Task, blender::compositor::threading_model_queue_schedule(), blender::compositor::threading_model_single_thread_execute(), and blender::compositor::threading_model_task_schedule().
Referenced by blender::compositor::ExecutionSystem::execute_work().
|
static |
Start the execution this methods will start the WorkScheduler. Inside this method all threads are initialized. for every device a thread is created.
Definition at line 212 of file COM_WorkScheduler.cc.
References blender::compositor::COM_threading_model(), blender::compositor::Queue, blender::compositor::SingleThreaded, blender::compositor::Task, blender::compositor::threading_model_queue_start(), and blender::compositor::threading_model_task_start().
Referenced by blender::compositor::ConstantFolder::fold_operations().
|
static |
stop the execution All created thread by the start method are destroyed.
Definition at line 246 of file COM_WorkScheduler.cc.
References blender::compositor::COM_threading_model(), blender::compositor::Queue, blender::compositor::SingleThreaded, blender::compositor::Task, blender::compositor::threading_model_queue_stop(), and blender::compositor::threading_model_task_stop().
Referenced by blender::compositor::ConstantFolder::fold_operations().