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 <algorithm> | 7 #include <algorithm> |
8 | 8 |
9 #include "src/v8.h" | 9 #include "src/v8.h" |
10 | 10 |
(...skipping 11167 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
11178 | 11178 |
11179 void HOptimizedGraphBuilder::VisitThisFunction(ThisFunction* expr) { | 11179 void HOptimizedGraphBuilder::VisitThisFunction(ThisFunction* expr) { |
11180 DCHECK(!HasStackOverflow()); | 11180 DCHECK(!HasStackOverflow()); |
11181 DCHECK(current_block() != NULL); | 11181 DCHECK(current_block() != NULL); |
11182 DCHECK(current_block()->HasPredecessor()); | 11182 DCHECK(current_block()->HasPredecessor()); |
11183 HInstruction* instr = BuildThisFunction(); | 11183 HInstruction* instr = BuildThisFunction(); |
11184 return ast_context()->ReturnInstruction(instr, expr->id()); | 11184 return ast_context()->ReturnInstruction(instr, expr->id()); |
11185 } | 11185 } |
11186 | 11186 |
11187 | 11187 |
| 11188 void HOptimizedGraphBuilder::VisitSuperReference(SuperReference* expr) { |
| 11189 UNREACHABLE(); |
| 11190 } |
| 11191 |
| 11192 |
11188 void HOptimizedGraphBuilder::VisitDeclarations( | 11193 void HOptimizedGraphBuilder::VisitDeclarations( |
11189 ZoneList<Declaration*>* declarations) { | 11194 ZoneList<Declaration*>* declarations) { |
11190 DCHECK(globals_.is_empty()); | 11195 DCHECK(globals_.is_empty()); |
11191 AstVisitor::VisitDeclarations(declarations); | 11196 AstVisitor::VisitDeclarations(declarations); |
11192 if (!globals_.is_empty()) { | 11197 if (!globals_.is_empty()) { |
11193 Handle<FixedArray> array = | 11198 Handle<FixedArray> array = |
11194 isolate()->factory()->NewFixedArray(globals_.length(), TENURED); | 11199 isolate()->factory()->NewFixedArray(globals_.length(), TENURED); |
11195 for (int i = 0; i < globals_.length(); ++i) array->set(i, *globals_.at(i)); | 11200 for (int i = 0; i < globals_.length(); ++i) array->set(i, *globals_.at(i)); |
11196 int flags = DeclareGlobalsEvalFlag::encode(current_info()->is_eval()) | | 11201 int flags = DeclareGlobalsEvalFlag::encode(current_info()->is_eval()) | |
11197 DeclareGlobalsNativeFlag::encode(current_info()->is_native()) | | 11202 DeclareGlobalsNativeFlag::encode(current_info()->is_native()) | |
(...skipping 1285 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
12483 if (ShouldProduceTraceOutput()) { | 12488 if (ShouldProduceTraceOutput()) { |
12484 isolate()->GetHTracer()->TraceHydrogen(name(), graph_); | 12489 isolate()->GetHTracer()->TraceHydrogen(name(), graph_); |
12485 } | 12490 } |
12486 | 12491 |
12487 #ifdef DEBUG | 12492 #ifdef DEBUG |
12488 graph_->Verify(false); // No full verify. | 12493 graph_->Verify(false); // No full verify. |
12489 #endif | 12494 #endif |
12490 } | 12495 } |
12491 | 12496 |
12492 } } // namespace v8::internal | 12497 } } // namespace v8::internal |
OLD | NEW |