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

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

Issue 1405503002: VectorICs: use a vector slot to aid in array literal processing. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Code comments. Created 5 years, 2 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.cc ('k') | src/compiler/ast-graph-builder.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-numbering.h" 5 #include "src/ast-numbering.h"
6 6
7 #include "src/ast.h" 7 #include "src/ast.h"
8 #include "src/scopes.h" 8 #include "src/scopes.h"
9 9
10 namespace v8 { 10 namespace v8 {
(...skipping 471 matching lines...) Expand 10 before | Expand all | Expand 10 after
482 Visit(node->value()); 482 Visit(node->value());
483 } 483 }
484 484
485 485
486 void AstNumberingVisitor::VisitArrayLiteral(ArrayLiteral* node) { 486 void AstNumberingVisitor::VisitArrayLiteral(ArrayLiteral* node) {
487 IncrementNodeCount(); 487 IncrementNodeCount();
488 node->set_base_id(ReserveIdRange(node->num_ids())); 488 node->set_base_id(ReserveIdRange(node->num_ids()));
489 for (int i = 0; i < node->values()->length(); i++) { 489 for (int i = 0; i < node->values()->length(); i++) {
490 Visit(node->values()->at(i)); 490 Visit(node->values()->at(i));
491 } 491 }
492 node->BuildConstantElements(isolate());
493 ReserveFeedbackSlots(node);
492 } 494 }
493 495
494 496
495 void AstNumberingVisitor::VisitCall(Call* node) { 497 void AstNumberingVisitor::VisitCall(Call* node) {
496 IncrementNodeCount(); 498 IncrementNodeCount();
497 ReserveFeedbackSlots(node); 499 ReserveFeedbackSlots(node);
498 node->set_base_id(ReserveIdRange(Call::num_ids())); 500 node->set_base_id(ReserveIdRange(Call::num_ids()));
499 Visit(node->expression()); 501 Visit(node->expression());
500 VisitArguments(node->arguments()); 502 VisitArguments(node->arguments());
501 } 503 }
(...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after
568 } 570 }
569 571
570 572
571 bool AstNumbering::Renumber(Isolate* isolate, Zone* zone, 573 bool AstNumbering::Renumber(Isolate* isolate, Zone* zone,
572 FunctionLiteral* function) { 574 FunctionLiteral* function) {
573 AstNumberingVisitor visitor(isolate, zone); 575 AstNumberingVisitor visitor(isolate, zone);
574 return visitor.Renumber(function); 576 return visitor.Renumber(function);
575 } 577 }
576 } // namespace internal 578 } // namespace internal
577 } // namespace v8 579 } // namespace v8
OLDNEW
« no previous file with comments | « src/ast.cc ('k') | src/compiler/ast-graph-builder.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698