Index: base/trace_event/memory_dump_manager.cc |
diff --git a/base/trace_event/memory_dump_manager.cc b/base/trace_event/memory_dump_manager.cc |
index e526ee606255691a4d624897eeec79df1dfd7aa8..7f9c2060f6c3cae178299c8171362b4269383c65 100644 |
--- a/base/trace_event/memory_dump_manager.cc |
+++ b/base/trace_event/memory_dump_manager.cc |
@@ -195,13 +195,11 @@ void MemoryDumpManager::EnableHeapProfilingIfNeeded() { |
if (profiling_mode == "") { |
AllocationContextTracker::SetCaptureMode( |
AllocationContextTracker::CaptureMode::PSEUDO_STACK); |
-#if (BUILDFLAG(CAN_UNWIND_WITH_FRAME_POINTERS) || !defined(NDEBUG)) |
} else if (profiling_mode == switches::kEnableHeapProfilingModeNative) { |
- // We need frame pointers for native tracing to work, and they are |
- // enabled in profiling and debug builds. |
+ // If we don't have frame pointers then native tracing falls-back to |
+ // using base::debug::StackTrace, which may be slow. |
AllocationContextTracker::SetCaptureMode( |
AllocationContextTracker::CaptureMode::NATIVE_STACK); |
-#endif |
#if BUILDFLAG(ENABLE_MEMORY_TASK_PROFILER) |
} else if (profiling_mode == switches::kEnableHeapProfilingTaskProfiler) { |
// Enable heap tracking, which in turn enables capture of heap usage |