21 #ifndef __TBB_task_scheduler_init_H 22 #define __TBB_task_scheduler_init_H 26 #if __TBB_SUPPORTS_WORKERS_WAITING_IN_TERMINATE 58 propagation_mode_exact = 1u,
59 propagation_mode_captured = 2u,
60 propagation_mode_mask = propagation_mode_exact | propagation_mode_captured
66 bool internal_terminate(
bool blocking );
67 #if __TBB_SUPPORTS_WORKERS_WAITING_IN_TERMINATE 73 static const int automatic = -1;
76 static const int deferred = -2;
99 #if __TBB_SUPPORTS_WORKERS_WAITING_IN_TERMINATE 100 #if TBB_USE_EXCEPTIONS 101 void blocking_terminate() {
103 internal_blocking_terminate(
true );
106 bool blocking_terminate(
const std::nothrow_t&)
__TBB_NOEXCEPT(
true) {
108 return internal_blocking_terminate(
false );
110 #endif // __TBB_SUPPORTS_WORKERS_WAITING_IN_TERMINATE 113 task_scheduler_init(
int number_of_threads=automatic, stack_size_type thread_stack_size=0 ) : my_scheduler(NULL)
122 __TBB_ASSERT( !(thread_stack_size & propagation_mode_mask),
"Requested stack size is not aligned" );
123 #if TBB_USE_EXCEPTIONS 126 initialize( number_of_threads, thread_stack_size );
task_scheduler_init(int number_of_threads=automatic, stack_size_type thread_stack_size=0)
Shorthand for default constructor followed by call to initialize(number_of_threads).
#define __TBB_ASSERT(predicate, comment)
No-op version of __TBB_ASSERT.
bool is_active() const
Returns true if scheduler is active (initialized); false otherwise.
#define __TBB_NOEXCEPT(expression)
~task_scheduler_init()
Destroy scheduler for this thread if thread has no other live task_scheduler_inits.
#define __TBB_EXPORTED_METHOD
void poison_pointer(T *__TBB_atomic &)
#define __TBB_EXPORTED_FUNC
std::size_t stack_size_type
#define TBB_USE_CAPTURED_EXCEPTION
Class delimiting the scope of task scheduler activity.
internal::scheduler * my_scheduler