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

Unified Diff: src/compiler.cc

Issue 10795074: Add a new API V8::SetJitCodeEventHandler to push code name and location to users such as profilers. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Ready for review Created 8 years, 5 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
Index: src/compiler.cc
diff --git a/src/compiler.cc b/src/compiler.cc
index 998f1bcb20c2c554b23c4e0cd664f57f2949d915..ed847b1bdefb296daa496ffee101b4e6f2585d7a 100644
--- a/src/compiler.cc
+++ b/src/compiler.cc
@@ -30,11 +30,11 @@
#include "compiler.h"
#include "bootstrapper.h"
+#include "code-events.h"
#include "codegen.h"
#include "compilation-cache.h"
#include "debug.h"
#include "full-codegen.h"
-#include "gdb-jit.h"
#include "hydrogen.h"
#include "isolate-inl.h"
#include "lithium.h"
@@ -493,10 +493,10 @@ static Handle<SharedFunctionInfo> MakeFunctionInfo(CompilationInfo* info) {
*info->code(),
*result,
String::cast(script->name())));
- GDBJIT(AddCode(Handle<String>(String::cast(script->name())),
- script,
- info->code(),
- info));
+ JIT_CODE_EVENT(AddCode(Handle<String>(String::cast(script->name())),
danno 2012/07/25 13:50:42 I know this is beyond the scope of your change, bu
Sigurður Ásgeirsson 2012/07/25 14:38:35 It really should be possible to do that, though th
+ script,
+ info->code(),
+ info));
} else {
PROFILE(isolate, CodeCreateEvent(
info->is_eval()
@@ -505,7 +505,7 @@ static Handle<SharedFunctionInfo> MakeFunctionInfo(CompilationInfo* info) {
*info->code(),
*result,
isolate->heap()->empty_string()));
- GDBJIT(AddCode(Handle<String>(), script, info->code(), info));
+ JIT_CODE_EVENT(AddCode(Handle<String>(), script, info->code(), info));
}
// Hint to the runtime system used when allocating space for initial
@@ -1027,10 +1027,10 @@ void Compiler::RecordFunctionCompilation(Logger::LogEventsAndTags tag,
}
}
- GDBJIT(AddCode(Handle<String>(shared->DebugName()),
- Handle<Script>(info->script()),
- Handle<Code>(info->code()),
- info));
+ JIT_CODE_EVENT(AddCode(Handle<String>(shared->DebugName()),
+ Handle<Script>(info->script()),
+ Handle<Code>(info->code()),
+ info));
}
} } // namespace v8::internal

Powered by Google App Engine
This is Rietveld 408576698