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 #ifndef V8_UNITTESTS_COMPILER_GRAPH_UNITTEST_H_ | 5 #ifndef V8_UNITTESTS_COMPILER_GRAPH_UNITTEST_H_ |
6 #define V8_UNITTESTS_COMPILER_GRAPH_UNITTEST_H_ | 6 #define V8_UNITTESTS_COMPILER_GRAPH_UNITTEST_H_ |
7 | 7 |
8 #include "src/compiler/common-operator.h" | 8 #include "src/compiler/common-operator.h" |
9 #include "src/compiler/graph.h" | 9 #include "src/compiler/graph.h" |
10 #include "src/compiler/typer.h" | 10 #include "src/compiler/typer.h" |
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
46 Node* TrueConstant(); | 46 Node* TrueConstant(); |
47 Node* UndefinedConstant(); | 47 Node* UndefinedConstant(); |
48 | 48 |
49 Node* EmptyFrameState(); | 49 Node* EmptyFrameState(); |
50 | 50 |
51 Matcher<Node*> IsBooleanConstant(bool value) { | 51 Matcher<Node*> IsBooleanConstant(bool value) { |
52 return value ? IsTrueConstant() : IsFalseConstant(); | 52 return value ? IsTrueConstant() : IsFalseConstant(); |
53 } | 53 } |
54 Matcher<Node*> IsFalseConstant(); | 54 Matcher<Node*> IsFalseConstant(); |
55 Matcher<Node*> IsTrueConstant(); | 55 Matcher<Node*> IsTrueConstant(); |
| 56 Matcher<Node*> IsNullConstant(); |
56 Matcher<Node*> IsUndefinedConstant(); | 57 Matcher<Node*> IsUndefinedConstant(); |
57 | 58 |
58 CommonOperatorBuilder* common() { return &common_; } | 59 CommonOperatorBuilder* common() { return &common_; } |
59 Graph* graph() { return &graph_; } | 60 Graph* graph() { return &graph_; } |
60 | 61 |
61 private: | 62 private: |
62 CommonOperatorBuilder common_; | 63 CommonOperatorBuilder common_; |
63 Graph graph_; | 64 Graph graph_; |
64 }; | 65 }; |
65 | 66 |
(...skipping 11 matching lines...) Expand all Loading... |
77 | 78 |
78 private: | 79 private: |
79 Typer typer_; | 80 Typer typer_; |
80 }; | 81 }; |
81 | 82 |
82 } // namespace compiler | 83 } // namespace compiler |
83 } // namespace internal | 84 } // namespace internal |
84 } // namespace v8 | 85 } // namespace v8 |
85 | 86 |
86 #endif // V8_UNITTESTS_COMPILER_GRAPH_UNITTEST_H_ | 87 #endif // V8_UNITTESTS_COMPILER_GRAPH_UNITTEST_H_ |
OLD | NEW |