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

Side by Side Diff: content/browser/loader/navigation_url_loader_impl.cc

Issue 2359503002: Let TRACE_EVENT_XXX_WITH_TIMESTAMP accept TimeTicks instead of int64_t (Closed)
Patch Set: Rebase Created 4 years, 3 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 unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium 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 #include "content/browser/loader/navigation_url_loader_impl.h" 5 #include "content/browser/loader/navigation_url_loader_impl.h"
6 6
7 #include <utility> 7 #include <utility>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/location.h" 10 #include "base/location.h"
(...skipping 17 matching lines...) Expand all
28 DCHECK_CURRENTLY_ON(BrowserThread::UI); 28 DCHECK_CURRENTLY_ON(BrowserThread::UI);
29 29
30 core_ = new NavigationURLLoaderImplCore(weak_factory_.GetWeakPtr()); 30 core_ = new NavigationURLLoaderImplCore(weak_factory_.GetWeakPtr());
31 31
32 // TODO(carlosk): extend this trace to support non-PlzNavigate navigations. 32 // TODO(carlosk): extend this trace to support non-PlzNavigate navigations.
33 // For the trace below we're using the NavigationURLLoaderImplCore as the 33 // For the trace below we're using the NavigationURLLoaderImplCore as the
34 // async trace id, |navigation_start| as the timestamp and reporting the 34 // async trace id, |navigation_start| as the timestamp and reporting the
35 // FrameTreeNode id as a parameter. 35 // FrameTreeNode id as a parameter.
36 TRACE_EVENT_ASYNC_BEGIN_WITH_TIMESTAMP1( 36 TRACE_EVENT_ASYNC_BEGIN_WITH_TIMESTAMP1(
37 "navigation", "Navigation timeToResponseStarted", core_, 37 "navigation", "Navigation timeToResponseStarted", core_,
38 request_info->common_params.navigation_start.ToInternalValue(), 38 request_info->common_params.navigation_start,
39 "FrameTreeNode id", request_info->frame_tree_node_id); 39 "FrameTreeNode id", request_info->frame_tree_node_id);
40 BrowserThread::PostTask( 40 BrowserThread::PostTask(
41 BrowserThread::IO, FROM_HERE, 41 BrowserThread::IO, FROM_HERE,
42 base::Bind(&NavigationURLLoaderImplCore::Start, base::Unretained(core_), 42 base::Bind(&NavigationURLLoaderImplCore::Start, base::Unretained(core_),
43 browser_context->GetResourceContext(), 43 browser_context->GetResourceContext(),
44 service_worker_context_wrapper, base::Passed(&request_info))); 44 service_worker_context_wrapper, base::Passed(&request_info)));
45 } 45 }
46 46
47 NavigationURLLoaderImpl::~NavigationURLLoaderImpl() { 47 NavigationURLLoaderImpl::~NavigationURLLoaderImpl() {
48 DCHECK_CURRENTLY_ON(BrowserThread::UI); 48 DCHECK_CURRENTLY_ON(BrowserThread::UI);
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after
101 delegate_->OnRequestStarted(timestamp); 101 delegate_->OnRequestStarted(timestamp);
102 } 102 }
103 103
104 void NavigationURLLoaderImpl::NotifyServiceWorkerEncountered() { 104 void NavigationURLLoaderImpl::NotifyServiceWorkerEncountered() {
105 DCHECK_CURRENTLY_ON(BrowserThread::UI); 105 DCHECK_CURRENTLY_ON(BrowserThread::UI);
106 106
107 delegate_->OnServiceWorkerEncountered(); 107 delegate_->OnServiceWorkerEncountered();
108 } 108 }
109 109
110 } // namespace content 110 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/frame_host/navigator_impl.cc ('k') | content/renderer/devtools/v8_sampling_profiler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698