Flutter Engine
The Flutter Engine
Classes | Public Types | Public Member Functions | Static Public Member Functions | Friends | List of all members
dart::Thread Class Reference

#include <thread.h>

Inheritance diagram for dart::Thread:
dart::ThreadState dart::BaseThread

Public Types

enum  TaskKind {
  kUnknownTask = 0 , kMutatorTask , kCompilerTask , kMarkerTask ,
  kSweeperTask , kCompactorTask , kScavengerTask , kSampleBlockTask ,
  kIncrementalCompactorTask
}
 
enum  { kOsrRequest = 0x1 }
 
enum  { kDidNotExit = 0 , kExitThroughFfi = 1 , kExitThroughRuntimeCall = 2 }
 
enum  { kVMInterrupt = 0x1 , kMessageInterrupt = 0x2 , kInterruptsMask = (kVMInterrupt | kMessageInterrupt) }
 
enum  ExecutionState { kThreadInVM = 0 , kThreadInGenerated , kThreadInNative , kThreadInBlockedState }
 

Public Member Functions

 ~Thread ()
 
bool HasActiveState ()
 
void AssertNonMutatorInvariants ()
 
void AssertNonDartMutatorInvariants ()
 
void AssertEmptyStackInvariants ()
 
void AssertEmptyThreadInvariants ()
 
void ReleaseStoreBuffer ()
 
void AcquireMarkingStack ()
 
void ReleaseMarkingStack ()
 
void SetStackLimit (uword value)
 
void ClearStackLimit ()
 
uword stack_limit_address () const
 
uword saved_stack_limit () const
 
uword saved_shadow_call_stack () const
 
uword write_barrier_mask () const
 
uword heap_base () const
 
int32_t IncrementAndGetStackOverflowCount ()
 
uint32_t IncrementAndGetRuntimeCallCount ()
 
TaskKind task_kind () const
 
uword GetAndClearStackOverflowFlags ()
 
void ScheduleInterrupts (uword interrupt_bits)
 
ErrorPtr HandleInterrupts ()
 
uword GetAndClearInterrupts ()
 
bool HasScheduledInterrupts () const
 
Monitorthread_lock () const
 
ApiLocalScopeapi_reusable_scope () const
 
void set_api_reusable_scope (ApiLocalScope *value)
 
ApiLocalScopeapi_top_scope () const
 
void set_api_top_scope (ApiLocalScope *value)
 
void EnterApiScope ()
 
void ExitApiScope ()
 
Isolateisolate () const
 
IsolateGroupisolate_group () const
 
bool IsDartMutatorThread () const
 
Isolatescheduled_dart_mutator_isolate () const
 
bool IsExecutingDartCode () const
 
bool HasExitedDartCode () const
 
bool HasCompilerState () const
 
CompilerStatecompiler_state ()
 
HierarchyInfohierarchy_info () const
 
void set_hierarchy_info (HierarchyInfo *value)
 
TypeUsageInfotype_usage_info () const
 
void set_type_usage_info (TypeUsageInfo *value)
 
CompilerTimingscompiler_timings () const
 
void set_compiler_timings (CompilerTimings *stats)
 
int32_t no_callback_scope_depth () const
 
void IncrementNoCallbackScopeDepth ()
 
void DecrementNoCallbackScopeDepth ()
 
bool force_growth () const
 
void IncrementForceGrowthScopeDepth ()
 
void DecrementForceGrowthScopeDepth ()
 
bool is_unwind_in_progress () const
 
void StartUnwindError ()
 
void StoreBufferAddObject (ObjectPtr obj)
 
void StoreBufferAddObjectGC (ObjectPtr obj)
 
void StoreBufferBlockProcess (StoreBuffer::ThresholdPolicy policy)
 
void StoreBufferReleaseGC ()
 
void StoreBufferAcquireGC ()
 
bool is_marking () const
 
void MarkingStackAddObject (ObjectPtr obj)
 
void OldMarkingStackAddObject (ObjectPtr obj)
 
void NewMarkingStackAddObject (ObjectPtr obj)
 
void DeferredMarkingStackAddObject (ObjectPtr obj)
 
void OldMarkingStackBlockProcess ()
 
void NewMarkingStackBlockProcess ()
 
void DeferredMarkingStackBlockProcess ()
 
uword top_exit_frame_info () const
 
void set_top_exit_frame_info (uword top_exit_frame_info)
 
Heapheap () const
 
uword top () const
 
uword end () const
 
uword true_end () const
 
void set_top (uword top)
 
void set_end (uword end)
 
void set_true_end (uword true_end)
 
int32_t no_safepoint_scope_depth () const
 
void IncrementNoSafepointScopeDepth ()
 
void DecrementNoSafepointScopeDepth ()
 
bool IsInNoReloadScope () const
 
bool IsInStoppedMutatorsScope () const
 
ObjectPoolPtr global_object_pool () const
 
void set_global_object_pool (ObjectPoolPtr raw_value)
 
const uworddispatch_table_array () const
 
void set_dispatch_table_array (const uword *array)
 
uword vm_tag () const
 
void set_vm_tag (uword tag)
 
int64_t unboxed_int64_runtime_arg () const
 
void set_unboxed_int64_runtime_arg (int64_t value)
 
int64_t unboxed_int64_runtime_second_arg () const
 
void set_unboxed_int64_runtime_second_arg (int64_t value)
 
double unboxed_double_runtime_arg () const
 
void set_unboxed_double_runtime_arg (double value)
 
simd128_value_t unboxed_simd128_runtime_arg () const
 
void set_unboxed_simd128_runtime_arg (simd128_value_t value)
 
ObjectPtr active_exception () const
 
void set_active_exception (const Object &value)
 
ObjectPtr active_stacktrace () const
 
void set_active_stacktrace (const Object &value)
 
uword resume_pc () const
 
void set_resume_pc (uword value)
 
ErrorPtr sticky_error () const
 
void set_sticky_error (const Error &value)
 
void ClearStickyError ()
 
DART_WARN_UNUSED_RESULT ErrorPtr StealStickyError ()
 
void ClearReusableHandles ()
 
bool IsAtSafepoint () const
 
bool IsAtSafepoint (SafepointLevel level) const
 
void SetAtSafepoint (bool value, SafepointLevel level)
 
bool IsSafepointRequestedLocked (SafepointLevel level) const
 
bool IsSafepointRequested () const
 
bool IsSafepointRequested (SafepointLevel level) const
 
bool IsSafepointLevelRequestedLocked (SafepointLevel level) const
 
void BlockForSafepoint ()
 
uword SetSafepointRequested (SafepointLevel level, bool value)
 
bool IsBlockedForSafepoint () const
 
void SetBlockedForSafepoint (bool value)
 
bool BypassSafepoints () const
 
bool UnwindErrorInProgress () const
 
void SetUnwindErrorInProgress (bool value)
 
bool OwnsGCSafepoint () const
 
bool OwnsReloadSafepoint () const
 
bool OwnsDeoptSafepoint () const
 
bool OwnsSafepoint () const
 
bool CanAcquireSafepointLocks () const
 
uword safepoint_state ()
 
ExecutionState execution_state () const
 
NO_SANITIZE_THREAD ExecutionState execution_state_cross_thread_for_testing () const
 
void set_execution_state (ExecutionState state)
 
virtual bool MayAllocateHandles ()
 
bool TryEnterSafepoint ()
 
void EnterSafepoint ()
 
bool TryExitSafepoint ()
 
void ExitSafepoint ()
 
void CheckForSafepoint ()
 
Threadnext () const
 
void VisitObjectPointers (ObjectPointerVisitor *visitor, ValidationPolicy validate_frames)
 
void RememberLiveTemporaries ()
 
void DeferredMarkLiveTemporaries ()
 
bool IsValidHandle (Dart_Handle object) const
 
bool IsValidLocalHandle (Dart_Handle object) const
 
intptr_t CountLocalHandles () const
 
int ZoneSizeInBytes () const
 
void UnwindScopes (uword stack_marker)
 
void InitVMConstants ()
 
int64_t GetNextTaskId ()
 
Randomrandom ()
 
void PrintJSON (JSONStream *stream) const
 
HeapProfileSamplerheap_sampler ()
 
PendingDeoptspending_deopts ()
 
SafepointLevel current_safepoint_level () const
 
template<class C >
CAllocateReusableHandle ()
 
- Public Member Functions inherited from dart::ThreadState
 ThreadState (bool is_os_thread)
 
virtual ~ThreadState ()
 
OSThreados_thread () const
 
void set_os_thread (OSThread *os_thread)
 
Zonezone () const
 
bool ZoneIsOwnedByThread (Zone *zone) const
 
StackResourcetop_resource () const
 
void set_top_resource (StackResource *value)
 
LongJumpScopelong_jump_base () const
 
void set_long_jump_base (LongJumpScope *value)
 
bool IsValidZoneHandle (Dart_Handle object) const
 
intptr_t CountZoneHandles () const
 
bool IsValidScopedHandle (Dart_Handle object) const
 
intptr_t CountScopedHandles () const
 
virtual bool MayAllocateHandles ()=0
 
HandleScopetop_handle_scope () const
 
void set_top_handle_scope (HandleScope *handle_scope)
 
- Public Member Functions inherited from dart::BaseThread
bool is_os_thread () const
 

Static Public Member Functions

static const char * TaskKindToCString (TaskKind kind)
 
static ThreadCurrent ()
 
static void EnterIsolate (Isolate *isolate)
 
static void ExitIsolate (bool isolate_shutdown=false)
 
static bool EnterIsolateGroupAsHelper (IsolateGroup *isolate_group, TaskKind kind, bool bypass_safepoint)
 
static void ExitIsolateGroupAsHelper (bool bypass_safepoint)
 
static bool EnterIsolateGroupAsNonMutator (IsolateGroup *isolate_group, TaskKind kind)
 
static void ExitIsolateGroupAsNonMutator ()
 
static intptr_t stack_limit_offset ()
 
static intptr_t saved_stack_limit_offset ()
 
static uword saved_shadow_call_stack_offset ()
 
static intptr_t write_barrier_mask_offset ()
 
static intptr_t stack_overflow_flags_offset ()
 
static uword stack_overflow_shared_stub_entry_point_offset (bool fpu_regs)
 
static intptr_t safepoint_state_offset ()
 
static intptr_t exit_through_ffi_offset ()
 
static intptr_t api_top_scope_offset ()
 
static intptr_t double_truncate_round_supported_offset ()
 
static intptr_t tsan_utils_offset ()
 
static intptr_t isolate_offset ()
 
static intptr_t isolate_group_offset ()
 
static intptr_t field_table_values_offset ()
 
static intptr_t shared_field_table_values_offset ()
 
static intptr_t dart_stream_offset ()
 
static intptr_t service_extension_stream_offset ()
 
static intptr_t store_buffer_block_offset ()
 
static intptr_t old_marking_stack_block_offset ()
 
static intptr_t new_marking_stack_block_offset ()
 
static intptr_t top_exit_frame_info_offset ()
 
static intptr_t top_offset ()
 
static intptr_t end_offset ()
 
static intptr_t write_barrier_wrappers_thread_offset (Register reg)
 
static intptr_t WriteBarrierWrappersOffsetForRegister (Register reg)
 
static bool CanLoadFromThread (const Object &object)
 
static intptr_t OffsetFromThread (const Object &object)
 
static bool ObjectAtOffset (intptr_t offset, Object *object)
 
static intptr_t OffsetFromThread (const RuntimeEntry *runtime_entry)
 
static intptr_t vm_tag_offset ()
 
static intptr_t unboxed_runtime_arg_offset ()
 
static intptr_t global_object_pool_offset ()
 
static intptr_t dispatch_table_array_offset ()
 
static intptr_t active_exception_offset ()
 
static intptr_t active_stacktrace_offset ()
 
static uword resume_pc_offset ()
 
static bool IsAtSafepoint (SafepointLevel level, uword state)
 
static bool IsSafepointLevelRequested (uword state, SafepointLevel level)
 
static bool IsBlockedForSafepoint (uword state)
 
static uword SetBypassSafepoints (bool value, uword state)
 
static intptr_t execution_state_offset ()
 
static uword full_safepoint_state_unacquired ()
 
static uword full_safepoint_state_acquired ()
 
static intptr_t next_task_id_offset ()
 
static intptr_t random_offset ()
 
- Static Public Member Functions inherited from dart::ThreadState
static ThreadStateCurrent ()
 
static intptr_t top_resource_offset ()
 

Friends

class RestoreWriteBarrierInvariantVisitor
 
class ApiZone
 
class ActiveIsolateScope
 
class InterruptChecker
 
