| OLD | NEW |
| 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 77 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 88 class ThreadVisitor; // Defined in v8threads.h | 88 class ThreadVisitor; // Defined in v8threads.h |
| 89 class UnicodeCache; | 89 class UnicodeCache; |
| 90 template <StateTag Tag> class VMState; | 90 template <StateTag Tag> class VMState; |
| 91 | 91 |
| 92 // 'void function pointer', used to roundtrip the | 92 // 'void function pointer', used to roundtrip the |
| 93 // ExternalReference::ExternalReferenceRedirector since we can not include | 93 // ExternalReference::ExternalReferenceRedirector since we can not include |
| 94 // assembler.h, where it is defined, here. | 94 // assembler.h, where it is defined, here. |
| 95 typedef void* ExternalReferenceRedirectorPointer(); | 95 typedef void* ExternalReferenceRedirectorPointer(); |
| 96 | 96 |
| 97 | 97 |
| 98 #ifdef ENABLE_DEBUGGER_SUPPORT | |
| 99 class Debug; | 98 class Debug; |
| 100 class Debugger; | 99 class Debugger; |
| 101 class DebuggerAgent; | 100 class DebuggerAgent; |
| 102 #endif | |
| 103 | 101 |
| 104 #if !defined(__arm__) && V8_TARGET_ARCH_ARM || \ | 102 #if !defined(__arm__) && V8_TARGET_ARCH_ARM || \ |
| 105 !defined(__aarch64__) && V8_TARGET_ARCH_ARM64 || \ | 103 !defined(__aarch64__) && V8_TARGET_ARCH_ARM64 || \ |
| 106 !defined(__mips__) && V8_TARGET_ARCH_MIPS | 104 !defined(__mips__) && V8_TARGET_ARCH_MIPS |
| 107 class Redirection; | 105 class Redirection; |
| 108 class Simulator; | 106 class Simulator; |
| 109 #endif | 107 #endif |
| 110 | 108 |
| 111 | 109 |
| 112 // Static indirection table for handles to constants. If a frame | 110 // Static indirection table for handles to constants. If a frame |
| (...skipping 190 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 303 // Head of the list of live LookupResults. | 301 // Head of the list of live LookupResults. |
| 304 LookupResult* top_lookup_result_; | 302 LookupResult* top_lookup_result_; |
| 305 | 303 |
| 306 private: | 304 private: |
| 307 void InitializeInternal(); | 305 void InitializeInternal(); |
| 308 | 306 |
| 309 Address try_catch_handler_address_; | 307 Address try_catch_handler_address_; |
| 310 }; | 308 }; |
| 311 | 309 |
| 312 | 310 |
| 313 #ifdef ENABLE_DEBUGGER_SUPPORT | |
| 314 | |
| 315 #define ISOLATE_DEBUGGER_INIT_LIST(V) \ | |
| 316 V(DebuggerAgent*, debugger_agent_instance, NULL) | |
| 317 #else | |
| 318 | |
| 319 #define ISOLATE_DEBUGGER_INIT_LIST(V) | |
| 320 | |
| 321 #endif | |
| 322 | |
| 323 | |
| 324 #if V8_TARGET_ARCH_ARM && !defined(__arm__) || \ | 311 #if V8_TARGET_ARCH_ARM && !defined(__arm__) || \ |
| 325 V8_TARGET_ARCH_ARM64 && !defined(__aarch64__) || \ | 312 V8_TARGET_ARCH_ARM64 && !defined(__aarch64__) || \ |
| 326 V8_TARGET_ARCH_MIPS && !defined(__mips__) | 313 V8_TARGET_ARCH_MIPS && !defined(__mips__) |
| 327 | 314 |
| 328 #define ISOLATE_INIT_SIMULATOR_LIST(V) \ | 315 #define ISOLATE_INIT_SIMULATOR_LIST(V) \ |
| 329 V(bool, simulator_initialized, false) \ | 316 V(bool, simulator_initialized, false) \ |
| 330 V(HashMap*, simulator_i_cache, NULL) \ | 317 V(HashMap*, simulator_i_cache, NULL) \ |
| 331 V(Redirection*, simulator_redirection, NULL) | 318 V(Redirection*, simulator_redirection, NULL) |
| 332 #else | 319 #else |
| 333 | 320 |
| (...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 386 V(int, ast_node_id, 0) \ | 373 V(int, ast_node_id, 0) \ |
| 387 V(unsigned, ast_node_count, 0) \ | 374 V(unsigned, ast_node_count, 0) \ |
| 388 V(bool, microtask_pending, false) \ | 375 V(bool, microtask_pending, false) \ |
| 389 V(bool, autorun_microtasks, true) \ | 376 V(bool, autorun_microtasks, true) \ |
| 390 V(HStatistics*, hstatistics, NULL) \ | 377 V(HStatistics*, hstatistics, NULL) \ |
| 391 V(HTracer*, htracer, NULL) \ | 378 V(HTracer*, htracer, NULL) \ |
| 392 V(CodeTracer*, code_tracer, NULL) \ | 379 V(CodeTracer*, code_tracer, NULL) \ |
| 393 V(bool, fp_stubs_generated, false) \ | 380 V(bool, fp_stubs_generated, false) \ |
| 394 V(int, max_available_threads, 0) \ | 381 V(int, max_available_threads, 0) \ |
| 395 V(uint32_t, per_isolate_assert_data, 0xFFFFFFFFu) \ | 382 V(uint32_t, per_isolate_assert_data, 0xFFFFFFFFu) \ |
| 396 ISOLATE_INIT_SIMULATOR_LIST(V) \ | 383 V(DebuggerAgent*, debugger_agent_instance, NULL) \ |
| 397 ISOLATE_DEBUGGER_INIT_LIST(V) | 384 ISOLATE_INIT_SIMULATOR_LIST(V) |
| 398 | 385 |
| 399 #define THREAD_LOCAL_TOP_ACCESSOR(type, name) \ | 386 #define THREAD_LOCAL_TOP_ACCESSOR(type, name) \ |
| 400 inline void set_##name(type v) { thread_local_top_.name##_ = v; } \ | 387 inline void set_##name(type v) { thread_local_top_.name##_ = v; } \ |
| 401 inline type name() const { return thread_local_top_.name##_; } | 388 inline type name() const { return thread_local_top_.name##_; } |
| 402 | 389 |
| 403 | 390 |
| 404 class Isolate { | 391 class Isolate { |
| 405 // These forward declarations are required to make the friend declarations in | 392 // These forward declarations are required to make the friend declarations in |
| 406 // PerIsolateThreadData work on some older versions of gcc. | 393 // PerIsolateThreadData work on some older versions of gcc. |
| 407 class ThreadDataTable; | 394 class ThreadDataTable; |
| (...skipping 549 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 957 | 944 |
| 958 RegExpStack* regexp_stack() { return regexp_stack_; } | 945 RegExpStack* regexp_stack() { return regexp_stack_; } |
| 959 | 946 |
| 960 unibrow::Mapping<unibrow::Ecma262Canonicalize>* | 947 unibrow::Mapping<unibrow::Ecma262Canonicalize>* |
| 961 interp_canonicalize_mapping() { | 948 interp_canonicalize_mapping() { |
| 962 return &interp_canonicalize_mapping_; | 949 return &interp_canonicalize_mapping_; |
| 963 } | 950 } |
| 964 | 951 |
| 965 inline bool IsCodePreAgingActive(); | 952 inline bool IsCodePreAgingActive(); |
| 966 | 953 |
| 967 #ifdef ENABLE_DEBUGGER_SUPPORT | |
| 968 Debugger* debugger() { | 954 Debugger* debugger() { |
| 969 if (!NoBarrier_Load(&debugger_initialized_)) InitializeDebugger(); | 955 if (!NoBarrier_Load(&debugger_initialized_)) InitializeDebugger(); |
| 970 return debugger_; | 956 return debugger_; |
| 971 } | 957 } |
| 972 Debug* debug() { | 958 Debug* debug() { |
| 973 if (!NoBarrier_Load(&debugger_initialized_)) InitializeDebugger(); | 959 if (!NoBarrier_Load(&debugger_initialized_)) InitializeDebugger(); |
| 974 return debug_; | 960 return debug_; |
| 975 } | 961 } |
| 976 #endif | |
| 977 | 962 |
| 978 inline bool IsDebuggerActive(); | 963 inline bool IsDebuggerActive(); |
| 979 inline bool DebuggerHasBreakPoints(); | 964 inline bool DebuggerHasBreakPoints(); |
| 980 | 965 |
| 981 CpuProfiler* cpu_profiler() const { return cpu_profiler_; } | 966 CpuProfiler* cpu_profiler() const { return cpu_profiler_; } |
| 982 HeapProfiler* heap_profiler() const { return heap_profiler_; } | 967 HeapProfiler* heap_profiler() const { return heap_profiler_; } |
| 983 | 968 |
| 984 #ifdef DEBUG | 969 #ifdef DEBUG |
| 985 HistogramInfo* heap_histograms() { return heap_histograms_; } | 970 HistogramInfo* heap_histograms() { return heap_histograms_; } |
| 986 | 971 |
| (...skipping 298 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1285 | 1270 |
| 1286 // Time stamp at initialization. | 1271 // Time stamp at initialization. |
| 1287 double time_millis_at_init_; | 1272 double time_millis_at_init_; |
| 1288 | 1273 |
| 1289 #ifdef DEBUG | 1274 #ifdef DEBUG |
| 1290 // A static array of histogram info for each type. | 1275 // A static array of histogram info for each type. |
| 1291 HistogramInfo heap_histograms_[LAST_TYPE + 1]; | 1276 HistogramInfo heap_histograms_[LAST_TYPE + 1]; |
| 1292 JSObject::SpillInformation js_spill_information_; | 1277 JSObject::SpillInformation js_spill_information_; |
| 1293 #endif | 1278 #endif |
| 1294 | 1279 |
| 1295 #ifdef ENABLE_DEBUGGER_SUPPORT | |
| 1296 Debugger* debugger_; | 1280 Debugger* debugger_; |
| 1297 Debug* debug_; | 1281 Debug* debug_; |
| 1298 #endif | |
| 1299 CpuProfiler* cpu_profiler_; | 1282 CpuProfiler* cpu_profiler_; |
| 1300 HeapProfiler* heap_profiler_; | 1283 HeapProfiler* heap_profiler_; |
| 1301 FunctionEntryHook function_entry_hook_; | 1284 FunctionEntryHook function_entry_hook_; |
| 1302 | 1285 |
| 1303 #define GLOBAL_BACKING_STORE(type, name, initialvalue) \ | 1286 #define GLOBAL_BACKING_STORE(type, name, initialvalue) \ |
| 1304 type name##_; | 1287 type name##_; |
| 1305 ISOLATE_INIT_LIST(GLOBAL_BACKING_STORE) | 1288 ISOLATE_INIT_LIST(GLOBAL_BACKING_STORE) |
| 1306 #undef GLOBAL_BACKING_STORE | 1289 #undef GLOBAL_BACKING_STORE |
| 1307 | 1290 |
| 1308 #define GLOBAL_ARRAY_BACKING_STORE(type, name, length) \ | 1291 #define GLOBAL_ARRAY_BACKING_STORE(type, name, length) \ |
| (...skipping 215 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1524 } | 1507 } |
| 1525 | 1508 |
| 1526 EmbeddedVector<char, 128> filename_; | 1509 EmbeddedVector<char, 128> filename_; |
| 1527 FILE* file_; | 1510 FILE* file_; |
| 1528 int scope_depth_; | 1511 int scope_depth_; |
| 1529 }; | 1512 }; |
| 1530 | 1513 |
| 1531 } } // namespace v8::internal | 1514 } } // namespace v8::internal |
| 1532 | 1515 |
| 1533 #endif // V8_ISOLATE_H_ | 1516 #endif // V8_ISOLATE_H_ |
| OLD | NEW |