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/v8.h" | 5 #include "src/v8.h" |
6 #include "test/cctest/cctest.h" | 6 #include "test/cctest/cctest.h" |
7 | 7 |
8 #include "src/compiler/common-operator.h" | 8 #include "src/compiler/common-operator.h" |
9 #include "src/compiler/generic-node-inl.h" | 9 #include "src/compiler/generic-node-inl.h" |
10 #include "src/compiler/generic-node.h" | 10 #include "src/compiler/generic-node.h" |
(...skipping 1745 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1756 // End // | 1756 // End // |
1757 | 1757 |
1758 Handle<Object> undef_object = | 1758 Handle<Object> undef_object = |
1759 Handle<Object>(isolate->heap()->undefined_value(), isolate); | 1759 Handle<Object>(isolate->heap()->undefined_value(), isolate); |
1760 PrintableUnique<Object> undef_constant = | 1760 PrintableUnique<Object> undef_constant = |
1761 PrintableUnique<Object>::CreateUninitialized(scope.main_zone(), | 1761 PrintableUnique<Object>::CreateUninitialized(scope.main_zone(), |
1762 undef_object); | 1762 undef_object); |
1763 | 1763 |
1764 Node* undef_node = graph.NewNode(common_builder.HeapConstant(undef_constant)); | 1764 Node* undef_node = graph.NewNode(common_builder.HeapConstant(undef_constant)); |
1765 | 1765 |
1766 Node* start_node = graph.NewNode(common_builder.Start()); | 1766 Node* start_node = graph.NewNode(common_builder.Start(0)); |
1767 | 1767 |
1768 CallDescriptor* descriptor = linkage.GetJSCallDescriptor(0); | 1768 CallDescriptor* descriptor = linkage.GetJSCallDescriptor(0); |
1769 Node* call_node = graph.NewNode(common_builder.Call(descriptor), | 1769 Node* call_node = graph.NewNode(common_builder.Call(descriptor), |
1770 undef_node, // function | 1770 undef_node, // function |
1771 undef_node, // context | 1771 undef_node, // context |
1772 start_node, // effect | 1772 start_node, // effect |
1773 start_node); // control | 1773 start_node); // control |
1774 | 1774 |
1775 Node* cont_node = graph.NewNode(common_builder.Continuation(), call_node); | 1775 Node* cont_node = graph.NewNode(common_builder.Continuation(), call_node); |
1776 Node* lazy_deopt_node = | 1776 Node* lazy_deopt_node = |
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1823 CHECK(!call_block->deferred_); | 1823 CHECK(!call_block->deferred_); |
1824 CHECK(!cont_block->deferred_); | 1824 CHECK(!cont_block->deferred_); |
1825 // The lazy deopt block contains framestate + bailout (and nothing else). | 1825 // The lazy deopt block contains framestate + bailout (and nothing else). |
1826 CHECK_EQ(deoptimization_node, deopt_block->control_input_); | 1826 CHECK_EQ(deoptimization_node, deopt_block->control_input_); |
1827 CHECK_EQ(2, static_cast<int>(deopt_block->nodes_.size())); | 1827 CHECK_EQ(2, static_cast<int>(deopt_block->nodes_.size())); |
1828 CHECK_EQ(lazy_deopt_node, deopt_block->nodes_[0]); | 1828 CHECK_EQ(lazy_deopt_node, deopt_block->nodes_[0]); |
1829 CHECK_EQ(state_node, deopt_block->nodes_[1]); | 1829 CHECK_EQ(state_node, deopt_block->nodes_[1]); |
1830 } | 1830 } |
1831 | 1831 |
1832 #endif | 1832 #endif |
OLD | NEW |