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

Side by Side Diff: net/socket/stream_socket.cc

Issue 2414883005: TEMP DO NOT LAND (Closed)
Patch Set: tmp Created 4 years, 1 month 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
« no previous file with comments | « net/socket/stream_socket.h ('k') | net/ssl/ssl_client_session_cache.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 "net/socket/stream_socket.h" 5 #include "net/socket/stream_socket.h"
6 6
7 #include "base/metrics/field_trial.h" 7 #include "base/metrics/field_trial.h"
8 #include "base/metrics/histogram_macros.h" 8 #include "base/metrics/histogram_macros.h"
9 #include "base/strings/string_number_conversions.h" 9 #include "base/strings/string_number_conversions.h"
10 #include "base/values.h" 10 #include "base/values.h"
11 11
12 namespace net { 12 namespace net {
13 13
14 void StreamSocket::PopulateAllocatorDump(
15 base::trace_event::MemoryAllocatorDump* dump) const {}
16
14 StreamSocket::UseHistory::UseHistory() 17 StreamSocket::UseHistory::UseHistory()
15 : was_ever_connected_(false), 18 : was_ever_connected_(false),
16 was_used_to_convey_data_(false), 19 was_used_to_convey_data_(false),
17 omnibox_speculation_(false), 20 omnibox_speculation_(false),
18 subresource_speculation_(false) { 21 subresource_speculation_(false) {
19 } 22 }
20 23
21 StreamSocket::UseHistory::~UseHistory() { 24 StreamSocket::UseHistory::~UseHistory() {
22 EmitPreconnectionHistograms(); 25 EmitPreconnectionHistograms();
23 } 26 }
(...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after
92 result = 0; // Never used, and not really connected. 95 result = 0; // Never used, and not really connected.
93 96
94 if (omnibox_speculation_) 97 if (omnibox_speculation_)
95 result += 3; 98 result += 3;
96 else if (subresource_speculation_) 99 else if (subresource_speculation_)
97 result += 6; 100 result += 6;
98 UMA_HISTOGRAM_ENUMERATION("Net.PreconnectUtilization2", result, 9); 101 UMA_HISTOGRAM_ENUMERATION("Net.PreconnectUtilization2", result, 9);
99 } 102 }
100 103
101 } // namespace net 104 } // namespace net
OLDNEW
« no previous file with comments | « net/socket/stream_socket.h ('k') | net/ssl/ssl_client_session_cache.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698