class Isolate
 
class IsolateGroup
 
class NoActiveIsolateScope
 
class NoReloadScope
 
class RawReloadParticipationScope
 
class Simulator
 
class StackZone
 
class StoppedMutatorsScope
 
class ThreadRegistry
 
class CompilerState
 
class compiler::target::Thread
 
class FieldTable
 
class RuntimeCallDeoptScope
 
class Dart
 
class TransitionGeneratedToVM
 
class TransitionVMToGenerated
 
class MonitorLocker
 
IsolateCreateWithinExistingIsolateGroup (IsolateGroup *, const char *, char **)
 

Detailed Description

Definition at line 342 of file thread.h.

Member Enumeration Documentation

◆ anonymous enum

anonymous enum
Enumerator
kOsrRequest 

Definition at line 424 of file thread.h.

424 {
425 kOsrRequest = 0x1, // Current stack overflow caused by OSR request.
426 };
@ kOsrRequest
Definition: thread.h:425

◆ anonymous enum

anonymous enum
Enumerator
kDidNotExit 
kExitThroughFfi 
kExitThroughRuntimeCall 

Definition at line 464 of file thread.h.

464 {
465 // Always true in generated state.
466 kDidNotExit = 0,
467 // The VM exited the generated state through FFI.
468 // This can be true in both native and VM state.
469 kExitThroughFfi = 1,
470 // The VM exited the generated state through a runtime call.
471 // This can be true in both native and VM state.
473 };
@ kExitThroughRuntimeCall
Definition: thread.h:472
@ kDidNotExit
Definition: thread.h:466
@ kExitThroughFfi
Definition: thread.h:469

◆ anonymous enum

anonymous enum
Enumerator
kVMInterrupt 
kMessageInterrupt 
kInterruptsMask 

Definition at line 487 of file thread.h.

487 {
488 kVMInterrupt = 0x1, // Internal VM checks: safepoints, store buffers, etc.
489 kMessageInterrupt = 0x2, // An interrupt to process an out of band message.
490
492 };
@ kMessageInterrupt
Definition: thread.h:489
@ kVMInterrupt
Definition: thread.h:488
@ kInterruptsMask
Definition: thread.h:491

◆ ExecutionState

Enumerator
kThreadInVM 
kThreadInGenerated 
kThreadInNative 
kThreadInBlockedState 

Definition at line 1033 of file thread.h.

1033 {
1034 kThreadInVM = 0,
1038 };
@ kThreadInNative
Definition: thread.h:1036
@ kThreadInBlockedState
Definition: thread.h:1037
@ kThreadInGenerated
Definition: thread.h:1035

◆ TaskKind

Enumerator
kUnknownTask 
kMutatorTask 
kCompilerTask 
kMarkerTask 
kSweeperTask 
kCompactorTask 
kScavengerTask 
kSampleBlockTask 
kIncrementalCompactorTask 

Definition at line 345 of file thread.h.

345 {
346 kUnknownTask = 0,
355 };
@ kCompilerTask
Definition: thread.h:348
@ kScavengerTask
Definition: thread.h:352
@ kMutatorTask
Definition: thread.h:347
@ kMarkerTask
Definition: thread.h:349
@ kSampleBlockTask
Definition: thread.h:353
@ kIncrementalCompactorTask
Definition: thread.h:354
@ kSweeperTask
Definition: thread.h:350
@ kUnknownTask
Definition: thread.h:346
@ kCompactorTask
Definition: thread.h:351

Constructor & Destructor Documentation

◆ ~Thread()

dart::Thread::~Thread ( )

Definition at line 37 of file thread.cc.

37 {
38 // We should cleanly exit any isolate before destruction.
39 ASSERT(isolate_ == nullptr);
40 ASSERT(store_buffer_block_ == nullptr);
41 ASSERT(old_marking_stack_block_ == nullptr);
42 ASSERT(new_marking_stack_block_ == nullptr);
43 ASSERT(deferred_marking_stack_block_ == nullptr);
44 // There should be no top api scopes at this point.
45 ASSERT(api_top_scope() == nullptr);
46 // Delete the reusable api scope if there is one.
47 if (api_reusable_scope_ != nullptr) {
48 delete api_reusable_scope_;
49 api_reusable_scope_ = nullptr;
50 }
51
52 DO_IF_TSAN(delete tsan_utils_);
53}
ApiLocalScope * api_top_scope() const
Definition: thread.h:513
#define ASSERT(E)
#define DO_IF_TSAN(CODE)

Member Function Documentation

◆ AcquireMarkingStack()

void dart::Thread::AcquireMarkingStack ( )

◆ active_exception()

ObjectPtr dart::Thread::active_exception ( ) const
inline

Definition at line 861 of file thread.h.

861{ return active_exception_; }

◆ active_exception_offset()

static intptr_t dart::Thread::active_exception_offset ( )
inlinestatic

Definition at line 863 of file thread.h.

863 {
864 return OFFSET_OF(Thread, active_exception_);
865 }
#define OFFSET_OF(type, field)
Definition: globals.h:138

◆ active_stacktrace()

ObjectPtr dart::Thread::active_stacktrace ( ) const
inline

Definition at line 867 of file thread.h.

867{ return active_stacktrace_; }

◆ active_stacktrace_offset()

static intptr_t dart::Thread::active_stacktrace_offset ( )
inlinestatic

Definition at line 869 of file thread.h.

869 {
870 return OFFSET_OF(Thread, active_stacktrace_);
871 }

◆ AllocateReusableHandle()

template<class C >
C * dart::Thread::AllocateReusableHandle ( )

Definition at line 956 of file thread.cc.

956 {
957 C* handle = reinterpret_cast<C*>(reusable_handles_.AllocateScopedHandle());
958 C::initializeHandle(handle, C::null());
959 return handle;
960}
uword AllocateScopedHandle()
Definition: handles.h:96

◆ api_reusable_scope()

ApiLocalScope * dart::Thread::api_reusable_scope ( ) const
inline

Definition at line 505 of file thread.h.

505{ return api_reusable_scope_; }

◆ api_top_scope()

ApiLocalScope * dart::Thread::api_top_scope ( ) const
inline

Definition at line 513 of file thread.h.

513{ return api_top_scope_; }

◆ api_top_scope_offset()

static intptr_t dart::Thread::api_top_scope_offset ( )
inlinestatic

Definition at line 515 of file thread.h.

515 {
516 return OFFSET_OF(Thread, api_top_scope_);
517 }

◆ AssertEmptyStackInvariants()

void dart::Thread::AssertEmptyStackInvariants ( )

Definition at line 287 of file thread.cc.

287 {
288 ASSERT(zone() == nullptr);
289 ASSERT(top_handle_scope() == nullptr);
290 ASSERT(long_jump_base() == nullptr);
291 ASSERT(top_resource() == nullptr);
292 ASSERT(top_exit_frame_info_ == 0);
293 ASSERT(api_top_scope_ == nullptr);
294 ASSERT(!pending_deopts_.HasPendingDeopts());
295 ASSERT(compiler_state_ == nullptr);
296 ASSERT(hierarchy_info_ == nullptr);
297 ASSERT(type_usage_info_ == nullptr);
298 ASSERT(no_active_isolate_scope_ == nullptr);
299 ASSERT(compiler_timings_ == nullptr);
300 ASSERT(!exit_through_ffi_);
301 ASSERT(runtime_call_deopt_ability_ == RuntimeCallDeoptAbility::kCanLazyDeopt);
302 ASSERT(no_callback_scope_depth_ == 0);
303 ASSERT(force_growth_scope_depth_ == 0);
304 ASSERT(no_reload_scope_depth_ == 0);
305 ASSERT(stopped_mutators_scope_depth_ == 0);
306 ASSERT(stack_overflow_flags_ == 0);
307 DEBUG_ASSERT(!inside_compiler_);
308 DEBUG_ASSERT(no_safepoint_scope_depth_ == 0);
309
310 // Avoid running these asserts for `vm-isolate`.
311 if (active_stacktrace_.untag() != 0) {
313 ASSERT(active_exception_ == Object::null());
314 ASSERT(active_stacktrace_ == Object::null());
315 }
316}
#define DEBUG_ASSERT(cond)
Definition: assert.h:321
UntaggedObject * untag() const
static ObjectPtr null()
Definition: object.h:433
Zone * zone() const
Definition: thread_state.h:37
HandleScope * top_handle_scope() const
Definition: thread_state.h:57
LongJumpScope * long_jump_base() const
Definition: thread_state.h:47
StackResource * top_resource() const
Definition: thread_state.h:41
ErrorPtr sticky_error() const
Definition: thread.cc:232

◆ AssertEmptyThreadInvariants()

void dart::Thread::AssertEmptyThreadInvariants ( )

Definition at line 318 of file thread.cc.

318 {
320
321 ASSERT(top_ == 0);
322 ASSERT(end_ == 0);
323 ASSERT(true_end_ == 0);
324 ASSERT(isolate_ == nullptr);
325 ASSERT(isolate_group_ == nullptr);
326 ASSERT(os_thread() == nullptr);
327 ASSERT(vm_tag_ == VMTag::kInvalidTagId);
328 ASSERT(task_kind_ == kUnknownTask);
329 ASSERT(execution_state_ == Thread::kThreadInNative);
330 ASSERT(scheduled_dart_mutator_isolate_ == nullptr);
331
332 ASSERT(write_barrier_mask_ == UntaggedObject::kGenerationalBarrierMask);
333 ASSERT(store_buffer_block_ == nullptr);
334 ASSERT(old_marking_stack_block_ == nullptr);
335 ASSERT(new_marking_stack_block_ == nullptr);
336 ASSERT(deferred_marking_stack_block_ == nullptr);
337 ASSERT(!is_unwind_in_progress_);
338
339 ASSERT(saved_stack_limit_ == OSThread::kInvalidStackLimit);
340 ASSERT(stack_limit_.load() == 0);
341 ASSERT(safepoint_state_ == 0);
342
343 // Avoid running these asserts for `vm-isolate`.
344 if (active_stacktrace_.untag() != 0) {
345 ASSERT(field_table_values_ == nullptr);
346 ASSERT(shared_field_table_values_ == nullptr);
347 ASSERT(global_object_pool_ == Object::null());
348#define CHECK_REUSABLE_HANDLE(object) ASSERT(object##_handle_->IsNull());
350#undef CHECK_REUSABLE_HANDLE
351 }
352}
static const uword kInvalidStackLimit
Definition: os_thread.h:88
T load(std::memory_order order=std::memory_order_relaxed) const
Definition: atomic.h:21
OSThread * os_thread() const
Definition: thread_state.h:33
void AssertEmptyStackInvariants()
Definition: thread.cc:287
static constexpr intptr_t kGenerationalBarrierMask
Definition: raw_object.h:181
@ kInvalidTagId
Definition: tags.h:38
#define CHECK_REUSABLE_HANDLE(object)
#define REUSABLE_HANDLE_LIST(V)
Definition: thread.h:78

◆ AssertNonDartMutatorInvariants()

void dart::Thread::AssertNonDartMutatorInvariants ( )

Definition at line 279 of file thread.cc.

279 {
281 ASSERT(isolate() == nullptr);
282 ASSERT(isolate_group() != nullptr);
283 ASSERT(task_kind_ != kMutatorTask);
284 DEBUG_ASSERT(!IsAnyReusableHandleScopeActive());
285}
bool IsDartMutatorThread() const
Definition: thread.h:551
Isolate * isolate() const
Definition: thread.h:534
IsolateGroup * isolate_group() const
Definition: thread.h:541

◆ AssertNonMutatorInvariants()

void dart::Thread::AssertNonMutatorInvariants ( )

Definition at line 270 of file thread.cc.

270 {
272 ASSERT(store_buffer_block_ == nullptr);
273 ASSERT(old_marking_stack_block_ == nullptr);
274 ASSERT(new_marking_stack_block_ == nullptr);
275 ASSERT(deferred_marking_stack_block_ == nullptr);
277}
void AssertNonDartMutatorInvariants()
Definition: thread.cc:279
bool BypassSafepoints() const
Definition: thread.h:1007

◆ BlockForSafepoint()

void dart::Thread::BlockForSafepoint ( )

Definition at line 1348 of file thread.cc.

1348 {
1350}
SafepointHandler * safepoint_handler()
Definition: isolate.h:334
void BlockForSafepoint(Thread *T)
Definition: safepoint.cc:324

◆ BypassSafepoints()

bool dart::Thread::BypassSafepoints ( ) const
inline

Definition at line 1007 of file thread.h.

