OLD | NEW |
1 // Copyright 2016 the V8 project authors. All rights reserved. | 1 // Copyright 2016 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_INSPECTOR_V8DEBUGGER_H_ | 5 #ifndef V8_INSPECTOR_V8DEBUGGER_H_ |
6 #define V8_INSPECTOR_V8DEBUGGER_H_ | 6 #define V8_INSPECTOR_V8DEBUGGER_H_ |
7 | 7 |
8 #include <vector> | 8 #include <vector> |
9 | 9 |
10 #include "src/base/macros.h" | 10 #include "src/base/macros.h" |
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
70 void getCompiledScripts(int contextGroupId, | 70 void getCompiledScripts(int contextGroupId, |
71 std::vector<std::unique_ptr<V8DebuggerScript>>&); | 71 std::vector<std::unique_ptr<V8DebuggerScript>>&); |
72 void enable(); | 72 void enable(); |
73 void disable(); | 73 void disable(); |
74 | 74 |
75 bool isPaused() const { return m_runningNestedMessageLoop; } | 75 bool isPaused() const { return m_runningNestedMessageLoop; } |
76 v8::Local<v8::Context> pausedContext() { return m_pausedContext; } | 76 v8::Local<v8::Context> pausedContext() { return m_pausedContext; } |
77 | 77 |
78 int maxAsyncCallChainDepth() { return m_maxAsyncCallStackDepth; } | 78 int maxAsyncCallChainDepth() { return m_maxAsyncCallStackDepth; } |
79 V8StackTraceImpl* currentAsyncCallChain(); | 79 V8StackTraceImpl* currentAsyncCallChain(); |
| 80 V8StackTraceImpl* currentAsyncTaskCreationStack(); |
80 void setAsyncCallStackDepth(V8DebuggerAgentImpl*, int); | 81 void setAsyncCallStackDepth(V8DebuggerAgentImpl*, int); |
81 std::unique_ptr<V8StackTraceImpl> createStackTrace(v8::Local<v8::StackTrace>); | 82 std::unique_ptr<V8StackTraceImpl> createStackTrace(v8::Local<v8::StackTrace>); |
82 std::unique_ptr<V8StackTraceImpl> captureStackTrace(bool fullStack); | 83 std::unique_ptr<V8StackTraceImpl> captureStackTrace(bool fullStack); |
83 | 84 |
84 v8::MaybeLocal<v8::Array> internalProperties(v8::Local<v8::Context>, | 85 v8::MaybeLocal<v8::Array> internalProperties(v8::Local<v8::Context>, |
85 v8::Local<v8::Value>); | 86 v8::Local<v8::Value>); |
86 | 87 |
87 void asyncTaskScheduled(const StringView& taskName, void* task, | 88 void asyncTaskScheduled(const StringView& taskName, void* task, |
88 bool recurring); | 89 bool recurring); |
89 void asyncTaskCanceled(void* task); | 90 void asyncTaskCanceled(void* task); |
(...skipping 92 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
182 AsyncTaskToStackTrace m_asyncTaskStacks; | 183 AsyncTaskToStackTrace m_asyncTaskStacks; |
183 AsyncTaskToStackTrace m_asyncTaskCreationStacks; | 184 AsyncTaskToStackTrace m_asyncTaskCreationStacks; |
184 int m_maxAsyncCallStacks; | 185 int m_maxAsyncCallStacks; |
185 std::map<int, void*> m_idToTask; | 186 std::map<int, void*> m_idToTask; |
186 std::unordered_map<void*, int> m_taskToId; | 187 std::unordered_map<void*, int> m_taskToId; |
187 int m_lastTaskId; | 188 int m_lastTaskId; |
188 protocol::HashSet<void*> m_recurringTasks; | 189 protocol::HashSet<void*> m_recurringTasks; |
189 int m_maxAsyncCallStackDepth; | 190 int m_maxAsyncCallStackDepth; |
190 std::vector<void*> m_currentTasks; | 191 std::vector<void*> m_currentTasks; |
191 std::vector<std::unique_ptr<V8StackTraceImpl>> m_currentStacks; | 192 std::vector<std::unique_ptr<V8StackTraceImpl>> m_currentStacks; |
| 193 std::vector<std::unique_ptr<V8StackTraceImpl>> m_currentCreationStacks; |
192 protocol::HashMap<V8DebuggerAgentImpl*, int> m_maxAsyncCallStackDepthMap; | 194 protocol::HashMap<V8DebuggerAgentImpl*, int> m_maxAsyncCallStackDepthMap; |
193 protocol::HashMap<void*, void*> m_parentTask; | 195 protocol::HashMap<void*, void*> m_parentTask; |
194 protocol::HashMap<void*, void*> m_firstNextTask; | 196 protocol::HashMap<void*, void*> m_firstNextTask; |
195 void* m_taskWithScheduledBreak = nullptr; | 197 void* m_taskWithScheduledBreak = nullptr; |
196 | 198 |
197 std::unique_ptr<ScheduleStepIntoAsyncCallback> m_stepIntoAsyncCallback; | 199 std::unique_ptr<ScheduleStepIntoAsyncCallback> m_stepIntoAsyncCallback; |
198 bool m_breakRequested = false; | 200 bool m_breakRequested = false; |
199 | 201 |
200 v8::debug::ExceptionBreakState m_pauseOnExceptionsState; | 202 v8::debug::ExceptionBreakState m_pauseOnExceptionsState; |
201 | 203 |
202 WasmTranslation m_wasmTranslation; | 204 WasmTranslation m_wasmTranslation; |
203 | 205 |
204 DISALLOW_COPY_AND_ASSIGN(V8Debugger); | 206 DISALLOW_COPY_AND_ASSIGN(V8Debugger); |
205 }; | 207 }; |
206 | 208 |
207 } // namespace v8_inspector | 209 } // namespace v8_inspector |
208 | 210 |
209 #endif // V8_INSPECTOR_V8DEBUGGER_H_ | 211 #endif // V8_INSPECTOR_V8DEBUGGER_H_ |
OLD | NEW |