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

Side by Side Diff: src/compiler/ast-graph-builder.h

Issue 1424943008: [turbofan] Desugar lookup slot optimization in graph builder. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Addressed comment. Created 5 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 unified diff | Download patch
« no previous file with comments | « no previous file | 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 2014 the V8 project authors. All rights reserved. 1 // Copyright 2014 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 #ifndef V8_COMPILER_AST_GRAPH_BUILDER_H_ 5 #ifndef V8_COMPILER_AST_GRAPH_BUILDER_H_
6 #define V8_COMPILER_AST_GRAPH_BUILDER_H_ 6 #define V8_COMPILER_AST_GRAPH_BUILDER_H_
7 7
8 #include "src/ast.h" 8 #include "src/ast.h"
9 #include "src/compiler/js-graph.h" 9 #include "src/compiler/js-graph.h"
10 #include "src/compiler/liveness-analyzer.h" 10 #include "src/compiler/liveness-analyzer.h"
(...skipping 345 matching lines...) Expand 10 before | Expand all | Expand 10 after
356 356
357 // =========================================================================== 357 // ===========================================================================
358 // The following build methods have the same contract as the above ones, but 358 // The following build methods have the same contract as the above ones, but
359 // they can also return {NULL} to indicate that no fragment was built. Note 359 // they can also return {NULL} to indicate that no fragment was built. Note
360 // that these are optimizations, disabling any of them should still produce 360 // that these are optimizations, disabling any of them should still produce
361 // correct graphs. 361 // correct graphs.
362 362
363 // Optimization for variable load from global object. 363 // Optimization for variable load from global object.
364 Node* TryLoadGlobalConstant(Handle<Name> name); 364 Node* TryLoadGlobalConstant(Handle<Name> name);
365 365
366 // Optimization for variable load of dynamic lookup slot that is most likely
367 // to resolve to a global slot or context slot (inferred from scope chain).
368 Node* TryLoadDynamicVariable(Variable* variable, Handle<String> name,
369 BailoutId bailout_id,
370 FrameStateBeforeAndAfter& states,
371 const VectorSlotPair& feedback,
372 OutputFrameStateCombine combine,
373 TypeofMode typeof_mode);
374
366 // Optimizations for automatic type conversion. 375 // Optimizations for automatic type conversion.
367 Node* TryFastToBoolean(Node* input); 376 Node* TryFastToBoolean(Node* input);
368 Node* TryFastToName(Node* input); 377 Node* TryFastToName(Node* input);
369 378
370 // =========================================================================== 379 // ===========================================================================
371 // The following visitation methods all recursively visit a subtree of the 380 // The following visitation methods all recursively visit a subtree of the
372 // underlying AST and extent the graph. The operand stack is mutated in a way 381 // underlying AST and extent the graph. The operand stack is mutated in a way
373 // consistent with other compilers: 382 // consistent with other compilers:
374 // - Expressions pop operands and push result, depending on {AstContext}. 383 // - Expressions pop operands and push result, depending on {AstContext}.
375 // - Statements keep the operand stack balanced. 384 // - Statements keep the operand stack balanced.
(...skipping 190 matching lines...) Expand 10 before | Expand all | Expand 10 after
566 575
567 // Prepare environment to be used as loop header. 576 // Prepare environment to be used as loop header.
568 void PrepareForLoop(BitVector* assigned, bool is_osr = false); 577 void PrepareForLoop(BitVector* assigned, bool is_osr = false);
569 }; 578 };
570 579
571 } // namespace compiler 580 } // namespace compiler
572 } // namespace internal 581 } // namespace internal
573 } // namespace v8 582 } // namespace v8
574 583
575 #endif // V8_COMPILER_AST_GRAPH_BUILDER_H_ 584 #endif // V8_COMPILER_AST_GRAPH_BUILDER_H_
OLDNEW
« no previous file with comments | « no previous file | src/compiler/ast-graph-builder.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698