1007 {
1008 return BypassSafepointsField::decode(safepoint_state_);
1009 }
static DecodeResult decode(std::string path)
Definition: png_codec.cpp:124

◆ CanAcquireSafepointLocks()

bool dart::Thread::CanAcquireSafepointLocks ( ) const

Definition at line 1372 of file thread.cc.

1372 {
1373 // A thread may acquire locks and then enter a safepoint operation (e.g.
1374 // holding program lock, allocating objects which triggers GC).
1375 //
1376 // So if this code is called inside safepoint operation, we generally have to
1377 // assume other threads may hold locks and are blocked on the safepoint,
1378 // meaning we cannot hold safepoint and acquire locks (deadlock!).
1379 //
1380 // Though if we own a reload safepoint operation it means all other mutators
1381 // are blocked in very specific places, where we know no locks are held. As
1382 // such we allow the current thread to acquire locks.
1383 //
1384 // Example: We own reload safepoint operation, load kernel, which allocates
1385 // symbols, where the symbol implementation acquires the symbol lock (we know
1386 // other mutators at reload safepoint do not hold symbol lock).
1389}
SafepointLevel InnermostSafepointOperation(const Thread *current_thread) const
Definition: safepoint.cc:291
@ kGCAndDeoptAndReload
Definition: thread.h:295

◆ CanLoadFromThread()

bool dart::Thread::CanLoadFromThread ( const Object object)
static

Definition at line 1154 of file thread.cc.

1154 {
1155 // In order to allow us to use assembler helper routines with non-[Code]
1156 // objects *before* stubs are initialized, we only loop ver the stubs if the
1157 // [object] is in fact a [Code] object.
1158 if (object.IsCode()) {
1159#define CHECK_OBJECT(type_name, member_name, expr, default_init_value) \
1160 if (object.ptr() == expr) { \
1161 return true; \
1162 }
1164#undef CHECK_OBJECT
1165 }
1166
1167 // For non [Code] objects we check if the object equals to any of the cached
1168 // non-stub entries.
1169#define CHECK_OBJECT(type_name, member_name, expr, default_init_value) \
1170 if (object.ptr() == expr) { \
1171 return true; \
1172 }
1174#undef CHECK_OBJECT
1175 return false;
1176}
#define CHECK_OBJECT(type_name, member_name, expr, default_init_value)
#define CACHED_NON_VM_STUB_LIST(V)
Definition: thread.h:174
#define CACHED_VM_STUBS_LIST(V)
Definition: thread.h:100

◆ CheckForSafepoint()

void dart::Thread::CheckForSafepoint ( )
inline

Definition at line 1104 of file thread.h.

1104 {
1105 // If we are in a runtime call that doesn't support lazy deopt, we will only
1106 // respond to gc safepointing requests.
1108 if (IsSafepointRequested()) {
1110 }
1111 }
bool IsSafepointRequested() const
Definition: thread.h:937
int32_t no_safepoint_scope_depth() const
Definition: thread.h:718
void BlockForSafepoint()
Definition: thread.cc:1348

◆ ClearReusableHandles()

void dart::Thread::ClearReusableHandles ( )

Definition at line 962 of file thread.cc.

962 {
963#define CLEAR_REUSABLE_HANDLE(object) *object##_handle_ = object::null();
965#undef CLEAR_REUSABLE_HANDLE
966}
#define CLEAR_REUSABLE_HANDLE(object)

◆ ClearStackLimit()

void dart::Thread::ClearStackLimit ( )

Definition at line 701 of file thread.cc.

701 {
703}
void SetStackLimit(uword value)
Definition: thread.cc:690

◆ ClearStickyError()

void dart::Thread::ClearStickyError ( )

Definition at line 241 of file thread.cc.

241 {
242 sticky_error_ = Error::null();
243}

◆ compiler_state()

CompilerState & dart::Thread::compiler_state ( )
inline

Definition at line 588 of file thread.h.

588 {
590 return *compiler_state_;
591 }
bool HasCompilerState() const
Definition: thread.h:586

◆ compiler_timings()

CompilerTimings * dart::Thread::compiler_timings ( ) const
inline

Definition at line 617 of file thread.h.

617{ return compiler_timings_; }

◆ CountLocalHandles()

intptr_t dart::Thread::CountLocalHandles ( ) const

Definition at line 1281 of file thread.cc.

1281 {
1282 intptr_t total = 0;
1283 ApiLocalScope* scope = api_top_scope_;
1284 while (scope != nullptr) {
1285 total += scope->local_handles()->CountHandles();
1286 scope = scope->previous();
1287 }
1288 return total;
1289}
LocalHandles * local_handles()
int CountHandles() const

◆ Current()

static Thread * dart::Thread::Current ( )
inlinestatic

Definition at line 362 of file thread.h.

362 {
363 return static_cast<Thread*>(OSThread::CurrentVMThread());
364 }
static ThreadState * CurrentVMThread()
Definition: os_thread.h:188

◆ current_safepoint_level()

SafepointLevel dart::Thread::current_safepoint_level ( ) const
inline

Definition at line 1146 of file thread.h.

1146 {
1147 if (runtime_call_deopt_ability_ ==
1149 return SafepointLevel::kGC;
1150 }
1151 if (no_reload_scope_depth_ > 0 || allow_reload_scope_depth_ <= 0) {
1153 }
1155 }
@ kGC
Definition: thread.h:291
@ kGCAndDeopt
Definition: thread.h:293

◆ dart_stream_offset()

static intptr_t dart::Thread::dart_stream_offset ( )
inlinestatic

Definition at line 571 of file thread.h.

571 {
572 return OFFSET_OF(Thread, dart_stream_);
573 }

◆ DecrementForceGrowthScopeDepth()

void dart::Thread::DecrementForceGrowthScopeDepth ( )
inline

Definition at line 638 of file thread.h.

638 {
639 ASSERT(force_growth_scope_depth_ > 0);
640 force_growth_scope_depth_ -= 1;
641 }

◆ DecrementNoCallbackScopeDepth()

void dart::Thread::DecrementNoCallbackScopeDepth ( )
inline

Definition at line 628 of file thread.h.

628 {
629 ASSERT(no_callback_scope_depth_ > 0);
630 no_callback_scope_depth_ -= 1;
631 }

◆ DecrementNoSafepointScopeDepth()

void dart::Thread::DecrementNoSafepointScopeDepth ( )
inline

Definition at line 733 of file thread.h.

733 {
734#if defined(DEBUG)
735 ASSERT(no_safepoint_scope_depth_ > 0);
736 no_safepoint_scope_depth_ -= 1;
737#endif
738 }

◆ DeferredMarkingStackAddObject()

void dart::Thread::DeferredMarkingStackAddObject ( ObjectPtr  obj)

Definition at line 871 of file thread.cc.

871 {
872 deferred_marking_stack_block_->Push(obj);
873 if (deferred_marking_stack_block_->IsFull()) {
875 }
876}
void Push(ObjectPtr obj)
Definition: pointer_block.h:37
bool IsFull() const
Definition: pointer_block.h:34
void DeferredMarkingStackBlockProcess()
Definition: thread.cc:842

◆ DeferredMarkingStackBlockProcess()

void dart::Thread::DeferredMarkingStackBlockProcess ( )

Definition at line 842 of file thread.cc.

842 {
843 DeferredMarkingStackRelease();
844 DeferredMarkingStackAcquire();
845}

◆ DeferredMarkLiveTemporaries()

void dart::Thread::DeferredMarkLiveTemporaries ( )

Definition at line 1144 of file thread.cc.

1144 {
1145 RestoreWriteBarrierInvariant(
1146 RestoreWriteBarrierInvariantOp::kAddToDeferredMarkingStack);
1147}

◆ dispatch_table_array()

const uword * dart::Thread::dispatch_table_array ( ) const
inline

Definition at line 797 of file thread.h.

797{ return dispatch_table_array_; }

◆ dispatch_table_array_offset()

static intptr_t dart::Thread::dispatch_table_array_offset ( )
inlinestatic

Definition at line 857 of file thread.h.

857 {
858 return OFFSET_OF(Thread, dispatch_table_array_);
859 }

◆ double_truncate_round_supported_offset()

static intptr_t dart::Thread::double_truncate_round_supported_offset ( )
inlinestatic

Definition at line 522 of file thread.h.

522 {
523 return OFFSET_OF(Thread, double_truncate_round_supported_);
524 }

◆ end()

uword dart::Thread::end ( ) const
inline

Definition at line 710 of file thread.h.

710{ return end_; }

◆ end_offset()

static intptr_t dart::Thread::end_offset ( )
inlinestatic

Definition at line 716 of file thread.h.

716{ return OFFSET_OF(Thread, end_); }

◆ EnterApiScope()

void dart::Thread::EnterApiScope ( )

Definition at line 1301 of file thread.cc.

1301 {
1303 ApiLocalScope* new_scope = api_reusable_scope();
1304 if (new_scope == nullptr) {
1305 new_scope = new ApiLocalScope(api_top_scope(), top_exit_frame_info());
1306 ASSERT(new_scope != nullptr);
1307 } else {
1308 new_scope->Reinit(this, api_top_scope(), top_exit_frame_info());
1309 set_api_reusable_scope(nullptr);
1310 }
1311 set_api_top_scope(new_scope); // New scope is now the top scope.
1312}
ApiLocalScope * api_reusable_scope() const
Definition: thread.h:505
void set_api_reusable_scope(ApiLocalScope *value)
Definition: thread.h:506
uword top_exit_frame_info() const
Definition: thread.h:691
void set_api_top_scope(ApiLocalScope *value)
Definition: thread.h:514
virtual bool MayAllocateHandles()
Definition: thread.h:1055

◆ EnterIsolate()

void dart::Thread::EnterIsolate ( Isolate isolate)
static

Definition at line 371 of file thread.cc.

371 {
372 const bool is_resumable = isolate->mutator_thread() != nullptr;
373
374 // To let VM's thread pool (if we run on it) know that this thread is
375 // occupying a mutator again (decreases its max size).
376 const bool is_nested_reenter =
377 (is_resumable && isolate->mutator_thread()->top_exit_frame_info() != 0);
378
379 auto group = isolate->group();
380 if (!(is_nested_reenter && isolate->mutator_thread()->OwnsSafepoint())) {
381 group->IncreaseMutatorCount(isolate, is_nested_reenter);
382 }
383
384 // Two threads cannot enter isolate at same time.
386
387 // We lazily create a [Thread] structure for the mutator thread, but we'll
388 // reuse it until the death of the isolate.
389 Thread* thread = nullptr;
390 if (is_resumable) {
391 thread = isolate->mutator_thread();
392 ASSERT(thread->scheduled_dart_mutator_isolate_ == isolate);
393 ASSERT(thread->isolate() == isolate);
394 ASSERT(thread->isolate_group() == isolate->group());
395 {
396 // Descheduled isolates are reloadable (if nothing else prevents it).
397 RawReloadParticipationScope enable_reload(thread);
398 thread->ExitSafepoint();
399 }
400 } else {
401 thread = AddActiveThread(group, isolate, /*is_dart_mutator*/ true,
402 /*bypass_safepoint=*/false);
403 thread->SetupState(kMutatorTask);
404 thread->SetupMutatorState(kMutatorTask);
405 thread->SetupDartMutatorState(isolate);
406 }
407
409 ResumeDartMutatorThreadInternal(thread);
410}
Thread * scheduled_mutator_thread_
Definition: base_isolate.h:34
IsolateGroup * group() const
Definition: isolate.h:1037
Thread * mutator_thread() const
Definition: isolate.cc:1920
bool OwnsSafepoint() const
Definition: thread.cc:1367
friend class RawReloadParticipationScope
Definition: thread.h:1480

◆ EnterIsolateGroupAsHelper()

bool dart::Thread::EnterIsolateGroupAsHelper ( IsolateGroup isolate_group,
TaskKind  kind,
bool  bypass_safepoint 
)
static

Definition at line 481 of file thread.cc.

483 {
484 Thread* thread = AddActiveThread(isolate_group, nullptr,
485 /*is_dart_mutator=*/false, bypass_safepoint);
486 if (thread != nullptr) {
487 thread->SetupState(kind);
488 // Even if [bypass_safepoint] is true, a thread may need mutator state (e.g.
489 // parallel scavenger threads write to the [Thread]s storebuffer)
490 thread->SetupMutatorState(kind);
491 ResumeThreadInternal(thread);
492
493 thread->AssertNonDartMutatorInvariants();
494 return true;
495 }
496 return false;
497}

◆ EnterIsolateGroupAsNonMutator()

bool dart::Thread::EnterIsolateGroupAsNonMutator ( IsolateGroup isolate_group,
TaskKind  kind 
)
static

