| OLD | NEW |
| 1 // Copyright 2013 the V8 project authors. All rights reserved. | 1 // Copyright 2013 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/hydrogen.h" | 5 #include "src/hydrogen.h" |
| 6 | 6 |
| 7 #include <sstream> | 7 #include <sstream> |
| 8 | 8 |
| 9 #include "src/v8.h" | 9 #include "src/v8.h" |
| 10 | 10 |
| (...skipping 11019 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 11030 DCHECK_EQ(Token::EQ, expr->op()); | 11030 DCHECK_EQ(Token::EQ, expr->op()); |
| 11031 Type* type = expr->combined_type()->Is(Type::None()) | 11031 Type* type = expr->combined_type()->Is(Type::None()) |
| 11032 ? Type::Any(zone()) : expr->combined_type(); | 11032 ? Type::Any(zone()) : expr->combined_type(); |
| 11033 HIfContinuation continuation; | 11033 HIfContinuation continuation; |
| 11034 BuildCompareNil(value, type, &continuation); | 11034 BuildCompareNil(value, type, &continuation); |
| 11035 return ast_context()->ReturnContinuation(&continuation, expr->id()); | 11035 return ast_context()->ReturnContinuation(&continuation, expr->id()); |
| 11036 } | 11036 } |
| 11037 } | 11037 } |
| 11038 | 11038 |
| 11039 | 11039 |
| 11040 void HOptimizedGraphBuilder::VisitSpread(Spread* expr) { |
| 11041 UNREACHABLE(); |
| 11042 } |
| 11043 |
| 11044 |
| 11040 HInstruction* HOptimizedGraphBuilder::BuildThisFunction() { | 11045 HInstruction* HOptimizedGraphBuilder::BuildThisFunction() { |
| 11041 // If we share optimized code between different closures, the | 11046 // If we share optimized code between different closures, the |
| 11042 // this-function is not a constant, except inside an inlined body. | 11047 // this-function is not a constant, except inside an inlined body. |
| 11043 if (function_state()->outer() != NULL) { | 11048 if (function_state()->outer() != NULL) { |
| 11044 return New<HConstant>( | 11049 return New<HConstant>( |
| 11045 function_state()->compilation_info()->closure()); | 11050 function_state()->compilation_info()->closure()); |
| 11046 } else { | 11051 } else { |
| 11047 return New<HThisFunction>(); | 11052 return New<HThisFunction>(); |
| 11048 } | 11053 } |
| 11049 } | 11054 } |
| (...skipping 2321 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 13371 if (ShouldProduceTraceOutput()) { | 13376 if (ShouldProduceTraceOutput()) { |
| 13372 isolate()->GetHTracer()->TraceHydrogen(name(), graph_); | 13377 isolate()->GetHTracer()->TraceHydrogen(name(), graph_); |
| 13373 } | 13378 } |
| 13374 | 13379 |
| 13375 #ifdef DEBUG | 13380 #ifdef DEBUG |
| 13376 graph_->Verify(false); // No full verify. | 13381 graph_->Verify(false); // No full verify. |
| 13377 #endif | 13382 #endif |
| 13378 } | 13383 } |
| 13379 | 13384 |
| 13380 } } // namespace v8::internal | 13385 } } // namespace v8::internal |
| OLD | NEW |