Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1828)

Side by Side Diff: src/isolate.h

Issue 10778036: The deferred handes list belongs to the Isolate and not to the (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Review. Created 8 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « src/heap.cc ('k') | src/isolate.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 the V8 project authors. All rights reserved.
2 // Redistribution and use in source and binary forms, with or without 2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions are 3 // modification, are permitted provided that the following conditions are
4 // met: 4 // met:
5 // 5 //
6 // * Redistributions of source code must retain the above copyright 6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer. 7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above 8 // * Redistributions in binary form must reproduce the above
9 // copyright notice, this list of conditions and the following 9 // copyright notice, this list of conditions and the following
10 // disclaimer in the documentation and/or other materials provided 10 // disclaimer in the documentation and/or other materials provided
(...skipping 1037 matching lines...) Expand 10 before | Expand all | Expand 10 after
1048 return date_cache_; 1048 return date_cache_;
1049 } 1049 }
1050 1050
1051 void set_date_cache(DateCache* date_cache) { 1051 void set_date_cache(DateCache* date_cache) {
1052 if (date_cache != date_cache_) { 1052 if (date_cache != date_cache_) {
1053 delete date_cache_; 1053 delete date_cache_;
1054 } 1054 }
1055 date_cache_ = date_cache; 1055 date_cache_ = date_cache;
1056 } 1056 }
1057 1057
1058 void IterateDeferredHandles(ObjectVisitor* visitor);
1059 void LinkDeferredHandles(DeferredHandles* deferred_handles);
1060 void UnlinkDeferredHandles(DeferredHandles* deferred_handles);
1061
1058 private: 1062 private:
1059 Isolate(); 1063 Isolate();
1060 1064
1061 friend struct GlobalState; 1065 friend struct GlobalState;
1062 friend struct InitializeGlobalState; 1066 friend struct InitializeGlobalState;
1063 1067
1064 enum State { 1068 enum State {
1065 UNINITIALIZED, // Some components may not have been allocated. 1069 UNINITIALIZED, // Some components may not have been allocated.
1066 INITIALIZED // All components are fully initialized. 1070 INITIALIZED // All components are fully initialized.
1067 }; 1071 };
(...skipping 203 matching lines...) Expand 10 before | Expand all | Expand 10 after
1271 // This class is huge and has a number of fields controlled by 1275 // This class is huge and has a number of fields controlled by
1272 // preprocessor defines. Make sure the offsets of these fields agree 1276 // preprocessor defines. Make sure the offsets of these fields agree
1273 // between compilation units. 1277 // between compilation units.
1274 #define ISOLATE_FIELD_OFFSET(type, name, ignored) \ 1278 #define ISOLATE_FIELD_OFFSET(type, name, ignored) \
1275 static const intptr_t name##_debug_offset_; 1279 static const intptr_t name##_debug_offset_;
1276 ISOLATE_INIT_LIST(ISOLATE_FIELD_OFFSET) 1280 ISOLATE_INIT_LIST(ISOLATE_FIELD_OFFSET)
1277 ISOLATE_INIT_ARRAY_LIST(ISOLATE_FIELD_OFFSET) 1281 ISOLATE_INIT_ARRAY_LIST(ISOLATE_FIELD_OFFSET)
1278 #undef ISOLATE_FIELD_OFFSET 1282 #undef ISOLATE_FIELD_OFFSET
1279 #endif 1283 #endif
1280 1284
1285 DeferredHandles* deferred_handles_head_;
1286
1281 friend class ExecutionAccess; 1287 friend class ExecutionAccess;
1282 friend class IsolateInitializer; 1288 friend class IsolateInitializer;
1283 friend class ThreadManager; 1289 friend class ThreadManager;
1284 friend class Simulator; 1290 friend class Simulator;
1285 friend class StackGuard; 1291 friend class StackGuard;
1286 friend class ThreadId; 1292 friend class ThreadId;
1287 friend class TestMemoryAllocatorScope; 1293 friend class TestMemoryAllocatorScope;
1288 friend class v8::Isolate; 1294 friend class v8::Isolate;
1289 friend class v8::Locker; 1295 friend class v8::Locker;
1290 friend class v8::Unlocker; 1296 friend class v8::Unlocker;
(...skipping 137 matching lines...) Expand 10 before | Expand all | Expand 10 after
1428 1434
1429 // Mark the global context with out of memory. 1435 // Mark the global context with out of memory.
1430 inline void Context::mark_out_of_memory() { 1436 inline void Context::mark_out_of_memory() {
1431 global_context()->set_out_of_memory(HEAP->true_value()); 1437 global_context()->set_out_of_memory(HEAP->true_value());
1432 } 1438 }
1433 1439
1434 1440
1435 } } // namespace v8::internal 1441 } } // namespace v8::internal
1436 1442
1437 #endif // V8_ISOLATE_H_ 1443 #endif // V8_ISOLATE_H_
OLDNEW
« no previous file with comments | « src/heap.cc ('k') | src/isolate.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698