Definition at line 511 of file thread.cc.

512 {
513 Thread* thread =
514 AddActiveThread(isolate_group, nullptr,
515 /*is_dart_mutator=*/false, /*bypass_safepoint=*/true);
516 if (thread != nullptr) {
517 thread->SetupState(kind);
518 ResumeThreadInternal(thread);
519
520 thread->AssertNonMutatorInvariants();
521 return true;
522 }
523 return false;
524}

◆ EnterSafepoint()

void dart::Thread::EnterSafepoint ( )
inline

Definition at line 1076 of file thread.h.

1076 {
1078 // First try a fast update of the thread state to indicate it is at a
1079 // safepoint.
1080 if (!TryEnterSafepoint()) {
1081 // Fast update failed which means we could potentially be in the middle
1082 // of a safepoint operation.
1083 EnterSafepointUsingLock();
1084 }
1085 }
bool TryEnterSafepoint()
Definition: thread.h:1069

◆ execution_state()

ExecutionState dart::Thread::execution_state ( ) const
inline

Definition at line 1040 of file thread.h.

1040 {
1041 return static_cast<ExecutionState>(execution_state_);
1042 }

◆ execution_state_cross_thread_for_testing()

NO_SANITIZE_THREAD ExecutionState dart::Thread::execution_state_cross_thread_for_testing ( ) const
inline

Definition at line 1045 of file thread.h.

1045 {
1046 return static_cast<ExecutionState>(execution_state_);
1047 }

◆ execution_state_offset()

static intptr_t dart::Thread::execution_state_offset ( )
inlinestatic

Definition at line 1051 of file thread.h.

1051 {
1052 return OFFSET_OF(Thread, execution_state_);
1053 }

◆ exit_through_ffi_offset()

static intptr_t dart::Thread::exit_through_ffi_offset ( )
inlinestatic

Definition at line 475 of file thread.h.

475 {
476 return OFFSET_OF(Thread, exit_through_ffi_);
477 }

◆ ExitApiScope()

void dart::Thread::ExitApiScope ( )

Definition at line 1314 of file thread.cc.

1314 {
1316 ApiLocalScope* scope = api_top_scope();
1317 ApiLocalScope* reusable_scope = api_reusable_scope();
1318 set_api_top_scope(scope->previous()); // Reset top scope to previous.
1319 if (reusable_scope == nullptr) {
1320 scope->Reset(this); // Reset the old scope which we just exited.
1322 } else {
1323 ASSERT(reusable_scope != scope);
1324 delete scope;
1325 }
1326}

◆ ExitIsolate()

void dart::Thread::ExitIsolate ( bool  isolate_shutdown = false)
static

Definition at line 428 of file thread.cc.

428 {
429 Thread* thread = Thread::Current();
430 ASSERT(thread != nullptr);
431 ASSERT(thread->IsDartMutatorThread());
432 ASSERT(thread->isolate() != nullptr);
433 ASSERT(thread->isolate_group() != nullptr);
434 ASSERT(thread->isolate()->mutator_thread_ == thread);
435 ASSERT(thread->isolate()->scheduled_mutator_thread_ == thread);
436 DEBUG_ASSERT(!thread->IsAnyReusableHandleScopeActive());
437
438 auto isolate = thread->isolate();
439 auto group = thread->isolate_group();
440
441 thread->set_vm_tag(isolate->is_runnable() ? VMTag::kIdleTagId
442 : VMTag::kLoadWaitTagId);
443 if (thread->sticky_error() != Error::null()) {
444 ASSERT(isolate->sticky_error_ == Error::null());
445 isolate->sticky_error_ = thread->StealStickyError();
446 }
447
449
450 // Right now we keep the [Thread] object across the isolate's lifetime. This
451 // makes entering/exiting quite fast as it mainly boils down to safepoint
452 // transitions. Though any operation that walks over all active threads will
453 // see this thread as well (e.g. safepoint operations).
454 const bool is_nested_exit = thread->top_exit_frame_info() != 0;
455 if (ShouldSuspend(isolate_shutdown, thread)) {
456 const auto tag =
457 isolate->is_runnable() ? VMTag::kIdleTagId : VMTag::kLoadWaitTagId;
458 SuspendDartMutatorThreadInternal(thread, tag);
459 {
460 // Descheduled isolates are reloadable (if nothing else prevents it).
461 RawReloadParticipationScope enable_reload(thread);
462 thread->EnterSafepoint();
463 }
464 thread->set_execution_state(Thread::kThreadInNative);
465 } else {
466 thread->ResetDartMutatorState(isolate);
467 thread->ResetMutatorState();
468 thread->ResetState();
469 SuspendDartMutatorThreadInternal(thread, VMTag::kInvalidTagId);
470 FreeActiveThread(thread, /*bypass_safepoint=*/false);
471 }
472
473 // To let VM's thread pool (if we run on it) know that this thread is
474 // occupying a mutator again (decreases its max size).
475 ASSERT(!(isolate_shutdown && is_nested_exit));
476 if (!(is_nested_exit && thread->OwnsSafepoint())) {
477 group->DecreaseMutatorCount(isolate, is_nested_exit);
478 }
479}
bool is_runnable() const
Definition: isolate.h:1095
static Thread * Current()
Definition: thread.h:362
static bool ShouldSuspend(bool isolate_shutdown, Thread *thread)
Definition: thread.cc:412

◆ ExitIsolateGroupAsHelper()

void dart::Thread::ExitIsolateGroupAsHelper ( bool  bypass_safepoint)
static

Definition at line 499 of file thread.cc.

499 {
500 Thread* thread = Thread::Current();
501 thread->AssertNonDartMutatorInvariants();
502
503 // Even if [bypass_safepoint] is true, a thread may need mutator state (e.g.
504 // parallel scavenger threads write to the [Thread]s storebuffer)
505 thread->ResetMutatorState();
506 thread->ResetState();
507 SuspendThreadInternal(thread, VMTag::kInvalidTagId);
508 FreeActiveThread(thread, bypass_safepoint);
509}

◆ ExitIsolateGroupAsNonMutator()

void dart::Thread::ExitIsolateGroupAsNonMutator ( )
static

Definition at line 526 of file thread.cc.

526 {
527 Thread* thread = Thread::Current();
528 ASSERT(thread != nullptr);
529 thread->AssertNonMutatorInvariants();
530
531 thread->ResetState();
532 SuspendThreadInternal(thread, VMTag::kInvalidTagId);
533 FreeActiveThread(thread, /*bypass_safepoint=*/true);
534}

◆ ExitSafepoint()

void dart::Thread::ExitSafepoint ( )
inline

Definition at line 1094 of file thread.h.

1094 {
1095 // First try a fast update of the thread state to indicate it is not at a
1096 // safepoint anymore.
1097 if (!TryExitSafepoint()) {
1098 // Fast update failed which means we could potentially be in the middle
1099 // of a safepoint operation.
1100 ExitSafepointUsingLock();
1101 }
1102 }
bool TryExitSafepoint()
Definition: thread.h:1087

◆ field_table_values_offset()

static intptr_t dart::Thread::field_table_values_offset ( )
inlinestatic

Definition at line 543 of file thread.h.

543 {
544 return OFFSET_OF(Thread, field_table_values_);
545 }

◆ force_growth()

bool dart::Thread::force_growth ( ) const
inline

Definition at line 633 of file thread.h.

633{ return force_growth_scope_depth_ != 0; }

◆ full_safepoint_state_acquired()

static uword dart::Thread::full_safepoint_state_acquired ( )
inlinestatic

Definition at line 1064 of file thread.h.

1064 {
1065 return (1 << AtSafepointField::shift()) |
1066 (1 << AtDeoptSafepointField::shift());
1067 }

◆ full_safepoint_state_unacquired()

static uword dart::Thread::full_safepoint_state_unacquired ( )
inlinestatic

Definition at line 1060 of file thread.h.

1060 {
1061 return (0 << AtSafepointField::shift()) |
1062 (0 << AtDeoptSafepointField::shift());
1063 }

◆ GetAndClearInterrupts()

uword dart::Thread::GetAndClearInterrupts ( )

Definition at line 724 of file thread.cc.

724 {
725 uword interrupt_bits = 0;
726 uword old_limit = stack_limit_.load();
727 uword new_limit = saved_stack_limit_;
728 do {
729 if (IsInterruptLimit(old_limit)) {
730 interrupt_bits = interrupt_bits | (old_limit & kInterruptsMask);
731 } else {
732 return interrupt_bits;
733 }
734 } while (!stack_limit_.compare_exchange_weak(old_limit, new_limit));
735
736 return interrupt_bits;
737}
bool compare_exchange_weak(T &expected, T desired, std::memory_order order=std::memory_order_relaxed)
Definition: atomic.h:52
uintptr_t uword
Definition: globals.h:501
static bool IsInterruptLimit(uword limit)
Definition: thread.cc:705

◆ GetAndClearStackOverflowFlags()

uword dart::Thread::GetAndClearStackOverflowFlags ( )

Definition at line 785 of file thread.cc.

785 {
786 uword stack_overflow_flags = stack_overflow_flags_;
787 stack_overflow_flags_ = 0;
788 return stack_overflow_flags;
789}

◆ GetNextTaskId()

int64_t dart::Thread::GetNextTaskId ( )
inline

Definition at line 1129 of file thread.h.

1129{ return next_task_id_++; }

◆ global_object_pool()

ObjectPoolPtr dart::Thread::global_object_pool ( ) const
inline

Definition at line 792 of file thread.h.

792{ return global_object_pool_; }

◆ global_object_pool_offset()

static intptr_t dart::Thread::global_object_pool_offset ( )
inlinestatic

Definition at line 853 of file thread.h.

853 {
854 return OFFSET_OF(Thread, global_object_pool_);
855 }

◆ HandleInterrupts()

ErrorPtr dart::Thread::HandleInterrupts ( )

Definition at line 739 of file thread.cc.

