OLD | NEW |
1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef V8_ISOLATE_H_ | 5 #ifndef V8_ISOLATE_H_ |
6 #define V8_ISOLATE_H_ | 6 #define V8_ISOLATE_H_ |
7 | 7 |
8 #include <memory> | 8 #include <memory> |
9 #include <queue> | 9 #include <queue> |
10 | 10 |
(...skipping 16 matching lines...) Expand all Loading... |
27 #include "src/zone/zone.h" | 27 #include "src/zone/zone.h" |
28 | 28 |
29 class TestIsolate; | 29 class TestIsolate; |
30 | 30 |
31 namespace v8 { | 31 namespace v8 { |
32 | 32 |
33 namespace base { | 33 namespace base { |
34 class RandomNumberGenerator; | 34 class RandomNumberGenerator; |
35 } | 35 } |
36 | 36 |
| 37 namespace debug { |
| 38 class ConsoleDelegate; |
| 39 } |
| 40 |
37 namespace internal { | 41 namespace internal { |
38 | 42 |
39 class AccessCompilerData; | 43 class AccessCompilerData; |
40 class AddressToIndexHashMap; | 44 class AddressToIndexHashMap; |
41 class AstStringConstants; | 45 class AstStringConstants; |
42 class BasicBlockProfiler; | 46 class BasicBlockProfiler; |
43 class Bootstrapper; | 47 class Bootstrapper; |
44 class CancelableTaskManager; | 48 class CancelableTaskManager; |
45 class CallInterfaceDescriptorData; | 49 class CallInterfaceDescriptorData; |
46 class CodeAgingHelper; | 50 class CodeAgingHelper; |
(...skipping 695 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
742 Object* Throw(Object* exception, MessageLocation* location = NULL); | 746 Object* Throw(Object* exception, MessageLocation* location = NULL); |
743 Object* ThrowIllegalOperation(); | 747 Object* ThrowIllegalOperation(); |
744 | 748 |
745 template <typename T> | 749 template <typename T> |
746 MUST_USE_RESULT MaybeHandle<T> Throw(Handle<Object> exception, | 750 MUST_USE_RESULT MaybeHandle<T> Throw(Handle<Object> exception, |
747 MessageLocation* location = NULL) { | 751 MessageLocation* location = NULL) { |
748 Throw(*exception, location); | 752 Throw(*exception, location); |
749 return MaybeHandle<T>(); | 753 return MaybeHandle<T>(); |
750 } | 754 } |
751 | 755 |
| 756 void set_console_delegate(debug::ConsoleDelegate* delegate) { |
| 757 console_delegate_ = delegate; |
| 758 } |
| 759 debug::ConsoleDelegate* console_delegate() { return console_delegate_; } |
| 760 |
752 // Re-throw an exception. This involves no error reporting since error | 761 // Re-throw an exception. This involves no error reporting since error |
753 // reporting was handled when the exception was thrown originally. | 762 // reporting was handled when the exception was thrown originally. |
754 Object* ReThrow(Object* exception); | 763 Object* ReThrow(Object* exception); |
755 | 764 |
756 // Find the correct handler for the current pending exception. This also | 765 // Find the correct handler for the current pending exception. This also |
757 // clears and returns the current pending exception. | 766 // clears and returns the current pending exception. |
758 Object* UnwindAndFindHandler(); | 767 Object* UnwindAndFindHandler(); |
759 | 768 |
760 // Tries to predict whether an exception will be caught. Note that this can | 769 // Tries to predict whether an exception will be caught. Note that this can |
761 // only produce an estimate, because it is undecidable whether a finally | 770 // only produce an estimate, because it is undecidable whether a finally |
(...skipping 783 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1545 BasicBlockProfiler* basic_block_profiler_; | 1554 BasicBlockProfiler* basic_block_profiler_; |
1546 | 1555 |
1547 List<Object*> partial_snapshot_cache_; | 1556 List<Object*> partial_snapshot_cache_; |
1548 | 1557 |
1549 v8::ArrayBuffer::Allocator* array_buffer_allocator_; | 1558 v8::ArrayBuffer::Allocator* array_buffer_allocator_; |
1550 | 1559 |
1551 FutexWaitListNode futex_wait_list_node_; | 1560 FutexWaitListNode futex_wait_list_node_; |
1552 | 1561 |
1553 CancelableTaskManager* cancelable_task_manager_; | 1562 CancelableTaskManager* cancelable_task_manager_; |
1554 | 1563 |
| 1564 debug::ConsoleDelegate* console_delegate_ = nullptr; |
| 1565 |
1555 v8::Isolate::AbortOnUncaughtExceptionCallback | 1566 v8::Isolate::AbortOnUncaughtExceptionCallback |
1556 abort_on_uncaught_exception_callback_; | 1567 abort_on_uncaught_exception_callback_; |
1557 | 1568 |
1558 #ifdef USE_SIMULATOR | 1569 #ifdef USE_SIMULATOR |
1559 base::Mutex simulator_i_cache_mutex_; | 1570 base::Mutex simulator_i_cache_mutex_; |
1560 #endif | 1571 #endif |
1561 | 1572 |
1562 bool allow_atomics_wait_; | 1573 bool allow_atomics_wait_; |
1563 | 1574 |
1564 ManagedObjectFinalizer managed_object_finalizers_list_; | 1575 ManagedObjectFinalizer managed_object_finalizers_list_; |
(...skipping 232 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1797 | 1808 |
1798 EmbeddedVector<char, 128> filename_; | 1809 EmbeddedVector<char, 128> filename_; |
1799 FILE* file_; | 1810 FILE* file_; |
1800 int scope_depth_; | 1811 int scope_depth_; |
1801 }; | 1812 }; |
1802 | 1813 |
1803 } // namespace internal | 1814 } // namespace internal |
1804 } // namespace v8 | 1815 } // namespace v8 |
1805 | 1816 |
1806 #endif // V8_ISOLATE_H_ | 1817 #endif // V8_ISOLATE_H_ |
OLD | NEW |