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

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

Issue 2597163002: Revert of [TypeFeedbackVector] Root literal arrays in function literals slots (Closed)
Patch Set: Created 4 years 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/arm/builtins-arm.cc » ('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 9
10 namespace v8 { 10 namespace v8 {
(...skipping 107 matching lines...) Expand 10 before | Expand all | Expand 10 after
118 DisableOptimization(kDebuggerStatement); 118 DisableOptimization(kDebuggerStatement);
119 node->set_base_id(ReserveIdRange(DebuggerStatement::num_ids())); 119 node->set_base_id(ReserveIdRange(DebuggerStatement::num_ids()));
120 } 120 }
121 121
122 122
123 void AstNumberingVisitor::VisitNativeFunctionLiteral( 123 void AstNumberingVisitor::VisitNativeFunctionLiteral(
124 NativeFunctionLiteral* node) { 124 NativeFunctionLiteral* node) {
125 IncrementNodeCount(); 125 IncrementNodeCount();
126 DisableOptimization(kNativeFunctionLiteral); 126 DisableOptimization(kNativeFunctionLiteral);
127 node->set_base_id(ReserveIdRange(NativeFunctionLiteral::num_ids())); 127 node->set_base_id(ReserveIdRange(NativeFunctionLiteral::num_ids()));
128 ReserveFeedbackSlots(node);
129 } 128 }
130 129
131 130
132 void AstNumberingVisitor::VisitDoExpression(DoExpression* node) { 131 void AstNumberingVisitor::VisitDoExpression(DoExpression* node) {
133 IncrementNodeCount(); 132 IncrementNodeCount();
134 node->set_base_id(ReserveIdRange(DoExpression::num_ids())); 133 node->set_base_id(ReserveIdRange(DoExpression::num_ids()));
135 Visit(node->block()); 134 Visit(node->block());
136 Visit(node->result()); 135 Visit(node->result());
137 } 136 }
138 137
(...skipping 450 matching lines...) Expand 10 before | Expand all | Expand 10 after
589 Visit(arguments->at(i)); 588 Visit(arguments->at(i));
590 } 589 }
591 } 590 }
592 591
593 592
594 void AstNumberingVisitor::VisitFunctionLiteral(FunctionLiteral* node) { 593 void AstNumberingVisitor::VisitFunctionLiteral(FunctionLiteral* node) {
595 IncrementNodeCount(); 594 IncrementNodeCount();
596 node->set_base_id(ReserveIdRange(FunctionLiteral::num_ids())); 595 node->set_base_id(ReserveIdRange(FunctionLiteral::num_ids()));
597 // We don't recurse into the declarations or body of the function literal: 596 // We don't recurse into the declarations or body of the function literal:
598 // you have to separately Renumber() each FunctionLiteral that you compile. 597 // you have to separately Renumber() each FunctionLiteral that you compile.
599 ReserveFeedbackSlots(node);
600 } 598 }
601 599
602 600
603 void AstNumberingVisitor::VisitRewritableExpression( 601 void AstNumberingVisitor::VisitRewritableExpression(
604 RewritableExpression* node) { 602 RewritableExpression* node) {
605 IncrementNodeCount(); 603 IncrementNodeCount();
606 node->set_base_id(ReserveIdRange(RewritableExpression::num_ids())); 604 node->set_base_id(ReserveIdRange(RewritableExpression::num_ids()));
607 Visit(node->expression()); 605 Visit(node->expression());
608 } 606 }
609 607
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after
651 } 649 }
652 650
653 651
654 bool AstNumbering::Renumber(Isolate* isolate, Zone* zone, 652 bool AstNumbering::Renumber(Isolate* isolate, Zone* zone,
655 FunctionLiteral* function) { 653 FunctionLiteral* function) {
656 AstNumberingVisitor visitor(isolate, zone); 654 AstNumberingVisitor visitor(isolate, zone);
657 return visitor.Renumber(function); 655 return visitor.Renumber(function);
658 } 656 }
659 } // namespace internal 657 } // namespace internal
660 } // namespace v8 658 } // namespace v8
OLDNEW
« no previous file with comments | « src/ast/ast.h ('k') | src/builtins/arm/builtins-arm.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698