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

Unified Diff: test/cctest/test-compiler.cc

Issue 670953003: Move feedback slot allocation to post-pass (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Rebased patch Created 6 years, 1 month 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/preparser.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/cctest/test-compiler.cc
diff --git a/test/cctest/test-compiler.cc b/test/cctest/test-compiler.cc
index d3c06baa45e08198540d007c69db049c21781108..9cda13b4e401636e1298a288e57d028aba3df86f 100644
--- a/test/cctest/test-compiler.cc
+++ b/test/cctest/test-compiler.cc
@@ -348,20 +348,19 @@ TEST(FeedbackVectorUnaffectedByScopeChanges) {
*v8::Handle<v8::Function>::Cast(
CcTest::global()->Get(v8_str("morphing_call"))));
- int expected_slots = 0;
- int expected_ic_slots = FLAG_vector_ics ? 2 : 1;
- CHECK_EQ(expected_slots, f->shared()->feedback_vector()->Slots());
- CHECK_EQ(expected_ic_slots, f->shared()->feedback_vector()->ICSlots());
-
- // And yet it's not compiled.
+ // Not compiled, and so no feedback vector allocated yet.
CHECK(!f->shared()->is_compiled());
+ CHECK_EQ(0, f->shared()->feedback_vector()->Slots());
+ CHECK_EQ(0, f->shared()->feedback_vector()->ICSlots());
CompileRun("morphing_call();");
- // The vector should have the same size despite the new scoping.
+ // Now a feedback vector is allocated.
+ CHECK(f->shared()->is_compiled());
+ int expected_slots = 0;
+ int expected_ic_slots = FLAG_vector_ics ? 2 : 1;
CHECK_EQ(expected_slots, f->shared()->feedback_vector()->Slots());
CHECK_EQ(expected_ic_slots, f->shared()->feedback_vector()->ICSlots());
- CHECK(f->shared()->is_compiled());
}
« no previous file with comments | « src/preparser.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698