Index: src/api.cc |
diff --git a/src/api.cc b/src/api.cc |
index b33e14c014131e2888f298ff37b8326f8a30eea4..d968bff57065fd5fa80816ddee9a82ba48faf01c 100644 |
--- a/src/api.cc |
+++ b/src/api.cc |
@@ -4831,47 +4831,26 @@ void V8::RemoveMemoryAllocationCallback(MemoryAllocationCallback callback) { |
void V8::PauseProfiler() { |
#ifdef ENABLE_LOGGING_AND_PROFILING |
- PauseProfilerEx(PROFILER_MODULE_CPU); |
+ i::Isolate* isolate = i::Isolate::Current(); |
+ isolate->logger()->PauseProfiler(); |
#endif |
} |
void V8::ResumeProfiler() { |
#ifdef ENABLE_LOGGING_AND_PROFILING |
- ResumeProfilerEx(PROFILER_MODULE_CPU); |
+ i::Isolate* isolate = i::Isolate::Current(); |
+ isolate->logger()->ResumeProfiler(); |
#endif |
} |
bool V8::IsProfilerPaused() { |
#ifdef ENABLE_LOGGING_AND_PROFILING |
- return LOGGER->GetActiveProfilerModules() & PROFILER_MODULE_CPU; |
-#else |
- return true; |
-#endif |
-} |
- |
- |
-void V8::ResumeProfilerEx(int flags, int tag) { |
-#ifdef ENABLE_LOGGING_AND_PROFILING |
i::Isolate* isolate = i::Isolate::Current(); |
- isolate->logger()->ResumeProfiler(flags, tag); |
-#endif |
-} |
- |
- |
-void V8::PauseProfilerEx(int flags, int tag) { |
-#ifdef ENABLE_LOGGING_AND_PROFILING |
- LOGGER->PauseProfiler(flags, tag); |
-#endif |
-} |
- |
- |
-int V8::GetActiveProfilerModules() { |
-#ifdef ENABLE_LOGGING_AND_PROFILING |
- return LOGGER->GetActiveProfilerModules(); |
+ return isolate->logger()->IsProfilerPaused(); |
#else |
- return PROFILER_MODULE_NONE; |
+ return true; |
#endif |
} |