| Index: third_party/WebKit/Source/core/dom/MainThreadTaskRunner.cpp
|
| diff --git a/third_party/WebKit/Source/core/dom/MainThreadTaskRunner.cpp b/third_party/WebKit/Source/core/dom/MainThreadTaskRunner.cpp
|
| index eeb2e78169f82595fd5c9a96b1a81571f1304627..6b66ac43399197e176ae3866fabfa5cad9c4b539 100644
|
| --- a/third_party/WebKit/Source/core/dom/MainThreadTaskRunner.cpp
|
| +++ b/third_party/WebKit/Source/core/dom/MainThreadTaskRunner.cpp
|
| @@ -70,7 +70,7 @@ void MainThreadTaskRunner::postTaskInternal(const WebTraceLocation& location, Pa
|
| void MainThreadTaskRunner::postTask(const WebTraceLocation& location, PassOwnPtr<ExecutionContextTask> task)
|
| {
|
| if (!task->taskNameForInstrumentation().isEmpty())
|
| - InspectorInstrumentation::didPostExecutionContextTask(m_context, task.get());
|
| + InspectorInstrumentation::scheduleAsyncTask(m_context, "postTask", task.get());
|
| postTaskInternal(location, task, false);
|
| }
|
|
|
| @@ -86,12 +86,11 @@ void MainThreadTaskRunner::perform(PassOwnPtr<ExecutionContextTask> task, bool i
|
| return;
|
| }
|
|
|
| - const bool instrumenting = !isInspectorTask && !task->taskNameForInstrumentation().isEmpty();
|
| - if (instrumenting)
|
| - InspectorInstrumentation::willPerformExecutionContextTask(m_context, task.get());
|
| + if (!isInspectorTask)
|
| + InspectorInstrumentation::asyncTaskStarted(m_context, task.get());
|
| task->performTask(m_context);
|
| - if (instrumenting)
|
| - InspectorInstrumentation::didPerformExecutionContextTask(m_context);
|
| + if (!isInspectorTask)
|
| + InspectorInstrumentation::asyncTaskFinished(m_context, task.get());
|
| }
|
|
|
| void MainThreadTaskRunner::suspend()
|
| @@ -117,10 +116,10 @@ void MainThreadTaskRunner::pendingTasksTimerFired(Timer<MainThreadTaskRunner>*)
|
| m_pendingTasks.remove(0);
|
| const bool instrumenting = !task->taskNameForInstrumentation().isEmpty();
|
| if (instrumenting)
|
| - InspectorInstrumentation::willPerformExecutionContextTask(m_context, task.get());
|
| + InspectorInstrumentation::asyncTaskStarted(m_context, task.get());
|
| task->performTask(m_context);
|
| if (instrumenting)
|
| - InspectorInstrumentation::didPerformExecutionContextTask(m_context);
|
| + InspectorInstrumentation::asyncTaskFinished(m_context, task.get());
|
| }
|
| }
|
|
|
|
|