Intel(R) Threading Building Blocks Doxygen Documentation
version 4.2.3
|
Memory prefix to a task object. More...
#include <task.h>
Private Member Functions | |
tbb::task & | task () |
The task corresponding to this task_prefix. More... | |
Private Attributes | |
isolation_tag | isolation |
The tag used for task isolation. More... | |
task_group_context * | context |
Shared context that is used to communicate asynchronous state changes. More... | |
scheduler * | origin |
The scheduler that allocated the task, or NULL if the task is big. More... | |
union { | |
scheduler * owner | |
Obsolete. The scheduler that owns the task. More... | |
task * next_offloaded | |
Pointer to the next offloaded lower priority task. More... | |
}; | |
tbb::task * | parent |
The task whose reference count includes me. More... | |
__TBB_atomic reference_count | ref_count |
Reference count used for synchronization. More... | |
int | depth |
Obsolete. Used to be scheduling depth before TBB 2.2. More... | |
unsigned char | state |
A task::state_type, stored as a byte for compactness. More... | |
unsigned char | extra_state |
Miscellaneous state that is not directly visible to users, stored as a byte for compactness. More... | |
affinity_id | affinity |
tbb::task * | next |
"next" field for list of task More... | |
Friends | |
class | tbb::task |
class | tbb::interface5::internal::task_base |
class | tbb::task_list |
class | internal::scheduler |
class | internal::allocate_root_proxy |
class | internal::allocate_child_proxy |
class | internal::allocate_continuation_proxy |
class | internal::allocate_additional_child_of_proxy |
void | make_critical (task &) |
bool | is_critical (task &) |
Memory prefix to a task object.
This class is internal to the library. Do not reference it directly, except within the library itself. Fields are ordered in way that preserves backwards compatibility and yields good packing on typical 32-bit and 64-bit platforms. New fields should be added at the beginning for backward compatibility with accesses to the task prefix inlined into application code. To prevent ODR violation, the class shall have the same layout in all application translation units. If some fields are conditional (e.g. enabled by preview macros) and might get skipped, use reserved fields to adjust the layout.
In case task prefix size exceeds 32 or 64 bytes on IA32 and Intel64 architectures correspondingly, consider dynamic setting of task_alignment and task_prefix_reservation_size based on the maximal operand size supported by the current CPU.
|
inlineprivate |
The task corresponding to this task_prefix.
|
friend |
|
friend |
|
friend |
|
friend |
union { ... } |
|
private |
|
private |
Shared context that is used to communicate asynchronous state changes.
Currently it is used to broadcast cancellation requests generated both by users and as the result of unhandled exceptions in the task::execute() methods.
|
private |
|
private |
Miscellaneous state that is not directly visible to users, stored as a byte for compactness.
0x0 -> version 1.0 task 0x1 -> version >=2.1 task 0x10 -> task was enqueued 0x20 -> task_proxy 0x40 -> task has live ref_count 0x80 -> a stolen task
|
private |
|
private |
task* tbb::internal::task_prefix::next_offloaded |
|
private |
The scheduler that allocated the task, or NULL if the task is big.
Small tasks are pooled by the scheduler that allocated the task. If a scheduler needs to free a small task allocated by another scheduler, it returns the task to that other scheduler. This policy avoids memory space blowup issues for memory allocators that allocate from thread-specific pools.
scheduler* tbb::internal::task_prefix::owner |
|
private |
|
private |
Reference count used for synchronization.
In the "continuation-passing style" of programming, this field is the difference of the number of allocated children minus the number of children that have completed. In the "blocking style" of programming, this field is one more than the difference.
Definition at line 248 of file task.h.
Referenced by tbb::interface7::internal::task_arena_base::internal_execute(), and tbb::internal::generic_scheduler::local_spawn_root_and_wait().
|
private |
A task::state_type, stored as a byte for compactness.
This state is exposed to users via method task::state().