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

Unified Diff: src/compiler.cc

Issue 196723003: Fix for bug 351257: type feedback vector initialization issue. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 9 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 | « no previous file | test/cctest/test-compiler.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/compiler.cc
diff --git a/src/compiler.cc b/src/compiler.cc
index 89864e049ba49fdad495cd2172abf3a347e1fc19..66b950bcb918d220702425e8101869aaf1ffc73a 100644
--- a/src/compiler.cc
+++ b/src/compiler.cc
@@ -142,13 +142,11 @@ void CompilationInfo::Initialize(Isolate* isolate,
}
set_bailout_reason(kUnknown);
- if (!shared_info().is_null()) {
- FixedArray* info_feedback_vector = shared_info()->feedback_vector();
- if (info_feedback_vector->length() > 0) {
- // We should initialize the CompilationInfo feedback vector from the
- // passed in shared info, rather than creating a new one.
- feedback_vector_ = Handle<FixedArray>(info_feedback_vector, isolate);
- }
+ if (!shared_info().is_null() && shared_info()->is_compiled()) {
+ // We should initialize the CompilationInfo feedback vector from the
+ // passed in shared info, rather than creating a new one.
+ feedback_vector_ = Handle<FixedArray>(shared_info()->feedback_vector(),
+ isolate);
}
}
« no previous file with comments | « no previous file | test/cctest/test-compiler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698