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

Unified Diff: src/compiler.cc

Issue 137403009: Adding a type vector to replace type cells. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Refinements. Created 6 years, 11 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
« src/compiler.h ('K') | « src/compiler.h ('k') | src/full-codegen.h » ('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 b9e13c166172595b298ae227348f5a40a35dca20..af2c78cf74a0d68593e666a59ba67d5fca9509e7 100644
--- a/src/compiler.cc
+++ b/src/compiler.cc
@@ -243,6 +243,33 @@ bool CompilationInfo::ShouldSelfOptimize() {
}
+void CompilationInfo::ProcessFeedbackSlots() {
+ // Scope analysis must have been done.
+ if (function()->slot_count() >= 0) {
mvstanton 2014/01/30 15:13:41 turn this to an assedrt.
mvstanton 2014/01/30 17:37:41 Done.
+ // The work was already done.
+ return;
+ }
+
+ if (function()->slot_nodes() == NULL) {
+ function()->set_slot_count(0);
+ return;
+ }
+
+ int current_slot = 0;
+ for (int i = 0; i < function()->slot_nodes()->length(); i++) {
+ FeedbackSlotInterface* slot_interface =
+ function()->slot_nodes()->at(i);
+ int count = slot_interface->GetFeedbackSlotCount(isolate());
+ if (count > 0) {
+ slot_interface->SetFirstFeedbackSlot(current_slot);
+ current_slot += count;
+ }
+ }
+
+ function()->set_slot_count(current_slot);
+}
+
+
class HOptimizedGraphBuilderWithPositions: public HOptimizedGraphBuilder {
public:
explicit HOptimizedGraphBuilderWithPositions(CompilationInfo* info)
« src/compiler.h ('K') | « src/compiler.h ('k') | src/full-codegen.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698