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

Unified Diff: net/spdy/buffered_spdy_framer.cc

Issue 2665283003: Improve memory estimate of SpdySessionPool in net/ MemoryDumpProvider. (Closed)
Patch Set: rebased Created 3 years, 10 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
« no previous file with comments | « net/spdy/buffered_spdy_framer.h ('k') | net/spdy/header_coalescer.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/spdy/buffered_spdy_framer.cc
diff --git a/net/spdy/buffered_spdy_framer.cc b/net/spdy/buffered_spdy_framer.cc
index 2ca4b24cc668ff52664398094e26e1420f19c934..332b06bdabafcaf53e2efe1d43cf3572e660c87b 100644
--- a/net/spdy/buffered_spdy_framer.cc
+++ b/net/spdy/buffered_spdy_framer.cc
@@ -10,6 +10,7 @@
#include "base/logging.h"
#include "base/memory/ptr_util.h"
#include "base/strings/string_util.h"
+#include "net/spdy/platform/api/spdy_estimate_memory_usage.h"
namespace net {
@@ -306,4 +307,15 @@ SpdyPriority BufferedSpdyFramer::GetHighestPriority() const {
return spdy_framer_.GetHighestPriority();
}
+size_t BufferedSpdyFramer::EstimateMemoryUsage() const {
+ return SpdyEstimateMemoryUsage(spdy_framer_) +
+ SpdyEstimateMemoryUsage(coalescer_) +
+ SpdyEstimateMemoryUsage(control_frame_fields_) +
+ SpdyEstimateMemoryUsage(goaway_fields_);
+}
+
+size_t BufferedSpdyFramer::GoAwayFields::EstimateMemoryUsage() const {
+ return SpdyEstimateMemoryUsage(debug_data);
+}
+
} // namespace net
« no previous file with comments | « net/spdy/buffered_spdy_framer.h ('k') | net/spdy/header_coalescer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698