| Index: src/isolate.h
|
| diff --git a/src/isolate.h b/src/isolate.h
|
| index 97854f22eb5b74df4b55da4d37ddf4855180647b..5b1e77f20e1ea6305f8db960cf3715091f606946 100644
|
| --- a/src/isolate.h
|
| +++ b/src/isolate.h
|
| @@ -478,6 +478,8 @@ class Isolate {
|
|
|
| static void GlobalTearDown();
|
|
|
| + bool IsDefaultIsolate() const { return this == default_isolate_; }
|
| +
|
| static void SetCrashIfDefaultIsolateInitialized();
|
| // Ensures that process-wide resources and the default isolate have been
|
| // allocated. It is only necessary to call this method in rare cases, for
|
| @@ -1132,12 +1134,14 @@ class Isolate {
|
| DISALLOW_COPY_AND_ASSIGN(EntryStackItem);
|
| };
|
|
|
| - // This mutex protects highest_thread_id_ and thread_data_table_.
|
| + // This mutex protects highest_thread_id_, thread_data_table_ and
|
| + // default_isolate_.
|
| static Mutex process_wide_mutex_;
|
|
|
| static Thread::LocalStorageKey per_isolate_thread_data_key_;
|
| static Thread::LocalStorageKey isolate_key_;
|
| static Thread::LocalStorageKey thread_id_key_;
|
| + static Isolate* default_isolate_;
|
| static ThreadDataTable* thread_data_table_;
|
|
|
| // A global counter for all generated Isolates, might overflow.
|
|
|