Index: src/heap-profiler.cc |
diff --git a/src/heap-profiler.cc b/src/heap-profiler.cc |
index ea17abc33d930dbf2dc2e2fcb755a063eb4380d6..55f09b92831f87e93a3338f1595b07b213b5a676 100644 |
--- a/src/heap-profiler.cc |
+++ b/src/heap-profiler.cc |
@@ -326,20 +326,27 @@ HeapProfiler::~HeapProfiler() { |
delete snapshots_; |
} |
+#endif // ENABLE_LOGGING_AND_PROFILING |
void HeapProfiler::Setup() { |
+#ifdef ENABLE_LOGGING_AND_PROFILING |
if (singleton_ == NULL) { |
singleton_ = new HeapProfiler(); |
} |
+#endif |
} |
void HeapProfiler::TearDown() { |
+#ifdef ENABLE_LOGGING_AND_PROFILING |
delete singleton_; |
singleton_ = NULL; |
+#endif |
} |
+#ifdef ENABLE_LOGGING_AND_PROFILING |
+ |
HeapSnapshot* HeapProfiler::TakeSnapshot(const char* name) { |
ASSERT(singleton_ != NULL); |
return singleton_->TakeSnapshotImpl(name); |