summaryrefslogtreecommitdiffstats
path: root/net
diff options
context:
space:
mode:
authormbelshe@chromium.org <mbelshe@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-12-10 01:53:33 +0000
committermbelshe@chromium.org <mbelshe@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-12-10 01:53:33 +0000
commit13b3a8ecb1b5f92760e44e558c1d4ae65936c7b1 (patch)
tree91fcc56b5496b4d3d68b1bab05241c0f18024f68 /net
parent95f0fe745adc36a922f9a4f5bd30f1893546fd8a (diff)
downloadchromium_src-13b3a8ecb1b5f92760e44e558c1d4ae65936c7b1.zip
chromium_src-13b3a8ecb1b5f92760e44e558c1d4ae65936c7b1.tar.gz
chromium_src-13b3a8ecb1b5f92760e44e558c1d4ae65936c7b1.tar.bz2
Add more cwnd histograms - this type partitioned by amount of data
sent across the SpdySession. BUG=none TEST=none Review URL: http://codereview.chromium.org/5760002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@68812 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'net')
-rw-r--r--net/spdy/spdy_session.cc25
-rw-r--r--net/spdy/spdy_session.h1
2 files changed, 26 insertions, 0 deletions
diff --git a/net/spdy/spdy_session.cc b/net/spdy/spdy_session.cc
index d96c784..b883cc2 100644
--- a/net/spdy/spdy_session.cc
+++ b/net/spdy/spdy_session.cc
@@ -235,6 +235,7 @@ SpdySession::SpdySession(const HostPortProxyPair& host_port_proxy_pair,
streams_pushed_and_claimed_count_(0),
streams_abandoned_count_(0),
frames_received_(0),
+ bytes_received_(0),
sent_settings_(false),
received_settings_(false),
stalled_streams_(0),
@@ -584,6 +585,8 @@ void SpdySession::OnReadComplete(int bytes_read) {
return;
}
+ bytes_received_ += bytes_read;
+
// The SpdyFramer will use callbacks onto |this| as it parses frames.
// When errors occur, those callbacks can lead to teardown of all references
// to |this|, so maintain a reference to self during this call for safe
@@ -1401,9 +1404,31 @@ void SpdySession::RecordHistograms() {
const spdy::SpdySetting setting = *it;
switch (setting.first.id()) {
case spdy::SETTINGS_CURRENT_CWND:
+ // Record several different histograms to see if cwnd converges
+ // for larger volumes of data being sent.
UMA_HISTOGRAM_CUSTOM_COUNTS("Net.SpdySettingsCwnd",
setting.second,
1, 200, 100);
+ if (bytes_received_ > 10 * 1024) {
+ UMA_HISTOGRAM_CUSTOM_COUNTS("Net.SpdySettingsCwnd10K",
+ setting.second,
+ 1, 200, 100);
+ if (bytes_received_ > 25 * 1024) {
+ UMA_HISTOGRAM_CUSTOM_COUNTS("Net.SpdySettingsCwnd25K",
+ setting.second,
+ 1, 200, 100);
+ if (bytes_received_ > 50 * 1024) {
+ UMA_HISTOGRAM_CUSTOM_COUNTS("Net.SpdySettingsCwnd50K",
+ setting.second,
+ 1, 200, 100);
+ if (bytes_received_ > 100 * 1024) {
+ UMA_HISTOGRAM_CUSTOM_COUNTS("Net.SpdySettingsCwnd100K",
+ setting.second,
+ 1, 200, 100);
+ }
+ }
+ }
+ }
break;
case spdy::SETTINGS_ROUND_TRIP_TIME:
UMA_HISTOGRAM_CUSTOM_COUNTS("Net.SpdySettingsRTT",
diff --git a/net/spdy/spdy_session.h b/net/spdy/spdy_session.h
index f8fa92a..49f3cf5 100644
--- a/net/spdy/spdy_session.h
+++ b/net/spdy/spdy_session.h
@@ -408,6 +408,7 @@ class SpdySession : public base::RefCounted<SpdySession>,
int streams_pushed_and_claimed_count_;
int streams_abandoned_count_;
int frames_received_;
+ int bytes_received_;
bool sent_settings_; // Did this session send settings when it started.
bool received_settings_; // Did this session receive at least one settings
// frame.