Profiler experiments: be more careful when accessing TypeFeedbackInfo

Review URL: https://chromiumcodereview.appspot.com/9471008

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@10835 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
parent a19c50af
...@@ -315,6 +315,8 @@ void IC::PostPatching(Address address, Code* target, Code* old_target) { ...@@ -315,6 +315,8 @@ void IC::PostPatching(Address address, Code* target, Code* old_target) {
if (delta != 0) { if (delta != 0) {
Code* host = target->GetHeap()->isolate()-> Code* host = target->GetHeap()->isolate()->
inner_pointer_to_code_cache()->GetCacheEntry(address)->code; inner_pointer_to_code_cache()->GetCacheEntry(address)->code;
// Not all Code objects have TypeFeedbackInfo.
if (host->type_feedback_info()->IsTypeFeedbackInfo()) {
TypeFeedbackInfo* info = TypeFeedbackInfo* info =
TypeFeedbackInfo::cast(host->type_feedback_info()); TypeFeedbackInfo::cast(host->type_feedback_info());
info->set_ic_with_typeinfo_count( info->set_ic_with_typeinfo_count(
...@@ -322,6 +324,7 @@ void IC::PostPatching(Address address, Code* target, Code* old_target) { ...@@ -322,6 +324,7 @@ void IC::PostPatching(Address address, Code* target, Code* old_target) {
} }
} }
} }
}
if (FLAG_watch_ic_patching) { if (FLAG_watch_ic_patching) {
Isolate::Current()->runtime_profiler()->NotifyICChanged(); Isolate::Current()->runtime_profiler()->NotifyICChanged();
// We do not want to optimize until the ICs have settled down, // We do not want to optimize until the ICs have settled down,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment