OLD | NEW |
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 #include "src/compiler/ast-graph-builder.h" | 5 #include "src/compiler/ast-graph-builder.h" |
6 | 6 |
7 #include "src/ast/scopes.h" | 7 #include "src/ast/scopes.h" |
8 #include "src/compiler.h" | 8 #include "src/compiler.h" |
9 #include "src/compiler/ast-loop-assignment-analyzer.h" | 9 #include "src/compiler/ast-loop-assignment-analyzer.h" |
10 #include "src/compiler/control-builders.h" | 10 #include "src/compiler/control-builders.h" |
(...skipping 3060 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3071 environment()->Pop(); | 3071 environment()->Pop(); |
3072 } else if (ast_context()->IsTest()) { | 3072 } else if (ast_context()->IsTest()) { |
3073 environment()->Poke(0, jsgraph()->FalseConstant()); | 3073 environment()->Poke(0, jsgraph()->FalseConstant()); |
3074 } | 3074 } |
3075 compare_if.End(); | 3075 compare_if.End(); |
3076 ast_context()->ReplaceValue(); | 3076 ast_context()->ReplaceValue(); |
3077 } | 3077 } |
3078 | 3078 |
3079 | 3079 |
3080 LanguageMode AstGraphBuilder::language_mode() const { | 3080 LanguageMode AstGraphBuilder::language_mode() const { |
3081 return info()->language_mode(); | 3081 return current_scope()->language_mode(); |
3082 } | 3082 } |
3083 | 3083 |
3084 | 3084 |
3085 VectorSlotPair AstGraphBuilder::CreateVectorSlotPair( | 3085 VectorSlotPair AstGraphBuilder::CreateVectorSlotPair( |
3086 FeedbackVectorSlot slot) const { | 3086 FeedbackVectorSlot slot) const { |
3087 return VectorSlotPair(handle(info()->shared_info()->feedback_vector()), slot); | 3087 return VectorSlotPair(handle(info()->shared_info()->feedback_vector()), slot); |
3088 } | 3088 } |
3089 | 3089 |
3090 | 3090 |
3091 void AstGraphBuilder::VisitRewritableExpression(RewritableExpression* node) { | 3091 void AstGraphBuilder::VisitRewritableExpression(RewritableExpression* node) { |
(...skipping 1277 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4369 // Phi does not exist yet, introduce one. | 4369 // Phi does not exist yet, introduce one. |
4370 value = NewPhi(inputs, value, control); | 4370 value = NewPhi(inputs, value, control); |
4371 value->ReplaceInput(inputs - 1, other); | 4371 value->ReplaceInput(inputs - 1, other); |
4372 } | 4372 } |
4373 return value; | 4373 return value; |
4374 } | 4374 } |
4375 | 4375 |
4376 } // namespace compiler | 4376 } // namespace compiler |
4377 } // namespace internal | 4377 } // namespace internal |
4378 } // namespace v8 | 4378 } // namespace v8 |
OLD | NEW |