| 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 <list> | 8 #include <list> |
| 9 #include <vector> | 9 #include <vector> |
| 10 | 10 |
| (...skipping 167 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 178 v8::Local<v8::Context> m_pausedContext; | 178 v8::Local<v8::Context> m_pausedContext; |
| 179 bool m_runningNestedMessageLoop; | 179 bool m_runningNestedMessageLoop; |
| 180 int m_ignoreScriptParsedEventsCounter; | 180 int m_ignoreScriptParsedEventsCounter; |
| 181 bool m_scheduledOOMBreak = false; | 181 bool m_scheduledOOMBreak = false; |
| 182 int m_targetContextGroupId = 0; | 182 int m_targetContextGroupId = 0; |
| 183 | 183 |
| 184 using AsyncTaskToStackTrace = | 184 using AsyncTaskToStackTrace = |
| 185 protocol::HashMap<void*, std::weak_ptr<AsyncStackTrace>>; | 185 protocol::HashMap<void*, std::weak_ptr<AsyncStackTrace>>; |
| 186 AsyncTaskToStackTrace m_asyncTaskStacks; | 186 AsyncTaskToStackTrace m_asyncTaskStacks; |
| 187 AsyncTaskToStackTrace m_asyncTaskCreationStacks; | 187 AsyncTaskToStackTrace m_asyncTaskCreationStacks; |
| 188 protocol::HashSet<void*> m_recurringTasks; |
| 189 protocol::HashMap<void*, void*> m_parentTask; |
| 190 |
| 188 int m_maxAsyncCallStacks; | 191 int m_maxAsyncCallStacks; |
| 189 protocol::HashSet<void*> m_recurringTasks; | |
| 190 int m_maxAsyncCallStackDepth; | 192 int m_maxAsyncCallStackDepth; |
| 191 | 193 |
| 192 std::vector<void*> m_currentTasks; | 194 std::vector<void*> m_currentTasks; |
| 193 std::vector<std::shared_ptr<AsyncStackTrace>> m_currentAsyncParent; | 195 std::vector<std::shared_ptr<AsyncStackTrace>> m_currentAsyncParent; |
| 194 std::vector<std::shared_ptr<AsyncStackTrace>> m_currentAsyncCreation; | 196 std::vector<std::shared_ptr<AsyncStackTrace>> m_currentAsyncCreation; |
| 195 | 197 |
| 196 void collectOldAsyncStacksIfNeeded(); | 198 void collectOldAsyncStacksIfNeeded(); |
| 197 void removeOldAsyncTasks(AsyncTaskToStackTrace& map); | 199 void removeOldAsyncTasks(AsyncTaskToStackTrace& map); |
| 198 int m_asyncStacksCount = 0; | 200 int m_asyncStacksCount = 0; |
| 199 // V8Debugger owns all the async stacks, while most of the other references | 201 // V8Debugger owns all the async stacks, while most of the other references |
| 200 // are weak, which allows to collect some stacks when there are too many. | 202 // are weak, which allows to collect some stacks when there are too many. |
| 201 std::list<std::shared_ptr<AsyncStackTrace>> m_allAsyncStacks; | 203 std::list<std::shared_ptr<AsyncStackTrace>> m_allAsyncStacks; |
| 202 | 204 |
| 203 protocol::HashMap<V8DebuggerAgentImpl*, int> m_maxAsyncCallStackDepthMap; | 205 protocol::HashMap<V8DebuggerAgentImpl*, int> m_maxAsyncCallStackDepthMap; |
| 204 protocol::HashMap<void*, void*> m_parentTask; | |
| 205 protocol::HashMap<void*, void*> m_firstNextTask; | |
| 206 void* m_taskWithScheduledBreak = nullptr; | 206 void* m_taskWithScheduledBreak = nullptr; |
| 207 | 207 |
| 208 std::unique_ptr<ScheduleStepIntoAsyncCallback> m_stepIntoAsyncCallback; | 208 std::unique_ptr<ScheduleStepIntoAsyncCallback> m_stepIntoAsyncCallback; |
| 209 bool m_breakRequested = false; | 209 bool m_breakRequested = false; |
| 210 | 210 |
| 211 v8::debug::ExceptionBreakState m_pauseOnExceptionsState; | 211 v8::debug::ExceptionBreakState m_pauseOnExceptionsState; |
| 212 | 212 |
| 213 WasmTranslation m_wasmTranslation; | 213 WasmTranslation m_wasmTranslation; |
| 214 | 214 |
| 215 DISALLOW_COPY_AND_ASSIGN(V8Debugger); | 215 DISALLOW_COPY_AND_ASSIGN(V8Debugger); |
| 216 }; | 216 }; |
| 217 | 217 |
| 218 } // namespace v8_inspector | 218 } // namespace v8_inspector |
| 219 | 219 |
| 220 #endif // V8_INSPECTOR_V8DEBUGGER_H_ | 220 #endif // V8_INSPECTOR_V8DEBUGGER_H_ |
| OLD | NEW |