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

Unified Diff: src/cpu-profiler.h

Issue 4888002: [Isolates] Pass isolate to VMState constructor. (Closed)
Patch Set: Created 10 years, 1 month 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 | « src/compiler.cc ('k') | src/execution.cc » ('j') | src/top.cc » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/cpu-profiler.h
diff --git a/src/cpu-profiler.h b/src/cpu-profiler.h
index ecf774ce6e35fff37600bfbf94f74b253cece0d9..9d54984f9520b4d5e7cd2f140deb1a16ffe3621f 100644
--- a/src/cpu-profiler.h
+++ b/src/cpu-profiler.h
@@ -226,6 +226,8 @@ class ProfilerEventsProcessor : public Thread {
namespace v8 {
namespace internal {
+
+// TODO(isolates): isolatify this class.
class CpuProfiler {
public:
static void Setup();
@@ -270,7 +272,10 @@ class CpuProfiler {
static void SetterCallbackEvent(String* name, Address entry_point);
static INLINE(bool is_profiling()) {
- Isolate* isolate = Isolate::Current();
+ return is_profiling(Isolate::Current());
+ }
+
+ static INLINE(bool is_profiling(Isolate* isolate)) {
return isolate->cpu_profiler() != NULL &&
isolate->cpu_profiler()->processor_ != NULL;
}
« no previous file with comments | « src/compiler.cc ('k') | src/execution.cc » ('j') | src/top.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698