Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(815)

Unified Diff: Source/core/inspector/InspectorDebuggerAgent.h

Issue 855383002: DevTools: use async operation id instead of AsyncCallChain (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Addressed comments Created 5 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: Source/core/inspector/InspectorDebuggerAgent.h
diff --git a/Source/core/inspector/InspectorDebuggerAgent.h b/Source/core/inspector/InspectorDebuggerAgent.h
index 3d63564dea901c08f080cbe2cf4cc336172a1dcc..6b2e89b667412e7381e41def9d28f07f5fb6f232 100644
--- a/Source/core/inspector/InspectorDebuggerAgent.h
+++ b/Source/core/inspector/InspectorDebuggerAgent.h
@@ -49,6 +49,7 @@
namespace blink {
class AsyncCallChain;
+class AsyncCallStack;
class ConsoleMessage;
class InjectedScript;
class InjectedScriptManager;
@@ -172,11 +173,12 @@ public:
// Async call stacks implementation
PassRefPtrWillBeRawPtr<ScriptAsyncCallStack> currentAsyncStackTraceForConsole();
- PassRefPtrWillBeRawPtr<AsyncCallChain> traceAsyncOperationStarting(const String& description);
- void traceAsyncCallbackStarting(v8::Isolate*, PassRefPtrWillBeRawPtr<AsyncCallChain>);
+ static const int unknownAsyncOperationId;
+ int traceAsyncOperationStarting(const String& description);
+ void traceAsyncCallbackStarting(v8::Isolate*, int operationId);
const AsyncCallChain* currentAsyncCallChain() const;
void traceAsyncCallbackCompleted();
- void traceAsyncOperationCompleted(AsyncCallChain*);
+ void traceAsyncOperationCompleted(int operationId);
bool trackingAsyncCalls() const { return m_maxAsyncCallStackDepth; }
class AsyncCallTrackingListener : public WillBeGarbageCollectedMixin {
@@ -218,7 +220,6 @@ private:
PassRefPtr<TypeBuilder::Debugger::StackTrace> currentAsyncStackTrace();
void resetAsyncCallTracker();
- void didCreateAsyncCallChain(AsyncCallChain*);
void changeJavaScriptRecursionLevel(int step);
@@ -286,7 +287,10 @@ private:
OwnPtrWillBeMember<V8AsyncCallTracker> m_v8AsyncCallTracker;
OwnPtrWillBeMember<PromiseTracker> m_promiseTracker;
- WillBeHeapHashSet<RefPtrWillBeMember<AsyncCallChain> > m_asyncOperationsForStepInto;
+ using AsyncOperationIdToAsyncCallChain = WillBeHeapHashMap<int, RefPtrWillBeMember<AsyncCallChain>>;
+ AsyncOperationIdToAsyncCallChain m_asyncOperations;
+ int m_lastAsyncOperationId;
+ WillBeHeapHashSet<int> m_asyncOperationsForStepInto;
unsigned m_maxAsyncCallStackDepth;
RefPtrWillBeMember<AsyncCallChain> m_currentAsyncCallChain;
unsigned m_nestedAsyncCallCount;

Powered by Google App Engine
This is Rietveld 408576698