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

Side by Side Diff: src/ast/ast-numbering.cc

Issue 2614373002: [FeedbackVector] Infrastructure for literal arrays in the vector. (Closed)
Patch Set: Release compile fix. Created 3 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 unified diff | Download patch
« no previous file with comments | « src/ast/ast.h ('k') | src/builtins/builtins-constructor.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "src/ast/ast-numbering.h" 5 #include "src/ast/ast-numbering.h"
6 6
7 #include "src/ast/ast.h" 7 #include "src/ast/ast.h"
8 #include "src/ast/scopes.h" 8 #include "src/ast/scopes.h"
9 #include "src/objects-inl.h" 9 #include "src/objects-inl.h"
10 10
(...skipping 108 matching lines...) Expand 10 before | Expand all | Expand 10 after
119 DisableOptimization(kDebuggerStatement); 119 DisableOptimization(kDebuggerStatement);
120 node->set_base_id(ReserveIdRange(DebuggerStatement::num_ids())); 120 node->set_base_id(ReserveIdRange(DebuggerStatement::num_ids()));
121 } 121 }
122 122
123 123
124 void AstNumberingVisitor::VisitNativeFunctionLiteral( 124 void AstNumberingVisitor::VisitNativeFunctionLiteral(
125 NativeFunctionLiteral* node) { 125 NativeFunctionLiteral* node) {
126 IncrementNodeCount(); 126 IncrementNodeCount();
127 DisableOptimization(kNativeFunctionLiteral); 127 DisableOptimization(kNativeFunctionLiteral);
128 node->set_base_id(ReserveIdRange(NativeFunctionLiteral::num_ids())); 128 node->set_base_id(ReserveIdRange(NativeFunctionLiteral::num_ids()));
129 ReserveFeedbackSlots(node);
129 } 130 }
130 131
131 132
132 void AstNumberingVisitor::VisitDoExpression(DoExpression* node) { 133 void AstNumberingVisitor::VisitDoExpression(DoExpression* node) {
133 IncrementNodeCount(); 134 IncrementNodeCount();
134 node->set_base_id(ReserveIdRange(DoExpression::num_ids())); 135 node->set_base_id(ReserveIdRange(DoExpression::num_ids()));
135 Visit(node->block()); 136 Visit(node->block());
136 Visit(node->result()); 137 Visit(node->result());
137 } 138 }
138 139
(...skipping 450 matching lines...) Expand 10 before | Expand all | Expand 10 after
589 Visit(arguments->at(i)); 590 Visit(arguments->at(i));
590 } 591 }
591 } 592 }
592 593
593 594
594 void AstNumberingVisitor::VisitFunctionLiteral(FunctionLiteral* node) { 595 void AstNumberingVisitor::VisitFunctionLiteral(FunctionLiteral* node) {
595 IncrementNodeCount(); 596 IncrementNodeCount();
596 node->set_base_id(ReserveIdRange(FunctionLiteral::num_ids())); 597 node->set_base_id(ReserveIdRange(FunctionLiteral::num_ids()));
597 // We don't recurse into the declarations or body of the function literal: 598 // We don't recurse into the declarations or body of the function literal:
598 // you have to separately Renumber() each FunctionLiteral that you compile. 599 // you have to separately Renumber() each FunctionLiteral that you compile.
600 ReserveFeedbackSlots(node);
599 } 601 }
600 602
601 603
602 void AstNumberingVisitor::VisitRewritableExpression( 604 void AstNumberingVisitor::VisitRewritableExpression(
603 RewritableExpression* node) { 605 RewritableExpression* node) {
604 IncrementNodeCount(); 606 IncrementNodeCount();
605 node->set_base_id(ReserveIdRange(RewritableExpression::num_ids())); 607 node->set_base_id(ReserveIdRange(RewritableExpression::num_ids()));
606 Visit(node->expression()); 608 Visit(node->expression());
607 } 609 }
608 610
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after
650 } 652 }
651 653
652 654
653 bool AstNumbering::Renumber(Isolate* isolate, Zone* zone, 655 bool AstNumbering::Renumber(Isolate* isolate, Zone* zone,
654 FunctionLiteral* function) { 656 FunctionLiteral* function) {
655 AstNumberingVisitor visitor(isolate, zone); 657 AstNumberingVisitor visitor(isolate, zone);
656 return visitor.Renumber(function); 658 return visitor.Renumber(function);
657 } 659 }
658 } // namespace internal 660 } // namespace internal
659 } // namespace v8 661 } // namespace v8
OLDNEW
« no previous file with comments | « src/ast/ast.h ('k') | src/builtins/builtins-constructor.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698