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

Unified Diff: net/spdy/spdy_session.cc

Issue 2623803002: Avoid creating MemoryAllocatorDump for individual sockets (Closed)
Patch Set: Address Eric's comments Created 3 years, 11 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/spdy_session.h ('k') | net/spdy/spdy_session_pool.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/spdy/spdy_session.cc
diff --git a/net/spdy/spdy_session.cc b/net/spdy/spdy_session.cc
index fe16bf02af011f95f6b1b8ee5322f73d30e73937..275a58002ded46c2002772139f1eb01ac36232e8 100644
--- a/net/spdy/spdy_session.cc
+++ b/net/spdy/spdy_session.cc
@@ -25,8 +25,6 @@
#include "base/strings/utf_string_conversions.h"
#include "base/threading/thread_task_runner_handle.h"
#include "base/time/time.h"
-#include "base/trace_event/memory_allocator_dump.h"
-#include "base/trace_event/process_memory_dump.h"
#include "base/trace_event/trace_event.h"
#include "base/values.h"
#include "crypto/ec_private_key.h"
@@ -1065,15 +1063,10 @@ bool SpdySession::CloseOneIdleConnection() {
return false;
}
-void SpdySession::DumpMemoryStats(
- base::trace_event::ProcessMemoryDump* pmd,
- const std::string& parent_absolute_name) const {
- std::string name =
- base::StringPrintf("%s/session_%p", parent_absolute_name.c_str(), this);
- base::trace_event::MemoryAllocatorDump* session_dump =
- pmd->CreateAllocatorDump(name);
- session_dump->AddString("active", "", is_active() ? "1" : "0");
- connection_->DumpMemoryStats(pmd, name);
+void SpdySession::DumpMemoryStats(StreamSocket::SocketMemoryStats* stats,
+ bool* is_session_active) const {
+ *is_session_active = is_active();
+ connection_->DumpMemoryStats(stats);
}
void SpdySession::EnqueueStreamWrite(
« no previous file with comments | « net/spdy/spdy_session.h ('k') | net/spdy/spdy_session_pool.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698