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

Unified Diff: src/ic-inl.h

Issue 8700008: New approach to Crankshaft decision-making (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: address comments Created 9 years 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/ic.cc ('k') | src/isolate.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/ic-inl.h
diff --git a/src/ic-inl.h b/src/ic-inl.h
index 56cea817600c29748fc0e9cd9e0037d3b70cd20d..93c2f948d62402e60ab2a9c9b7ee42ae5ef5f7d8 100644
--- a/src/ic-inl.h
+++ b/src/ic-inl.h
@@ -29,6 +29,8 @@
#define V8_IC_INL_H_
#include "ic.h"
+
+#include "compiler.h"
#include "debug.h"
#include "macro-assembler.h"
@@ -89,6 +91,21 @@ void IC::SetTargetAtAddress(Address address, Code* target) {
Assembler::set_target_address_at(address, target->instruction_start());
target->GetHeap()->incremental_marking()->RecordCodeTargetPatch(address,
target);
+ Isolate::Current()->runtime_profiler()->NotifyICChanged();
+ StackFrameIterator it;
+ if (it.done()) return;
+ it.Advance();
+ static const int kStackFramesToMark = Compiler::kMaxInliningLevels - 1;
+ for (int i = 0; i < kStackFramesToMark; ++i) {
+ if (it.done()) return;
+ StackFrame* raw_frame = it.frame();
+ if (raw_frame->is_java_script()) {
+ JSFunction* function =
+ JSFunction::cast(JavaScriptFrame::cast(raw_frame)->function());
+ function->shared()->set_profiler_ticks(0);
+ }
+ it.Advance();
+ }
}
« no previous file with comments | « src/ic.cc ('k') | src/isolate.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698