| OLD | NEW |
| 1 // Copyright 2010 the V8 project authors. All rights reserved. | 1 // Copyright 2010 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 900 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 911 private: | 911 private: |
| 912 PerIsolateThreadData* list_; | 912 PerIsolateThreadData* list_; |
| 913 }; | 913 }; |
| 914 | 914 |
| 915 // These items form a stack synchronously with threads Enter'ing and Exit'ing | 915 // These items form a stack synchronously with threads Enter'ing and Exit'ing |
| 916 // the Isolate. The top of the stack points to a thread which is currently | 916 // the Isolate. The top of the stack points to a thread which is currently |
| 917 // running the Isolate. When the stack is empty, the Isolate is considered | 917 // running the Isolate. When the stack is empty, the Isolate is considered |
| 918 // not entered by any thread and can be Disposed. | 918 // not entered by any thread and can be Disposed. |
| 919 // If the same thread enters the Isolate more then once, the entry_count_ | 919 // If the same thread enters the Isolate more then once, the entry_count_ |
| 920 // is incremented rather then a new item pushed to the stack. | 920 // is incremented rather then a new item pushed to the stack. |
| 921 struct EntryStackItem { | 921 class EntryStackItem { |
| 922 public: | 922 public: |
| 923 EntryStackItem(PerIsolateThreadData* previous_thread_data, | 923 EntryStackItem(PerIsolateThreadData* previous_thread_data, |
| 924 Isolate* previous_isolate, | 924 Isolate* previous_isolate, |
| 925 EntryStackItem* previous_item) | 925 EntryStackItem* previous_item) |
| 926 : entry_count(1), | 926 : entry_count(1), |
| 927 previous_thread_data(previous_thread_data), | 927 previous_thread_data(previous_thread_data), |
| 928 previous_isolate(previous_isolate), | 928 previous_isolate(previous_isolate), |
| 929 previous_item(previous_item) { } | 929 previous_item(previous_item) { } |
| 930 | 930 |
| 931 int entry_count; | 931 int entry_count; |
| (...skipping 334 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1266 | 1266 |
| 1267 } } // namespace v8::internal | 1267 } } // namespace v8::internal |
| 1268 | 1268 |
| 1269 // TODO(isolates): Get rid of these -inl.h includes and place them only where | 1269 // TODO(isolates): Get rid of these -inl.h includes and place them only where |
| 1270 // they're needed. | 1270 // they're needed. |
| 1271 #include "allocation-inl.h" | 1271 #include "allocation-inl.h" |
| 1272 #include "zone-inl.h" | 1272 #include "zone-inl.h" |
| 1273 #include "frames-inl.h" | 1273 #include "frames-inl.h" |
| 1274 | 1274 |
| 1275 #endif // V8_ISOLATE_H_ | 1275 #endif // V8_ISOLATE_H_ |
| OLD | NEW |