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

Unified Diff: base/trace_event/heap_profiler_heap_dump_writer.cc

Issue 2861133002: memory-infra: Move dump level check to observer and rename session state (Closed)
Patch Set: move comment Created 3 years, 7 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
Index: base/trace_event/heap_profiler_heap_dump_writer.cc
diff --git a/base/trace_event/heap_profiler_heap_dump_writer.cc b/base/trace_event/heap_profiler_heap_dump_writer.cc
index 70bd87a44aae07a808ffcc2913f75a20bf0c9ef6..f06f64cde5174ce74251e084ce402f49bb97c070 100644
--- a/base/trace_event/heap_profiler_heap_dump_writer.cc
+++ b/base/trace_event/heap_profiler_heap_dump_writer.cc
@@ -16,9 +16,9 @@
#include "base/logging.h"
#include "base/macros.h"
#include "base/strings/stringprintf.h"
+#include "base/trace_event/heap_profiler_serialization_state.h"
#include "base/trace_event/heap_profiler_stack_frame_deduplicator.h"
#include "base/trace_event/heap_profiler_type_name_deduplicator.h"
-#include "base/trace_event/memory_dump_session_state.h"
#include "base/trace_event/trace_config.h"
#include "base/trace_event/trace_event_argument.h"
#include "base/trace_event/trace_log.h"
@@ -311,11 +311,12 @@ std::unique_ptr<TracedValue> Serialize(const std::set<Entry>& entries) {
std::unique_ptr<TracedValue> ExportHeapDump(
const std::unordered_map<AllocationContext, AllocationMetrics>&
metrics_by_context,
- const MemoryDumpSessionState& session_state) {
+ const HeapProfilerSerializationState& heap_profiler_serialization_state) {
internal::HeapDumpWriter writer(
- session_state.stack_frame_deduplicator(),
- session_state.type_name_deduplicator(),
- session_state.heap_profiler_breakdown_threshold_bytes());
+ heap_profiler_serialization_state.stack_frame_deduplicator(),
+ heap_profiler_serialization_state.type_name_deduplicator(),
+ heap_profiler_serialization_state
+ .heap_profiler_breakdown_threshold_bytes());
return Serialize(writer.Summarize(metrics_by_context));
}

Powered by Google App Engine
This is Rietveld 408576698