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

Unified Diff: src/log.cc

Issue 13529004: Remove LOGGER macro (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Rebase Created 7 years, 8 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
« no previous file with comments | « src/log.h ('k') | src/runtime.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/log.cc
diff --git a/src/log.cc b/src/log.cc
index 81fe19f046b256c86209e1664a23ee7afff3e1fc..9a52d80497583b27890a1bdb6a98204cd1fc01ea 100644
--- a/src/log.cc
+++ b/src/log.cc
@@ -216,9 +216,10 @@ void Profiler::Engage() {
Start();
// Register to get ticks.
- LOGGER->ticker_->SetProfiler(this);
+ Logger* logger = isolate_->logger();
+ logger->ticker_->SetProfiler(this);
- LOGGER->ProfilerBeginEvent();
+ logger->ProfilerBeginEvent();
}
@@ -226,7 +227,7 @@ void Profiler::Disengage() {
if (!engaged_) return;
// Stop receiving ticks.
- LOGGER->ticker_->ClearProfiler();
+ isolate_->logger()->ticker_->ClearProfiler();
// Terminate the worker thread by setting running_ to false,
// inserting a fake element in the queue and then wait for
@@ -778,11 +779,10 @@ void Logger::RegExpCompileEvent(Handle<JSRegExp> regexp, bool in_cache) {
}
-void Logger::LogRuntime(Isolate* isolate,
- Vector<const char> format,
+void Logger::LogRuntime(Vector<const char> format,
JSArray* args) {
if (!log_->IsEnabled() || !FLAG_log_runtime) return;
- HandleScope scope(isolate);
+ HandleScope scope(isolate_);
LogMessageBuilder msg(this);
for (int i = 0; i < format.length(); i++) {
char c = format[i];
@@ -899,12 +899,12 @@ void Logger::DeleteEvent(const char* name, void* object) {
void Logger::NewEventStatic(const char* name, void* object, size_t size) {
- LOGGER->NewEvent(name, object, size);
+ Isolate::Current()->logger()->NewEvent(name, object, size);
}
void Logger::DeleteEventStatic(const char* name, void* object) {
- LOGGER->DeleteEvent(name, object);
+ Isolate::Current()->logger()->DeleteEvent(name, object);
}
void Logger::CallbackEventInternal(const char* prefix, Name* name,
« no previous file with comments | « src/log.h ('k') | src/runtime.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698