Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(49)

Side by Side Diff: test/unittests/compiler/graph-unittest.cc

Issue 2406803002: [turbofan] Enforce native context specialization. (Closed)
Patch Set: Remove unused variables Created 4 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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.h" 7 #include "src/compiler/node-properties.h"
8 #include "src/factory.h" 8 #include "src/factory.h"
9 #include "src/objects-inl.h" // TODO(everyone): Make typer.h IWYU compliant. 9 #include "src/objects-inl.h" // TODO(everyone): Make typer.h IWYU compliant.
10 #include "test/unittests/compiler/node-test-utils.h" 10 #include "test/unittests/compiler/node-test-utils.h"
11 11
12 namespace v8 { 12 namespace v8 {
13 namespace internal { 13 namespace internal {
14 namespace compiler { 14 namespace compiler {
15 15
16 GraphTest::GraphTest(int num_parameters) : common_(zone()), graph_(zone()) { 16 GraphTest::GraphTest(int num_parameters)
17 : TestWithNativeContext(),
18 TestWithIsolateAndZone(),
19 common_(zone()),
20 graph_(zone()) {
17 graph()->SetStart(graph()->NewNode(common()->Start(num_parameters))); 21 graph()->SetStart(graph()->NewNode(common()->Start(num_parameters)));
18 graph()->SetEnd(graph()->NewNode(common()->End(1), graph()->start())); 22 graph()->SetEnd(graph()->NewNode(common()->End(1), graph()->start()));
19 } 23 }
20 24
21 25
22 GraphTest::~GraphTest() {} 26 GraphTest::~GraphTest() {}
23 27
24 28
25 Node* GraphTest::Parameter(int32_t index) { 29 Node* GraphTest::Parameter(int32_t index) {
26 return graph()->NewNode(common()->Parameter(index), graph()->start()); 30 return graph()->NewNode(common()->Parameter(index), graph()->start());
(...skipping 102 matching lines...) Expand 10 before | Expand all | Expand 10 after
129 EXPECT_LT(0u, n0->id()); 133 EXPECT_LT(0u, n0->id());
130 EXPECT_LT(0u, n1->id()); 134 EXPECT_LT(0u, n1->id());
131 EXPECT_NE(n0->id(), n1->id()); 135 EXPECT_NE(n0->id(), n1->id());
132 EXPECT_EQ(&kDummyOperator, n0->op()); 136 EXPECT_EQ(&kDummyOperator, n0->op());
133 EXPECT_EQ(&kDummyOperator, n1->op()); 137 EXPECT_EQ(&kDummyOperator, n1->op());
134 } 138 }
135 139
136 } // namespace compiler 140 } // namespace compiler
137 } // namespace internal 141 } // namespace internal
138 } // namespace v8 142 } // namespace v8
OLDNEW
« no previous file with comments | « test/unittests/compiler/graph-unittest.h ('k') | test/unittests/compiler/js-create-lowering-unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698