| 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/compiler/common-operator.h" | 5 #include "src/compiler/common-operator.h" |
| 6 #include "src/compiler/graph.h" | 6 #include "src/compiler/graph.h" |
| 7 #include "src/compiler/machine-operator.h" | 7 #include "src/compiler/machine-operator.h" |
| 8 #include "src/compiler/node.h" | 8 #include "src/compiler/node.h" |
| 9 #include "src/compiler/node-matchers.h" | 9 #include "src/compiler/node-matchers.h" |
| 10 #include "src/compiler/opcodes.h" | 10 #include "src/compiler/opcodes.h" |
| 11 | 11 |
| 12 #include "test/unittests/compiler/graph-unittest.h" | 12 #include "test/unittests/compiler/graph-unittest.h" |
| 13 #include "test/unittests/test-utils.h" | 13 #include "test/unittests/test-utils.h" |
| 14 | 14 |
| 15 namespace v8 { | 15 namespace v8 { |
| 16 namespace internal { | 16 namespace internal { |
| 17 namespace compiler { | 17 namespace compiler { |
| 18 | 18 |
| 19 class NodeMatcherTest : public GraphTest { | 19 class NodeMatcherTest : public GraphTest { |
| 20 public: | 20 public: |
| 21 NodeMatcherTest() : machine_(zone()) {} | 21 NodeMatcherTest() : machine_(zone()) {} |
| 22 ~NodeMatcherTest() OVERRIDE {} | 22 ~NodeMatcherTest() override {} |
| 23 | 23 |
| 24 MachineOperatorBuilder* machine() { return &machine_; } | 24 MachineOperatorBuilder* machine() { return &machine_; } |
| 25 | 25 |
| 26 private: | 26 private: |
| 27 MachineOperatorBuilder machine_; | 27 MachineOperatorBuilder machine_; |
| 28 }; | 28 }; |
| 29 | 29 |
| 30 namespace { | 30 namespace { |
| 31 | 31 |
| 32 template <class Matcher> | 32 template <class Matcher> |
| (...skipping 909 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 942 Node* merge = graph()->NewNode(common()->Merge(2), if_true, if_false); | 942 Node* merge = graph()->NewNode(common()->Merge(2), if_true, if_false); |
| 943 DiamondMatcher matcher(merge); | 943 DiamondMatcher matcher(merge); |
| 944 EXPECT_FALSE(matcher.Matched()); | 944 EXPECT_FALSE(matcher.Matched()); |
| 945 } | 945 } |
| 946 } | 946 } |
| 947 | 947 |
| 948 | 948 |
| 949 } // namespace compiler | 949 } // namespace compiler |
| 950 } // namespace internal | 950 } // namespace internal |
| 951 } // namespace v8 | 951 } // namespace v8 |
| OLD | NEW |