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

Unified Diff: src/compiler.cc

Issue 1869693003: [compiler] Make feedback vector cope with flag changes. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 4 years, 8 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/mjsunit/regress/regress-crbug-600995.js » ('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 7977bd04d3da23c6ef018fd343906bd241a27e86..d39738215056c644a4507f21393fda7ec5bd28b1 100644
--- a/src/compiler.cc
+++ b/src/compiler.cc
@@ -744,9 +744,11 @@ void EnsureFeedbackVector(CompilationInfo* info) {
if (!info->has_shared_info()) return;
// If no type feedback vector exists, we create one now. At this point the
- // AstNumbering pass has already run. Note that we should reuse any existing
- // feedback vector rather than creating a new one.
- if (info->shared_info()->feedback_vector()->is_empty()) {
+ // AstNumbering pass has already run. Note the snapshot can contain outdated
+ // vectors for a different configuration, hence we also recreate a new vector
+ // when the function is not compiled (i.e. no code was serialized).
+ if (info->shared_info()->feedback_vector()->is_empty() ||
+ !info->shared_info()->is_compiled()) {
Handle<TypeFeedbackMetadata> feedback_metadata = TypeFeedbackMetadata::New(
info->isolate(), info->literal()->feedback_vector_spec());
Handle<TypeFeedbackVector> feedback_vector =
« no previous file with comments | « no previous file | test/mjsunit/regress/regress-crbug-600995.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698