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 "test/unittests/compiler/graph-unittest.h" | 5 #include "test/unittests/compiler/graph-unittest.h" |
6 | 6 |
7 #include "src/compiler/node-properties-inl.h" | 7 #include "src/compiler/node-properties-inl.h" |
8 #include "test/unittests/compiler/node-test-utils.h" | 8 #include "test/unittests/compiler/node-test-utils.h" |
9 | 9 |
10 namespace v8 { | 10 namespace v8 { |
(...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
86 } | 86 } |
87 | 87 |
88 | 88 |
89 Matcher<Node*> GraphTest::IsTrueConstant() { | 89 Matcher<Node*> GraphTest::IsTrueConstant() { |
90 return IsHeapConstant( | 90 return IsHeapConstant( |
91 Unique<HeapObject>::CreateImmovable(factory()->true_value())); | 91 Unique<HeapObject>::CreateImmovable(factory()->true_value())); |
92 } | 92 } |
93 | 93 |
94 | 94 |
95 TypedGraphTest::TypedGraphTest(int num_parameters) | 95 TypedGraphTest::TypedGraphTest(int num_parameters) |
96 : GraphTest(num_parameters), typer_(graph(), MaybeHandle<Context>()) {} | 96 : GraphTest(num_parameters), |
| 97 typer_(isolate(), graph(), MaybeHandle<Context>()) {} |
97 | 98 |
98 | 99 |
99 TypedGraphTest::~TypedGraphTest() {} | 100 TypedGraphTest::~TypedGraphTest() {} |
100 | 101 |
101 | 102 |
102 Node* TypedGraphTest::Parameter(Type* type, int32_t index) { | 103 Node* TypedGraphTest::Parameter(Type* type, int32_t index) { |
103 Node* node = GraphTest::Parameter(index); | 104 Node* node = GraphTest::Parameter(index); |
104 NodeProperties::SetBounds(node, Bounds(type)); | 105 NodeProperties::SetBounds(node, Bounds(type)); |
105 return node; | 106 return node; |
106 } | 107 } |
(...skipping 14 matching lines...) Expand all Loading... |
121 EXPECT_LT(0, n0->id()); | 122 EXPECT_LT(0, n0->id()); |
122 EXPECT_LT(0, n1->id()); | 123 EXPECT_LT(0, n1->id()); |
123 EXPECT_NE(n0->id(), n1->id()); | 124 EXPECT_NE(n0->id(), n1->id()); |
124 EXPECT_EQ(&kDummyOperator, n0->op()); | 125 EXPECT_EQ(&kDummyOperator, n0->op()); |
125 EXPECT_EQ(&kDummyOperator, n1->op()); | 126 EXPECT_EQ(&kDummyOperator, n1->op()); |
126 } | 127 } |
127 | 128 |
128 } // namespace compiler | 129 } // namespace compiler |
129 } // namespace internal | 130 } // namespace internal |
130 } // namespace v8 | 131 } // namespace v8 |
OLD | NEW |