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/bytecode-branch-analysis.h" | 10 #include "src/compiler/bytecode-branch-analysis.h" |
(...skipping 1598 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1609 } | 1609 } |
1610 | 1610 |
1611 void BytecodeGraphBuilder::VisitJumpIfUndefined() { | 1611 void BytecodeGraphBuilder::VisitJumpIfUndefined() { |
1612 BuildJumpIfEqual(jsgraph()->UndefinedConstant()); | 1612 BuildJumpIfEqual(jsgraph()->UndefinedConstant()); |
1613 } | 1613 } |
1614 | 1614 |
1615 void BytecodeGraphBuilder::VisitJumpIfUndefinedConstant() { | 1615 void BytecodeGraphBuilder::VisitJumpIfUndefinedConstant() { |
1616 BuildJumpIfEqual(jsgraph()->UndefinedConstant()); | 1616 BuildJumpIfEqual(jsgraph()->UndefinedConstant()); |
1617 } | 1617 } |
1618 | 1618 |
| 1619 void BytecodeGraphBuilder::VisitJumpLoop() { BuildJump(); } |
| 1620 |
1619 void BytecodeGraphBuilder::VisitStackCheck() { | 1621 void BytecodeGraphBuilder::VisitStackCheck() { |
1620 FrameStateBeforeAndAfter states(this); | 1622 FrameStateBeforeAndAfter states(this); |
1621 Node* node = NewNode(javascript()->StackCheck()); | 1623 Node* node = NewNode(javascript()->StackCheck()); |
1622 environment()->RecordAfterState(node, &states); | 1624 environment()->RecordAfterState(node, &states); |
1623 } | 1625 } |
1624 | 1626 |
1625 void BytecodeGraphBuilder::VisitOsrPoll() {} | |
1626 | |
1627 void BytecodeGraphBuilder::VisitReturn() { | 1627 void BytecodeGraphBuilder::VisitReturn() { |
1628 BuildLoopExitsForFunctionExit(); | 1628 BuildLoopExitsForFunctionExit(); |
1629 Node* control = | 1629 Node* control = |
1630 NewNode(common()->Return(), environment()->LookupAccumulator()); | 1630 NewNode(common()->Return(), environment()->LookupAccumulator()); |
1631 MergeControlToLeaveFunction(control); | 1631 MergeControlToLeaveFunction(control); |
1632 } | 1632 } |
1633 | 1633 |
1634 void BytecodeGraphBuilder::VisitDebugger() { | 1634 void BytecodeGraphBuilder::VisitDebugger() { |
1635 FrameStateBeforeAndAfter states(this); | 1635 FrameStateBeforeAndAfter states(this); |
1636 Node* call = | 1636 Node* call = |
(...skipping 441 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2078 // Phi does not exist yet, introduce one. | 2078 // Phi does not exist yet, introduce one. |
2079 value = NewPhi(inputs, value, control); | 2079 value = NewPhi(inputs, value, control); |
2080 value->ReplaceInput(inputs - 1, other); | 2080 value->ReplaceInput(inputs - 1, other); |
2081 } | 2081 } |
2082 return value; | 2082 return value; |
2083 } | 2083 } |
2084 | 2084 |
2085 } // namespace compiler | 2085 } // namespace compiler |
2086 } // namespace internal | 2086 } // namespace internal |
2087 } // namespace v8 | 2087 } // namespace v8 |
OLD | NEW |