OLD | NEW |
1 // Copyright 2015 the V8 project authors. All rights reserved. | 1 // Copyright 2015 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/bytecode-graph-builder.h" | 5 #include "src/compiler/bytecode-graph-builder.h" |
6 | 6 |
7 #include "src/ast/ast.h" | 7 #include "src/ast/ast.h" |
8 #include "src/ast/scopes.h" | 8 #include "src/ast/scopes.h" |
9 #include "src/compilation-info.h" | 9 #include "src/compilation-info.h" |
10 #include "src/compiler/compiler-source-position-table.h" | 10 #include "src/compiler/compiler-source-position-table.h" |
(...skipping 1595 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1606 } | 1606 } |
1607 | 1607 |
1608 void BytecodeGraphBuilder::VisitDeletePropertyStrict() { | 1608 void BytecodeGraphBuilder::VisitDeletePropertyStrict() { |
1609 BuildDelete(LanguageMode::STRICT); | 1609 BuildDelete(LanguageMode::STRICT); |
1610 } | 1610 } |
1611 | 1611 |
1612 void BytecodeGraphBuilder::VisitDeletePropertySloppy() { | 1612 void BytecodeGraphBuilder::VisitDeletePropertySloppy() { |
1613 BuildDelete(LanguageMode::SLOPPY); | 1613 BuildDelete(LanguageMode::SLOPPY); |
1614 } | 1614 } |
1615 | 1615 |
| 1616 void BytecodeGraphBuilder::VisitGetSuperConstructor() { |
| 1617 Node* node = NewNode(javascript()->GetSuperConstructor(), |
| 1618 environment()->LookupAccumulator()); |
| 1619 environment()->BindRegister(bytecode_iterator().GetRegisterOperand(0), node, |
| 1620 Environment::kAttachFrameState); |
| 1621 } |
| 1622 |
1616 void BytecodeGraphBuilder::BuildCompareOp(const Operator* js_op) { | 1623 void BytecodeGraphBuilder::BuildCompareOp(const Operator* js_op) { |
1617 PrepareEagerCheckpoint(); | 1624 PrepareEagerCheckpoint(); |
1618 Node* left = | 1625 Node* left = |
1619 environment()->LookupRegister(bytecode_iterator().GetRegisterOperand(0)); | 1626 environment()->LookupRegister(bytecode_iterator().GetRegisterOperand(0)); |
1620 Node* right = environment()->LookupAccumulator(); | 1627 Node* right = environment()->LookupAccumulator(); |
1621 Node* node = NewNode(js_op, left, right); | 1628 Node* node = NewNode(js_op, left, right); |
1622 environment()->BindAccumulator(node, Environment::kAttachFrameState); | 1629 environment()->BindAccumulator(node, Environment::kAttachFrameState); |
1623 } | 1630 } |
1624 | 1631 |
1625 void BytecodeGraphBuilder::VisitTestEqual() { | 1632 void BytecodeGraphBuilder::VisitTestEqual() { |
(...skipping 610 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2236 it->source_position().ScriptOffset(), start_position_.InliningId())); | 2243 it->source_position().ScriptOffset(), start_position_.InliningId())); |
2237 it->Advance(); | 2244 it->Advance(); |
2238 } else { | 2245 } else { |
2239 DCHECK_GT(it->code_offset(), offset); | 2246 DCHECK_GT(it->code_offset(), offset); |
2240 } | 2247 } |
2241 } | 2248 } |
2242 | 2249 |
2243 } // namespace compiler | 2250 } // namespace compiler |
2244 } // namespace internal | 2251 } // namespace internal |
2245 } // namespace v8 | 2252 } // namespace v8 |
OLD | NEW |