739 {
740 uword interrupt_bits = GetAndClearInterrupts();
741 if ((interrupt_bits & kVMInterrupt) != 0) {
743 if (isolate_group()->store_buffer()->Overflowed()) {
744 // Evacuate: If the popular store buffer targets are copied instead of
745 // promoted, the store buffer won't shrink and a second scavenge will
746 // occur that does promote them.
748 }
749 heap()->CheckFinalizeMarking(this);
750
751#if !defined(PRODUCT)
752 if (isolate()->TakeHasCompletedBlocks()) {
754 }
755#endif // !defined(PRODUCT)
756
757#if !defined(PRODUCT) || defined(FORCE_INCLUDE_SAMPLING_HEAP_PROFILER)
758 HeapProfileSampler& sampler = heap_sampler();
759 if (sampler.ShouldSetThreadSamplingInterval()) {
760 sampler.SetThreadSamplingInterval();
761 }
762 if (sampler.ShouldUpdateThreadEnable()) {
763 sampler.UpdateThreadEnable();
764 }
765#endif // !defined(PRODUCT) || defined(FORCE_INCLUDE_SAMPLING_HEAP_PROFILER)
766 }
767 if ((interrupt_bits & kMessageInterrupt) != 0) {
770 if (status != MessageHandler::kOK) {
771 // False result from HandleOOBMessages signals that the isolate should
772 // be terminating.
773 if (FLAG_trace_isolates) {
775 "[!] Terminating isolate due to OOB message:\n"
776 "\tisolate: %s\n",
777 isolate()->name());
778 }
779 return StealStickyError();
780 }
781 }
782 return Error::null();
783}
void CheckFinalizeMarking(Thread *thread)
Definition: heap.cc:627
void CollectGarbage(Thread *thread, GCType type, GCReason reason)
Definition: heap.cc:558
MessageHandler * message_handler() const
Definition: isolate.cc:2416
MessageStatus HandleOOBMessages()
static void static void PrintErr(const char *format,...) PRINTF_ATTRIBUTE(1
static void ProcessCompletedBlocks(Isolate *isolate)
Definition: profiler.cc:1837
uword GetAndClearInterrupts()
Definition: thread.cc:724
DART_WARN_UNUSED_RESULT ErrorPtr StealStickyError()
Definition: thread.cc:245
Heap * heap() const
Definition: thread.cc:943
void CheckForSafepoint()
Definition: thread.h:1104
HeapProfileSampler & heap_sampler()
Definition: thread.h:1141
const char *const name

◆ HasActiveState()

bool dart::Thread::HasActiveState ( )

Definition at line 354 of file thread.cc.

354 {
355 // Do we have active dart frames?
356 if (top_exit_frame_info() != 0) {
357 return true;
358 }
359 // Do we have active embedder scopes?
360 if (api_top_scope() != nullptr) {
361 return true;
362 }
363 // Do we have active vm zone?
364 if (zone() != nullptr) {
365 return true;
366 }
368 return false;
369}

◆ HasCompilerState()

bool dart::Thread::HasCompilerState ( ) const
inline

Definition at line 586 of file thread.h.

586{ return compiler_state_ != nullptr; }

◆ HasExitedDartCode()

bool dart::Thread::HasExitedDartCode ( ) const

Definition at line 951 of file thread.cc.

951 {
952 return (top_exit_frame_info() != 0) && !VMTag::IsDartTag(vm_tag());
953}
uword vm_tag() const
Definition: thread.h:821
static bool IsDartTag(uword id)
Definition: tags.h:64

◆ HasScheduledInterrupts()

bool dart::Thread::HasScheduledInterrupts ( ) const
inline

Definition at line 497 of file thread.h.

497 {
498 return (stack_limit_.load() & kInterruptsMask) != 0;
499 }

◆ heap()

Heap * dart::Thread::heap ( ) const

Definition at line 943 of file thread.cc.

943 {
944 return isolate_group_->heap();
945}
Heap * heap() const
Definition: isolate.h:296

◆ heap_base()

uword dart::Thread::heap_base ( ) const
inline

Definition at line 429 of file thread.h.

429 {
430#if defined(DART_COMPRESSED_POINTERS)
431 return heap_base_;
432#else
433 return 0;
434#endif
435 }

◆ heap_sampler()

HeapProfileSampler & dart::Thread::heap_sampler ( )
inline

Definition at line 1141 of file thread.h.

1141{ return heap_sampler_; }

◆ hierarchy_info()

HierarchyInfo * dart::Thread::hierarchy_info ( ) const
inline

Definition at line 593 of file thread.h.

593 {
594 ASSERT(isolate_group_ != nullptr);
595 return hierarchy_info_;
596 }

◆ IncrementAndGetRuntimeCallCount()

uint32_t dart::Thread::IncrementAndGetRuntimeCallCount ( )
inline

Definition at line 451 of file thread.h.

451{ return ++runtime_call_count_; }

◆ IncrementAndGetStackOverflowCount()

int32_t dart::Thread::IncrementAndGetStackOverflowCount ( )
inline

Definition at line 447 of file thread.h.

447 {
448 return ++stack_overflow_count_;
449 }

◆ IncrementForceGrowthScopeDepth()

void dart::Thread::IncrementForceGrowthScopeDepth ( )
inline

Definition at line 634 of file thread.h.

634 {
635 ASSERT(force_growth_scope_depth_ < INT_MAX);
636 force_growth_scope_depth_ += 1;
637 }

◆ IncrementNoCallbackScopeDepth()

void dart::Thread::IncrementNoCallbackScopeDepth ( )
inline

Definition at line 624 of file thread.h.

624 {
625 ASSERT(no_callback_scope_depth_ < INT_MAX);
626 no_callback_scope_depth_ += 1;
627 }

◆ IncrementNoSafepointScopeDepth()

void dart::Thread::IncrementNoSafepointScopeDepth ( )
inline

Definition at line 726 of file thread.h.

726 {
727#if defined(DEBUG)
728 ASSERT(no_safepoint_scope_depth_ < INT_MAX);
729 no_safepoint_scope_depth_ += 1;
730#endif
731 }

◆ InitVMConstants()

void dart::Thread::InitVMConstants ( )

Definition at line 183 of file thread.cc.

183 {
184#if defined(DART_COMPRESSED_POINTERS)
185 heap_base_ = Object::null()->heap_base();
186#endif
187
188#define ASSERT_VM_HEAP(type_name, member_name, init_expr, default_init_value) \
189 ASSERT((init_expr)->IsOldObject());
191#undef ASSERT_VM_HEAP
192
193#define INIT_VALUE(type_name, member_name, init_expr, default_init_value) \
194 ASSERT(member_name == default_init_value); \
195 member_name = (init_expr);
197#undef INIT_VALUE
198
199 for (intptr_t i = 0; i < kNumberOfDartAvailableCpuRegs; ++i) {
200 write_barrier_wrappers_entry_points_[i] =
201 StubCode::WriteBarrierWrappers().EntryPoint() +
203 }
204
205#define INIT_VALUE(name) \
206 ASSERT(name##_entry_point_ == 0); \
207 name##_entry_point_ = k##name##RuntimeEntry.GetEntryPoint();
209#undef INIT_VALUE
210
211#define INIT_VALUE(returntype, name, ...) \
212 ASSERT(name##_entry_point_ == 0); \
213 name##_entry_point_ = k##name##RuntimeEntry.GetEntryPoint();
215#undef INIT_VALUE
216
217// Setup the thread specific reusable handles.
218#define REUSABLE_HANDLE_ALLOCATION(object) \
219 this->object##_handle_ = this->AllocateReusableHandle<object>();
221#undef REUSABLE_HANDLE_ALLOCATION
222}
uword heap_base() const
const intptr_t kStoreBufferWrapperSize
constexpr int kNumberOfDartAvailableCpuRegs
#define RUNTIME_ENTRY_LIST(V)
#define LEAF_RUNTIME_ENTRY_LIST(V)
#define INIT_VALUE(type_name, member_name, init_expr, default_init_value)
#define ASSERT_VM_HEAP(type_name, member_name, init_expr, default_init_value)
#define REUSABLE_HANDLE_ALLOCATION(object)
#define CACHED_CONSTANTS_LIST(V)
Definition: thread.h:267
#define CACHED_VM_OBJECTS_LIST(V)
Definition: thread.h:185

◆ is_marking()

bool dart::Thread::is_marking ( ) const
inline

Definition at line 676 of file thread.h.

676{ return old_marking_stack_block_ != nullptr; }

◆ is_unwind_in_progress()

bool dart::Thread::is_unwind_in_progress ( ) const
inline

Definition at line 643 of file thread.h.

643{ return is_unwind_in_progress_; }

◆ IsAtSafepoint() [1/3]

bool dart::Thread::IsAtSafepoint ( ) const
inline

Definition at line 917 of file thread.h.

917 {
918 // Owning a higher level safepoint implies owning the lower levels as well.
920 }
bool IsAtSafepoint() const
Definition: thread.h:917

◆ IsAtSafepoint() [2/3]

bool dart::Thread::IsAtSafepoint ( SafepointLevel  level) const
inline

Definition at line 921 of file thread.h.

921 {
922 return IsAtSafepoint(level, safepoint_state_.load());
923 }

◆ IsAtSafepoint() [3/3]

static bool dart::Thread::IsAtSafepoint ( SafepointLevel  level,
uword  state 
)
inlinestatic

Definition at line 911 of file thread.h.

911 {
912 const uword mask = AtSafepointBits(level);
913 return (state & mask) == mask;
914 }
AtkStateType state

◆ IsBlockedForSafepoint() [1/2]

bool dart::Thread::IsBlockedForSafepoint ( ) const
inline

Definition at line 999 of file thread.h.

999 {
1000 return BlockedForSafepointField::decode(safepoint_state_);
1001 }

◆ IsBlockedForSafepoint() [2/2]

static bool dart::Thread::IsBlockedForSafepoint ( uword  state)
inlinestatic

Definition at line 996 of file thread.h.

996 {
998 }

◆ IsDartMutatorThread()

bool dart::Thread::IsDartMutatorThread ( ) const
inline

Definition at line 551 of file thread.h.

551 {
552 return scheduled_dart_mutator_isolate_ != nullptr;
553 }

◆ IsExecutingDartCode()

bool dart::Thread::IsExecutingDartCode ( ) const

Definition at line 947 of file thread.cc.

947 {
948 return (top_exit_frame_info() == 0) && VMTag::IsDartTag(vm_tag());
949}

◆ IsInNoReloadScope()

bool dart::Thread::IsInNoReloadScope ( ) const
inline

Definition at line 740 of file thread.h.

740{ return no_reload_scope_depth_ > 0; }

◆ IsInStoppedMutatorsScope()

bool dart::Thread::IsInStoppedMutatorsScope ( ) const
inline

Definition at line 742 of file thread.h.

742 {
743 return stopped_mutators_scope_depth_ > 0;
744 }

◆ isolate()

Isolate * dart::Thread::isolate ( ) const
inline

Definition at line 534 of file thread.h.

534{ return isolate_; }

◆ isolate_group()

IsolateGroup * dart::Thread::isolate_group ( ) const
inline

Definition at line 541 of file thread.h.

541{ return isolate_group_; }

◆ isolate_group_offset()

static intptr_t dart::Thread::isolate_group_offset ( )
inlinestatic

Definition at line 536 of file thread.h.

536 {
537 return OFFSET_OF(Thread, isolate_group_);
538 }

◆ isolate_offset()

static intptr_t dart::Thread::isolate_offset ( )
inlinestatic

Definition at line 535 of file thread.h.

535{ return OFFSET_OF(Thread, isolate_); }

◆ IsSafepointLevelRequested()

static bool dart::Thread::IsSafepointLevelRequested ( uword  state,
SafepointLevel  level 
)
inlinestatic

Definition at line 955 of file thread.h.

955 {
956 switch (level) {
958 return (state & SafepointRequestedField::mask_in_place()) != 0;
960 return (state & DeoptSafepointRequestedField::mask_in_place()) != 0;
962 return (state & ReloadSafepointRequestedField::mask_in_place()) != 0;
963 default:
964 UNREACHABLE();
965 }
966 }
#define UNREACHABLE()
Definition: assert.h:248

◆ IsSafepointLevelRequestedLocked()

bool dart::Thread::IsSafepointLevelRequestedLocked ( SafepointLevel  level) const
inline

Definition at line 948 of file thread.h.

948 {
949 ASSERT(thread_lock()->IsOwnedByCurrentThread());
950 if (level > current_safepoint_level()) return false;
951 const uword state = safepoint_state_.load();
953 }
Monitor * thread_lock() const
Definition: thread.h:502
static bool IsSafepointLevelRequested(uword state, SafepointLevel level)
Definition: thread.h:955
SafepointLevel current_safepoint_level() const
Definition: thread.h:1146

◆ IsSafepointRequested() [1/2]

bool dart::Thread::IsSafepointRequested ( ) const
inline

Definition at line 937 of file thread.h.

937 {
939 }

◆ IsSafepointRequested() [2/2]

bool dart::Thread::IsSafepointRequested ( SafepointLevel  level) const
inline

Definition at line 940 of file thread.h.

940 {
941 const uword state = safepoint_state_.load();
942 for (intptr_t i = level; i >= 0; --i) {
944 return true;
945 }
946 return false;
947 }
SafepointLevel
Definition: thread.h:289

◆ IsSafepointRequestedLocked()

bool dart::Thread::IsSafepointRequestedLocked ( SafepointLevel  level) const
inline

Definition at line 933 of file thread.h.

933 {
934 ASSERT(thread_lock()->IsOwnedByCurrentThread());
936 }

◆ IsValidHandle()

bool dart::Thread::IsValidHandle ( Dart_Handle  object) const

Definition at line 1265 of file thread.cc.

1265 {
1266 return IsValidLocalHandle(object) || IsValidZoneHandle(object) ||
1267 IsValidScopedHandle(object);
1268}
bool IsValidZoneHandle(Dart_Handle object) const
Definition: thread_state.cc:28
bool IsValidScopedHandle(Dart_Handle object) const
Definition: thread_state.cc:50
bool IsValidLocalHandle(Dart_Handle object) const
Definition: thread.cc:1270

◆ IsValidLocalHandle()

bool dart::Thread::IsValidLocalHandle ( Dart_Handle  object) const

Definition at line 1270 of file thread.cc.

1270 {
1271 ApiLocalScope* scope = api_top_scope_;
1272 while (scope != nullptr) {
1273 if (scope->local_handles()->IsValidHandle(object)) {
1274 return true;
1275 }
1276 scope = scope->previous();
1277 }
1278 return false;
1279}
ApiLocalScope * previous() const

◆ MarkingStackAddObject()

void dart::Thread::MarkingStackAddObject ( ObjectPtr  obj)

Definition at line 847 of file thread.cc.

847 {
848 if (obj->IsNewObject()) {
850 } else {
852 }
853}
void NewMarkingStackAddObject(ObjectPtr obj)
Definition: thread.cc:863
void OldMarkingStackAddObject(ObjectPtr obj)
Definition: thread.cc:855

◆ MayAllocateHandles()

virtual bool dart::Thread::MayAllocateHandles ( )
inlinevirtual

Implements dart::ThreadState.

Definition at line 1055 of file thread.h.

1055 {
1056 return (execution_state() == kThreadInVM) ||
1058 }
ExecutionState execution_state() const
Definition: thread.h:1040

◆ new_marking_stack_block_offset()

static intptr_t dart::Thread::new_marking_stack_block_offset ( )
inlinestatic

Definition at line 687 of file thread.h.

687 {
688 return OFFSET_OF(Thread, new_marking_stack_block_);
689 }

◆ NewMarkingStackAddObject()

void dart::Thread::NewMarkingStackAddObject ( ObjectPtr  obj)

Definition at line 863 of file thread.cc.

863 {
864 ASSERT(obj->IsNewObject());
865 new_marking_stack_block_->Push(obj);
866 if (new_marking_stack_block_->IsFull()) {
868 }
869}
void NewMarkingStackBlockProcess()
Definition: thread.cc:837

◆ NewMarkingStackBlockProcess()

void dart::Thread::NewMarkingStackBlockProcess ( )

Definition at line 837 of file thread.cc.

837 {
838 NewMarkingStackRelease();
839 NewMarkingStackAcquire();
840}

◆ next()

Thread * dart::Thread::next ( ) const
inline

Definition at line 1113 of file thread.h.

1113{ return next_; }

◆ next_task_id_offset()

static intptr_t dart::Thread::next_task_id_offset ( )
inlinestatic

Definition at line 1130 of file thread.h.

1130 {
1131 return OFFSET_OF(Thread, next_task_id_);
1132 }

◆ no_callback_scope_depth()

int32_t dart::Thread::no_callback_scope_depth ( ) const
inline

Definition at line 623 of file thread.h.

623{ return no_callback_scope_depth_; }

◆ no_safepoint_scope_depth()

int32_t dart::Thread::no_safepoint_scope_depth ( ) const
inline

Definition at line 718 of file thread.h.

718 {
719#if defined(DEBUG)
720 return no_safepoint_scope_depth_;
721#else
722 return 0;
723#endif
724 }

◆ ObjectAtOffset()

bool dart::Thread::ObjectAtOffset ( intptr_t  offset,
Object object 
)
static

Definition at line 1205 of file thread.cc.

1205 {
1207 // --disassemble-stubs runs before all the references through
1208 // thread have targets
1209 return false;
1210 }
1211
1212#define COMPUTE_OFFSET(type_name, member_name, expr, default_init_value) \
1213 if (Thread::member_name##offset() == offset) { \
1214 *object = expr; \
1215 return true; \
1216 }
1218#undef COMPUTE_OFFSET
1219 return false;
1220}
static Isolate * vm_isolate()
Definition: dart.h:68
static Isolate * Current()
Definition: isolate.h:986
#define COMPUTE_OFFSET(type_name, member_name, expr, default_init_value)

◆ OffsetFromThread() [1/2]

intptr_t dart::Thread::OffsetFromThread ( const Object object)
static

Definition at line 1178 of file thread.cc.

1178 {
1179 // In order to allow us to use assembler helper routines with non-[Code]
1180 // objects *before* stubs are initialized, we only loop ver the stubs if the
1181 // [object] is in fact a [Code] object.
1182 if (object.IsCode()) {
1183#define COMPUTE_OFFSET(type_name, member_name, expr, default_init_value) \
1184 ASSERT((expr)->untag()->InVMIsolateHeap()); \
1185 if (object.ptr() == expr) { \
1186 return Thread::member_name##offset(); \
1187 }
1189#undef COMPUTE_OFFSET
1190 }
1191
1192 // For non [Code] objects we check if the object equals to any of the cached
1193 // non-stub entries.
1194#define COMPUTE_OFFSET(type_name, member_name, expr, default_init_value) \
1195 if (object.ptr() == expr) { \
1196 return Thread::member_name##offset(); \
1197 }
1199#undef COMPUTE_OFFSET
1200
1201 UNREACHABLE();
1202 return -1;
1203}

◆ OffsetFromThread() [2/2]

intptr_t dart::Thread::OffsetFromThread ( const RuntimeEntry runtime_entry)
static

Definition at line 1222 of file thread.cc.

1222 {
1223#define COMPUTE_OFFSET(name) \
1224 if (runtime_entry == &k##name##RuntimeEntry) { \
1225 return Thread::name##_entry_point_offset(); \
1226 }
1228#undef COMPUTE_OFFSET
1229
1230#define COMPUTE_OFFSET(returntype, name, ...) \
1231 if (runtime_entry == &k##name##RuntimeEntry) { \
1232 return Thread::name##_entry_point_offset(); \
1233 }
1235#undef COMPUTE_OFFSET
1236
1237 UNREACHABLE();
1238 return -1;
1239}

◆ old_marking_stack_block_offset()

static intptr_t dart::Thread::old_marking_stack_block_offset ( )
inlinestatic

Definition at line 684 of file thread.h.

684 {
685 return OFFSET_OF(Thread, old_marking_stack_block_);
686 }

◆ OldMarkingStackAddObject()

void dart::Thread::OldMarkingStackAddObject ( ObjectPtr  obj)

Definition at line 855 of file thread.cc.

855 {
856 ASSERT(obj->IsOldObject());
857 old_marking_stack_block_->Push(obj);
858 if (old_marking_stack_block_->IsFull()) {
860 }
861}
void OldMarkingStackBlockProcess()
Definition: thread.cc:832

◆ OldMarkingStackBlockProcess()

void dart::Thread::OldMarkingStackBlockProcess ( )

Definition at line 832 of file thread.cc.

832 {
833 OldMarkingStackRelease();
834 OldMarkingStackAcquire();
835}

◆ OwnsDeoptSafepoint()

bool dart::Thread::OwnsDeoptSafepoint ( ) const

Definition at line 1357 of file thread.cc.

◆ OwnsGCSafepoint()

bool dart::Thread::OwnsGCSafepoint ( ) const

Definition at line 1352 of file thread.cc.

◆ OwnsReloadSafepoint()

bool dart::Thread::OwnsReloadSafepoint ( ) const

Definition at line 1362 of file thread.cc.

◆ OwnsSafepoint()

bool dart::Thread::OwnsSafepoint ( ) const

Definition at line 1367 of file thread.cc.

1367 {
1370}
@ kNoSafepoint
Definition: thread.h:300

◆ pending_deopts()

PendingDeopts & dart::Thread::pending_deopts ( )
inline

Definition at line 1144 of file thread.h.

1144{ return pending_deopts_; }

◆ PrintJSON()

void dart::Thread::PrintJSON ( JSONStream stream) const

◆ random()

Random * dart::Thread::random ( )
inline

Definition at line 1133 of file thread.h.

1133{ return &thread_random_; }

◆ random_offset()

static intptr_t dart::Thread::random_offset ( )
inlinestatic

Definition at line 1134 of file thread.h.

1134{ return OFFSET_OF(Thread, thread_random_); }

◆ ReleaseMarkingStack()

void dart::Thread::ReleaseMarkingStack ( )

◆ ReleaseStoreBuffer()

void dart::Thread::ReleaseStoreBuffer ( )

Definition at line 677 of file thread.cc.

677 {
678 ASSERT(IsAtSafepoint() || OwnsSafepoint() || task_kind_ == kMarkerTask);
679 if (store_buffer_block_ == nullptr || store_buffer_block_->IsEmpty()) {
680 return; // Nothing to release.
681 }
682 // Prevent scheduling another GC by ignoring the threshold.
683 StoreBufferRelease(StoreBuffer::kIgnoreThreshold);
684 // Make sure to get an *empty* block; the isolate needs all entries
685 // at GC time.
686 // TODO(koda): Replace with an epilogue (PrepareAfterGC) that acquires.
687 store_buffer_block_ = isolate_group()->store_buffer()->PopEmptyBlock();
688}
Block * PopEmptyBlock()
StoreBuffer * store_buffer() const
Definition: isolate.h:509
bool IsEmpty() const
Definition: pointer_block.h:35

◆ RememberLiveTemporaries()

void dart::Thread::RememberLiveTemporaries ( )

Definition at line 1149 of file thread.cc.

1149 {
1150 RestoreWriteBarrierInvariant(
1151 RestoreWriteBarrierInvariantOp::kAddToRememberedSet);
1152}

◆ resume_pc()

uword dart::Thread::resume_pc ( ) const
inline

Definition at line 873 of file thread.h.

873{ return resume_pc_; }

◆ resume_pc_offset()

static uword dart::Thread::resume_pc_offset ( )
inlinestatic

Definition at line 875 of file thread.h.

875{ return OFFSET_OF(Thread, resume_pc_); }

◆ safepoint_state()

uword dart::Thread::safepoint_state ( )
inline

Definition at line 1031 of file thread.h.

1031{ return safepoint_state_; }

◆ safepoint_state_offset()

static intptr_t dart::Thread::safepoint_state_offset ( )
inlinestatic

Definition at line 459 of file thread.h.

459 {
460 return OFFSET_OF(Thread, safepoint_state_);
461 }

◆ saved_shadow_call_stack()

uword dart::Thread::saved_shadow_call_stack ( ) const
inline

Definition at line 418 of file thread.h.

418{ return saved_shadow_call_stack_; }

◆ saved_shadow_call_stack_offset()

static uword dart::Thread::saved_shadow_call_stack_offset ( )
inlinestatic

Definition at line 419 of file thread.h.

419 {
420 return OFFSET_OF(Thread, saved_shadow_call_stack_);
421 }

◆ saved_stack_limit()

uword dart::Thread::saved_stack_limit ( ) const
inline

Definition at line 410 of file thread.h.

410{ return saved_stack_limit_; }

◆ saved_stack_limit_offset()

static intptr_t dart::Thread::saved_stack_limit_offset ( )
inlinestatic

Definition at line 407 of file thread.h.

407 {
408 return OFFSET_OF(Thread, saved_stack_limit_);
409 }

◆ scheduled_dart_mutator_isolate()

Isolate * dart::Thread::scheduled_dart_mutator_isolate ( ) const
inline

Definition at line 562 of file thread.h.

562 {
563 return scheduled_dart_mutator_isolate_;
564 }

◆ ScheduleInterrupts()

void dart::Thread::ScheduleInterrupts ( uword  interrupt_bits)

Definition at line 710 of file thread.cc.

710 {
711 ASSERT((interrupt_bits & ~kInterruptsMask) == 0); // Must fit in mask.
712
713 uword old_limit = stack_limit_.load();
714 uword new_limit;
715 do {
716 if (IsInterruptLimit(old_limit)) {
717 new_limit = old_limit | interrupt_bits;
718 } else {
719 new_limit = (kInterruptStackLimit & ~kInterruptsMask) | interrupt_bits;
720 }
721 } while (!stack_limit_.compare_exchange_weak(old_limit, new_limit));
722}
static constexpr uword kInterruptStackLimit
Definition: stack_frame.h:427

◆ service_extension_stream_offset()

static intptr_t dart::Thread::service_extension_stream_offset ( )
inlinestatic

Definition at line 576 of file thread.h.

576 {
577 return OFFSET_OF(Thread, service_extension_stream_);
578 }

◆ set_active_exception()

void dart::Thread::set_active_exception ( const Object value)

Definition at line 224 of file thread.cc.

224 {
225 active_exception_ = value.ptr();
226}
uint8_t value

◆ set_active_stacktrace()

void dart::Thread::set_active_stacktrace ( const Object value)

Definition at line 228 of file thread.cc.

228 {
229 active_stacktrace_ = value.ptr();
230}

◆ set_api_reusable_scope()

void dart::Thread::set_api_reusable_scope ( ApiLocalScope value)
inline

Definition at line 506 of file thread.h.

506 {
507 ASSERT(value == nullptr || api_reusable_scope_ == nullptr);
508 api_reusable_scope_ = value;
509 }

◆ set_api_top_scope()

void dart::Thread::set_api_top_scope ( ApiLocalScope value)
inline

Definition at line 514 of file thread.h.

514{ api_top_scope_ = value; }

◆ set_compiler_timings()

void dart::Thread::set_compiler_timings ( CompilerTimings stats)
inline

Definition at line 619 of file thread.h.

619 {
620 compiler_timings_ = stats;
621 }
dictionary stats
Definition: malisc.py:20

◆ set_dispatch_table_array()

void dart::Thread::set_dispatch_table_array ( const uword array)
inline

Definition at line 798 of file thread.h.

798 {
799 dispatch_table_array_ = array;
800 }

◆ set_end()

void dart::Thread::set_end ( uword  end)
inline

Definition at line 713 of file thread.h.

713{ end_ = end; }
uword end() const
Definition: thread.h:710

◆ set_execution_state()

void dart::Thread::set_execution_state ( ExecutionState  state)
inline

Definition at line 1048 of file thread.h.

1048 {
1049 execution_state_ = static_cast<uword>(state);
1050 }

◆ set_global_object_pool()

void dart::Thread::set_global_object_pool ( ObjectPoolPtr  raw_value)
inline

Definition at line 793 of file thread.h.

793 {
794 global_object_pool_ = raw_value;
795 }

◆ set_hierarchy_info()

void dart::Thread::set_hierarchy_info ( HierarchyInfo value)
inline

Definition at line 598 of file thread.h.

598 {
599 ASSERT(isolate_group_ != nullptr);
600 ASSERT((hierarchy_info_ == nullptr && value != nullptr) ||
601 (hierarchy_info_ != nullptr && value == nullptr));
602 hierarchy_info_ = value;
603 }

◆ set_resume_pc()

void dart::Thread::set_resume_pc ( uword  value)
inline

Definition at line 874 of file thread.h.

874{ resume_pc_ = value; }

◆ set_sticky_error()

void dart::Thread::set_sticky_error ( const Error value)

Definition at line 236 of file thread.cc.

236 {
237 ASSERT(!value.IsNull());
238 sticky_error_ = value.ptr();
239}

◆ set_top()

void dart::Thread::set_top ( uword  top)
inline

Definition at line 712 of file thread.h.

712{ top_ = top; }
uword top() const
Definition: thread.h:709

◆ set_top_exit_frame_info()

void dart::Thread::set_top_exit_frame_info ( uword  top_exit_frame_info)
inline

Definition at line 692 of file thread.h.

692 {
693 top_exit_frame_info_ = top_exit_frame_info;
694 }

◆ set_true_end()

void dart::Thread::set_true_end ( uword  true_end)
inline

Definition at line 714 of file thread.h.

714{ true_end_ = true_end; }
uword true_end() const
Definition: thread.h:711

◆ set_type_usage_info()

void dart::Thread::set_type_usage_info ( TypeUsageInfo value)
inline

Definition at line 610 of file thread.h.

610 {
611 ASSERT(isolate_group_ != nullptr);
612 ASSERT((type_usage_info_ == nullptr && value != nullptr) ||
613 (type_usage_info_ != nullptr && value == nullptr));
614 type_usage_info_ = value;
615 }

◆ set_unboxed_double_runtime_arg()

void dart::Thread::set_unboxed_double_runtime_arg ( double  value)
inline

Definition at line 840 of file thread.h.

840 {
841 unboxed_runtime_arg_.double_storage[0] = value;
842 }
double double_storage[2]
Definition: globals.h:151

◆ set_unboxed_int64_runtime_arg()

void dart::Thread::set_unboxed_int64_runtime_arg ( int64_t  value)
inline

Definition at line 828 of file thread.h.

828 {
829 unboxed_runtime_arg_.int64_storage[0] = value;
830 }
int64_t int64_storage[2]
Definition: globals.h:149

◆ set_unboxed_int64_runtime_second_arg()

void dart::Thread::set_unboxed_int64_runtime_second_arg ( int64_t  value)
inline

Definition at line 834 of file thread.h.

834 {
835 unboxed_runtime_arg_.int64_storage[1] = value;
836 }

◆ set_unboxed_simd128_runtime_arg()

void dart::Thread::set_unboxed_simd128_runtime_arg ( simd128_value_t  value)
inline

Definition at line 846 of file thread.h.

846 {
847 unboxed_runtime_arg_ = value;
848 }

◆ set_vm_tag()

void dart::Thread::set_vm_tag ( uword  tag)
inline

Definition at line 822 of file thread.h.

822{ vm_tag_ = tag; }

◆ SetAtSafepoint()

void dart::Thread::SetAtSafepoint ( bool  value,
SafepointLevel  level 
)
inline

Definition at line 924 of file thread.h.

924 {
925 ASSERT(thread_lock()->IsOwnedByCurrentThread());
927 if (value) {
928 safepoint_state_ |= AtSafepointBits(level);
929 } else {
930 safepoint_state_ &= ~AtSafepointBits(level);
931 }
932 }

◆ SetBlockedForSafepoint()

void dart::Thread::SetBlockedForSafepoint ( bool  value)
inline

Definition at line 1002 of file thread.h.

1002 {
1003 ASSERT(thread_lock()->IsOwnedByCurrentThread());
1004 safepoint_state_ =
1005 BlockedForSafepointField::update(value, safepoint_state_);
1006 }

◆ SetBypassSafepoints()

static uword dart::Thread::SetBypassSafepoints ( bool  value,
uword  state 
)
inlinestatic

Definition at line 1010 of file thread.h.

1010 {
1011 return BypassSafepointsField::update(value, state);
1012 }

◆ SetSafepointRequested()

uword dart::Thread::SetSafepointRequested ( SafepointLevel  level,
bool  value 
)
inline

Definition at line 970 of file thread.h.

970 {
971 ASSERT(thread_lock()->IsOwnedByCurrentThread());
972
973 uword mask = 0;
974 switch (level) {
976 mask = SafepointRequestedField::mask_in_place();
977 break;
979 mask = DeoptSafepointRequestedField::mask_in_place();
980 break;
982 mask = ReloadSafepointRequestedField::mask_in_place();
983 break;
984 default:
985 UNREACHABLE();
986 }
987
988 if (value) {
989 // acquire pulls from the release in TryEnterSafepoint.
990 return safepoint_state_.fetch_or(mask, std::memory_order_acquire);
991 } else {
992 // release pushes to the acquire in TryExitSafepoint.
993 return safepoint_state_.fetch_and(~mask, std::memory_order_release);
994 }
995 }

◆ SetStackLimit()

void dart::Thread::SetStackLimit ( uword  value)

Definition at line 690 of file thread.cc.

690 {
691 // The thread setting the stack limit is not necessarily the thread which
692 // the stack limit is being set on.
693 MonitorLocker ml(&thread_lock_);
694 if (!HasScheduledInterrupts()) {
695 // No interrupt pending, set stack_limit_ too.
696 stack_limit_.store(limit);
697 }
698 saved_stack_limit_ = limit;
699}
void store(T arg, std::memory_order order=std::memory_order_relaxed)
Definition: atomic.h:27
bool HasScheduledInterrupts() const
Definition: thread.h:497
friend class MonitorLocker
Definition: thread.h:1494

◆ SetUnwindErrorInProgress()

void dart::Thread::SetUnwindErrorInProgress ( bool  value)
inline

Definition at line 1016 of file thread.h.

1016 {
1017 const uword mask = UnwindErrorInProgressField::mask_in_place();
1018 if (value) {
1019 safepoint_state_.fetch_or(mask);
1020 } else {
1021 safepoint_state_.fetch_and(~mask);
1022 }
1023 }

◆ shared_field_table_values_offset()

static intptr_t dart::Thread::shared_field_table_values_offset ( )
inlinestatic

Definition at line 547 of file thread.h.

547 {
548 return OFFSET_OF(Thread, shared_field_table_values_);
549 }

◆ stack_limit_address()

uword dart::Thread::stack_limit_address ( ) const
inline

Definition at line 399 of file thread.h.

399 {
400 return reinterpret_cast<uword>(&stack_limit_);
401 }

◆ stack_limit_offset()

static intptr_t dart::Thread::stack_limit_offset ( )
inlinestatic

Definition at line 402 of file thread.h.

402 {
403 return OFFSET_OF(Thread, stack_limit_);
404 }

◆ stack_overflow_flags_offset()

static intptr_t dart::Thread::stack_overflow_flags_offset ( )
inlinestatic

Definition at line 443 of file thread.h.

443 {
444 return OFFSET_OF(Thread, stack_overflow_flags_);
445 }

◆ stack_overflow_shared_stub_entry_point_offset()

static uword dart::Thread::stack_overflow_shared_stub_entry_point_offset ( bool  fpu_regs)
inlinestatic

Definition at line 453 of file thread.h.

453 {
454 return fpu_regs
455 ? stack_overflow_shared_with_fpu_regs_entry_point_offset()
456 : stack_overflow_shared_without_fpu_regs_entry_point_offset();
457 }

◆ StartUnwindError()

void dart::Thread::StartUnwindError ( )
inline

Definition at line 645 of file thread.h.

645 {
646 is_unwind_in_progress_ = true;
648 }
void SetUnwindErrorInProgress(bool value)
Definition: thread.h:1016

◆ StealStickyError()

ErrorPtr dart::Thread::StealStickyError ( )

Definition at line 245 of file thread.cc.

245 {
246 NoSafepointScope no_safepoint;
247 ErrorPtr return_value = sticky_error_;
248 sticky_error_ = Error::null();
249 return return_value;
250}

◆ sticky_error()

ErrorPtr dart::Thread::sticky_error ( ) const

Definition at line 232 of file thread.cc.

232 {
233 return sticky_error_;
234}

◆ store_buffer_block_offset()

static intptr_t dart::Thread::store_buffer_block_offset ( )
inlinestatic

Definition at line 672 of file thread.h.

672 {
673 return OFFSET_OF(Thread, store_buffer_block_);
674 }

◆ StoreBufferAcquireGC()

void dart::Thread::StoreBufferAcquireGC ( )

Definition at line 828 of file thread.cc.

828 {
829 store_buffer_block_ = isolate_group()->store_buffer()->PopNonFullBlock();
830}
Block * PopNonFullBlock()

◆ StoreBufferAddObject()

void dart::Thread::StoreBufferAddObject ( ObjectPtr  obj)

Definition at line 796 of file thread.cc.

796 {
797 ASSERT(this == Thread::Current());
798 store_buffer_block_->Push(obj);
799 if (store_buffer_block_->IsFull()) {
801 }
802}
void StoreBufferBlockProcess(StoreBuffer::ThresholdPolicy policy)
Definition: thread.cc:791

◆ StoreBufferAddObjectGC()

void dart::Thread::StoreBufferAddObjectGC ( ObjectPtr  obj)

Definition at line 804 of file thread.cc.

804 {
805 store_buffer_block_->Push(obj);
806 if (store_buffer_block_->IsFull()) {
808 }
809}

◆ StoreBufferBlockProcess()

void dart::Thread::StoreBufferBlockProcess ( StoreBuffer::ThresholdPolicy  policy)

Definition at line 791 of file thread.cc.

791 {
792 StoreBufferRelease(policy);
793 StoreBufferAcquire();
794}
it will be possible to load the file into Perfetto s trace viewer disable asset Prevents usage of any non test fonts unless they were explicitly Loaded via prefetched default font Indicates whether the embedding started a prefetch of the default font manager before creating the engine run In non interactive keep the shell running after the Dart script has completed enable serial On low power devices with low core running concurrent GC tasks on threads can cause them to contend with the UI thread which could potentially lead to jank This option turns off all concurrent GC activities domain network policy
Definition: switches.h:248

◆ StoreBufferReleaseGC()

void dart::Thread::StoreBufferReleaseGC ( )

Definition at line 821 of file thread.cc.

821 {
822 StoreBufferBlock* block = store_buffer_block_;
823 store_buffer_block_ = nullptr;
826}
void PushBlock(Block *block, ThresholdPolicy policy)
StoreBuffer::Block StoreBufferBlock

◆ task_kind()

TaskKind dart::Thread::task_kind ( ) const
inline

Definition at line 479 of file thread.h.

479{ return task_kind_; }

◆ TaskKindToCString()

const char * dart::Thread::TaskKindToCString ( TaskKind  kind)
static

Definition at line 252 of file thread.cc.

252 {
253 switch (kind) {
254 case kUnknownTask:
255 return "kUnknownTask";
256 case kMutatorTask:
257 return "kMutatorTask";
258 case kCompilerTask:
259 return "kCompilerTask";
260 case kSweeperTask:
261 return "kSweeperTask";
262 case kMarkerTask:
263 return "kMarkerTask";
264 default:
265 UNREACHABLE();
266 return "";
267 }
268}

◆ thread_lock()

Monitor * dart::Thread::thread_lock ( ) const
inline

Definition at line 502 of file thread.h.

502{ return &thread_lock_; }

◆ top()

uword dart::Thread::top ( ) const
inline

Definition at line 709 of file thread.h.

709{ return top_; }

◆ top_exit_frame_info()

uword dart::Thread::top_exit_frame_info ( ) const
inline

Definition at line 691 of file thread.h.

691{ return top_exit_frame_info_; }

◆ top_exit_frame_info_offset()

static intptr_t dart::Thread::top_exit_frame_info_offset ( )
inlinestatic

Definition at line 695 of file thread.h.

695 {
696 return OFFSET_OF(Thread, top_exit_frame_info_);
697 }

◆ top_offset()

static intptr_t dart::Thread::top_offset ( )
inlinestatic

Definition at line 715 of file thread.h.

715{ return OFFSET_OF(Thread, top_); }

◆ true_end()

uword dart::Thread::true_end ( ) const
inline

Definition at line 711 of file thread.h.

711{ return true_end_; }

◆ TryEnterSafepoint()

bool dart::Thread::TryEnterSafepoint ( )
inline

Definition at line 1069 of file thread.h.

1069 {
1070 uword old_state = 0;
1071 uword new_state = AtSafepointBits(current_safepoint_level());
1072 return safepoint_state_.compare_exchange_strong(old_state, new_state,
1073 std::memory_order_release);
1074 }

◆ TryExitSafepoint()

bool dart::Thread::TryExitSafepoint ( )
inline

Definition at line 1087 of file thread.h.

1087 {
1088 uword old_state = AtSafepointBits(current_safepoint_level());
1089 uword new_state = 0;
1090 return safepoint_state_.compare_exchange_strong(old_state, new_state,
1091 std::memory_order_acquire);
1092 }

◆ tsan_utils_offset()

static intptr_t dart::Thread::tsan_utils_offset ( )
inlinestatic

Definition at line 526 of file thread.h.

526{ return OFFSET_OF(Thread, tsan_utils_); }

◆ type_usage_info()

TypeUsageInfo * dart::Thread::type_usage_info ( ) const
inline

Definition at line 605 of file thread.h.

605 {
606 ASSERT(isolate_group_ != nullptr);
607 return type_usage_info_;
608 }

◆ unboxed_double_runtime_arg()

double dart::Thread::unboxed_double_runtime_arg ( ) const
inline

Definition at line 837 of file thread.h.

837 {
838 return unboxed_runtime_arg_.double_storage[0];
839 }

◆ unboxed_int64_runtime_arg()

int64_t dart::Thread::unboxed_int64_runtime_arg ( ) const
inline

Definition at line 825 of file thread.h.

825 {
826 return unboxed_runtime_arg_.int64_storage[0];
827 }

◆ unboxed_int64_runtime_second_arg()

int64_t dart::Thread::unboxed_int64_runtime_second_arg ( ) const
inline

Definition at line 831 of file thread.h.

831 {
832 return unboxed_runtime_arg_.int64_storage[1];
833 }

◆ unboxed_runtime_arg_offset()

static intptr_t dart::Thread::unboxed_runtime_arg_offset ( )
inlinestatic

Definition at line 849 of file thread.h.

849 {
850 return OFFSET_OF(Thread, unboxed_runtime_arg_);
851 }

◆ unboxed_simd128_runtime_arg()

simd128_value_t dart::Thread::unboxed_simd128_runtime_arg ( ) const
inline

Definition at line 843 of file thread.h.

843 {
844 return unboxed_runtime_arg_;
845 }

◆ UnwindErrorInProgress()

bool dart::Thread::UnwindErrorInProgress ( ) const
inline

Definition at line 1013 of file thread.h.

1013 {
1014 return UnwindErrorInProgressField::decode(safepoint_state_);
1015 }

◆ UnwindScopes()

void dart::Thread::UnwindScopes ( uword  stack_marker)

Definition at line 1328 of file thread.cc.

1328 {
1329 // Unwind all scopes using the same stack_marker, i.e. all scopes allocated
1330 // under the same top_exit_frame_info.
1331 ApiLocalScope* scope = api_top_scope_;
1332 while (scope != nullptr && scope->stack_marker() != 0 &&
1333 scope->stack_marker() == stack_marker) {
1334 api_top_scope_ = scope->previous();
1335 delete scope;
1336 scope = api_top_scope_;
1337 }
1338}

◆ VisitObjectPointers()

void dart::Thread::VisitObjectPointers ( ObjectPointerVisitor visitor,
ValidationPolicy  validate_frames 
)

Definition at line 968 of file thread.cc.

969 {
970 ASSERT(visitor != nullptr);
971
972 if (zone() != nullptr) {
973 zone()->VisitObjectPointers(visitor);
974 }
975
976 // Visit objects in thread specific handles area.
977 reusable_handles_.VisitObjectPointers(visitor);
978
979 visitor->VisitPointer(reinterpret_cast<ObjectPtr*>(&global_object_pool_));
980 visitor->VisitPointer(reinterpret_cast<ObjectPtr*>(&active_exception_));
981 visitor->VisitPointer(reinterpret_cast<ObjectPtr*>(&active_stacktrace_));
982 visitor->VisitPointer(reinterpret_cast<ObjectPtr*>(&sticky_error_));
983
984 // Visit the api local scope as it has all the api local handles.
985 ApiLocalScope* scope = api_top_scope_;
986 while (scope != nullptr) {
987 scope->local_handles()->VisitObjectPointers(visitor);
988 scope = scope->previous();
989 }
990
991 // Only the mutator thread can run Dart code.
992 if (IsDartMutatorThread()) {
993 // The MarkTask, which calls this method, can run on a different thread. We
994 // therefore assume the mutator is at a safepoint and we can iterate its
995 // stack.
996 // TODO(vm-team): It would be beneficial to be able to ask the mutator
997 // thread whether it is in fact blocked at the moment (at a "safepoint") so
998 // we can safely iterate its stack.
999 //
1000 // Unfortunately we cannot use `this->IsAtSafepoint()` here because that
1001 // will return `false` even though the mutator thread is waiting for mark
1002 // tasks (which iterate its stack) to finish.
1003 const StackFrameIterator::CrossThreadPolicy cross_thread_policy =
1005
1006 // Iterate over all the stack frames and visit objects on the stack.
1007 StackFrameIterator frames_iterator(top_exit_frame_info(), validation_policy,
1008 this, cross_thread_policy);
1009 StackFrame* frame = frames_iterator.NextFrame();
1010 visitor->set_gc_root_type("frame");
1011 while (frame != nullptr) {
1012 frame->VisitObjectPointers(visitor);
1013 frame = frames_iterator.NextFrame();
1014 }
1015 visitor->clear_gc_root_type();
1016 } else {
1017 // We are not on the mutator thread.
1019 }
1020}
#define RELEASE_ASSERT(cond)
Definition: assert.h:327
void VisitObjectPointers(ObjectPointerVisitor *visitor)
void VisitObjectPointers(ObjectPointerVisitor *visitor)
Definition: handles.cc:20
void VisitObjectPointers(ObjectPointerVisitor *visitor)
Definition: zone.cc:305
double frame
Definition: examples.cpp:31

◆ vm_tag()

uword dart::Thread::vm_tag ( ) const
inline

Definition at line 821 of file thread.h.

821{ return vm_tag_; }

◆ vm_tag_offset()

static intptr_t dart::Thread::vm_tag_offset ( )
inlinestatic

Definition at line 823 of file thread.h.

823{ return OFFSET_OF(Thread, vm_tag_); }

◆ write_barrier_mask()

uword dart::Thread::write_barrier_mask ( ) const
inline

Definition at line 428 of file thread.h.

428{ return write_barrier_mask_; }

◆ write_barrier_mask_offset()

static intptr_t dart::Thread::write_barrier_mask_offset ( )
inlinestatic

Definition at line 437 of file thread.h.

437 {
438 return OFFSET_OF(Thread, write_barrier_mask_);
439 }

◆ write_barrier_wrappers_thread_offset()

static intptr_t dart::Thread::write_barrier_wrappers_thread_offset ( Register  reg)
inlinestatic

Definition at line 753 of file thread.h.

753 {
754 ASSERT((kDartAvailableCpuRegs & (1 << reg)) != 0);
755 intptr_t index = 0;
756 for (intptr_t i = 0; i < kNumberOfCpuRegisters; ++i) {
757 if ((kDartAvailableCpuRegs & (1 << i)) == 0) continue;
758 if (i == reg) break;
759 ++index;
760 }
761 return OFFSET_OF(Thread, write_barrier_wrappers_entry_points_) +
762 index * sizeof(uword);
763 }
@ kNumberOfCpuRegisters
Definition: constants_arm.h:98
constexpr RegList kDartAvailableCpuRegs

◆ WriteBarrierWrappersOffsetForRegister()

static intptr_t dart::Thread::WriteBarrierWrappersOffsetForRegister ( Register  reg)
inlinestatic

Definition at line 765 of file thread.h.

765 {
766 intptr_t index = 0;
767 for (intptr_t i = 0; i < kNumberOfCpuRegisters; ++i) {
768 if ((kDartAvailableCpuRegs & (1 << i)) == 0) continue;
769 if (i == reg) {
770 return index * kStoreBufferWrapperSize;
771 }
772 ++index;
773 }
774 UNREACHABLE();
775 return 0;
776 }

◆ ZoneSizeInBytes()

int dart::Thread::ZoneSizeInBytes ( ) const

Definition at line 1291 of file thread.cc.

1291 {
1292 int total = 0;
1293 ApiLocalScope* scope = api_top_scope_;
1294 while (scope != nullptr) {
1295 total += scope->zone()->SizeInBytes();
1296 scope = scope->previous();
1297 }
1298 return total;
1299}
uintptr_t SizeInBytes() const
Definition: zone.cc:182

Friends And Related Function Documentation

◆ ActiveIsolateScope

friend class ActiveIsolateScope
friend

Definition at line 1474 of file thread.h.

◆ ApiZone

friend class ApiZone
friend

Definition at line 1473 of file thread.h.

◆ compiler::target::Thread

friend class compiler::target::Thread
friend

Definition at line 1486 of file thread.h.

◆ CompilerState

friend class CompilerState
friend

Definition at line 1485 of file thread.h.

◆ CreateWithinExistingIsolateGroup

Isolate * CreateWithinExistingIsolateGroup ( IsolateGroup ,
const char *  ,
char **   
)
friend

Definition at line 1301 of file dart_api_impl.cc.

1303 {
1306
1307 auto spawning_group = group;
1308
1309 Isolate* isolate = reinterpret_cast<Isolate*>(
1310 CreateIsolate(spawning_group, /*is_new_group=*/false, name,
1311 /*isolate_data=*/nullptr, error));
1312 if (isolate == nullptr) return nullptr;
1313
1314 auto source = spawning_group->source();
1315 ASSERT(isolate->source() == source);
1316
1317 return isolate;
1318}
IsolateGroupSource * source() const
Definition: isolate.h:1036
friend class Isolate
Definition: thread.h:1476
#define API_TIMELINE_DURATION(thread)
#define CHECK_NO_ISOLATE(isolate)
Definition: dart_api_impl.h:53
SkBitmap source
Definition: examples.cpp:28
const uint8_t uint32_t uint32_t GError ** error
static Dart_Isolate CreateIsolate(IsolateGroup *group, bool is_new_group, const char *name, void *isolate_data, char **error)

◆ Dart

friend class Dart
friend

Definition at line 1489 of file thread.h.

◆ FieldTable

friend class FieldTable
friend

Definition at line 1487 of file thread.h.

◆ InterruptChecker

friend class InterruptChecker
friend

Definition at line 1475 of file thread.h.

◆ Isolate

friend class Isolate
friend

Definition at line 1476 of file thread.h.

◆ IsolateGroup

friend class IsolateGroup
friend

Definition at line 1477 of file thread.h.

◆ MonitorLocker

friend class MonitorLocker
friend

Definition at line 1494 of file thread.h.

◆ NoActiveIsolateScope

friend class NoActiveIsolateScope
friend

Definition at line 1478 of file thread.h.

◆ NoReloadScope

friend class NoReloadScope
friend

Definition at line 1479 of file thread.h.

◆ RawReloadParticipationScope

friend class RawReloadParticipationScope
friend

Definition at line 1480 of file thread.h.

◆ RestoreWriteBarrierInvariantVisitor

Definition at line 1165 of file thread.h.

◆ RuntimeCallDeoptScope

friend class RuntimeCallDeoptScope
friend

Definition at line 1488 of file thread.h.

◆ Simulator

friend class Simulator
friend

Definition at line 1481 of file thread.h.

◆ StackZone

friend class StackZone
friend

Definition at line 1482 of file thread.h.

◆ StoppedMutatorsScope

friend class StoppedMutatorsScope
friend

Definition at line 1483 of file thread.h.

◆ ThreadRegistry

friend class ThreadRegistry
friend

Definition at line 1484 of file thread.h.

◆ TransitionGeneratedToVM

friend class TransitionGeneratedToVM
friend

Definition at line 1491 of file thread.h.

◆ TransitionVMToGenerated

friend class TransitionVMToGenerated
friend

Definition at line 1493 of file thread.h.


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