Chromium Code Reviews

Unified Diff: src/x64/lithium-codegen-x64.cc

Issue 10706002: Implements a new API to set a function entry hook for profiling. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Sketch ARM code stub. Created 8 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
Index: src/x64/lithium-codegen-x64.cc
diff --git a/src/x64/lithium-codegen-x64.cc b/src/x64/lithium-codegen-x64.cc
index a19fcec3b91ae03254b2c764c93cdd16acb99628..8ae7151772761f06c9eb4c70e6a1e8c9b7a23caa 100644
--- a/src/x64/lithium-codegen-x64.cc
+++ b/src/x64/lithium-codegen-x64.cc
@@ -135,6 +135,12 @@ bool LCodeGen::GeneratePrologue() {
}
#endif
+ const FunctionEntryHook* hook_location = V8::GetFunctionEntryHookLocation();
+ if (*hook_location != NULL) {
+ ProfileEntryHookStub stub;
+ __ CallStub(&stub);
+ }
+
// Strict mode functions need to replace the receiver with undefined
// when called as functions (without an explicit receiver
// object). rcx is zero for method calls and non-zero for function

Powered by Google App Engine