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

Unified Diff: net/http2/hpack/decoder/http2_hpack_decoder.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/http2/hpack/decoder/http2_hpack_decoder.h ('k') | net/proxy/proxy_server.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/http2/hpack/decoder/http2_hpack_decoder.cc
diff --git a/net/http2/hpack/decoder/http2_hpack_decoder.cc b/net/http2/hpack/decoder/http2_hpack_decoder.cc
index 390d8287c73d2977d19bdedfef6f00b73f35b5f0..607bec1ecba50d36c755063a4915291d6568399e 100644
--- a/net/http2/hpack/decoder/http2_hpack_decoder.cc
+++ b/net/http2/hpack/decoder/http2_hpack_decoder.cc
@@ -5,6 +5,7 @@
#include "net/http2/hpack/decoder/http2_hpack_decoder.h"
#include "base/logging.h"
+#include "base/trace_event/memory_usage_estimator.h"
#include "net/http2/decoder/decode_status.h"
using base::StringPiece;
@@ -116,6 +117,10 @@ bool Http2HpackDecoder::error_detected() {
return error_detected_;
}
+size_t Http2HpackDecoder::EstimateMemoryUsage() const {
+ return base::trace_event::EstimateMemoryUsage(entry_buffer_);
+}
+
void Http2HpackDecoder::ReportError(StringPiece error_message) {
DVLOG(3) << "Http2HpackDecoder::ReportError is new="
<< (!error_detected_ ? "true" : "false")
« no previous file with comments | « net/http2/hpack/decoder/http2_hpack_decoder.h ('k') | net/proxy/proxy_server.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698