OLD | NEW |
1 // Copyright 2015 the V8 project authors. All rights reserved. | 1 // Copyright 2015 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_COMPILER_LOOP_PEELING_H_ | 5 #ifndef V8_COMPILER_LOOP_PEELING_H_ |
6 #define V8_COMPILER_LOOP_PEELING_H_ | 6 #define V8_COMPILER_LOOP_PEELING_H_ |
7 | 7 |
8 #include "src/compiler/loop-analysis.h" | 8 #include "src/compiler/loop-analysis.h" |
9 | 9 |
10 namespace v8 { | 10 namespace v8 { |
(...skipping 11 matching lines...) Expand all Loading... |
22 | 22 |
23 protected: | 23 protected: |
24 PeeledIteration() {} | 24 PeeledIteration() {} |
25 }; | 25 }; |
26 | 26 |
27 class CommonOperatorBuilder; | 27 class CommonOperatorBuilder; |
28 | 28 |
29 // Implements loop peeling. | 29 // Implements loop peeling. |
30 class LoopPeeler { | 30 class LoopPeeler { |
31 public: | 31 public: |
| 32 static bool CanPeel(LoopTree* loop_tree, LoopTree::Loop* loop); |
32 static PeeledIteration* Peel(Graph* graph, CommonOperatorBuilder* common, | 33 static PeeledIteration* Peel(Graph* graph, CommonOperatorBuilder* common, |
33 LoopTree* loop_tree, LoopTree::Loop* loop, | 34 LoopTree* loop_tree, LoopTree::Loop* loop, |
34 Zone* tmp_zone); | 35 Zone* tmp_zone); |
35 }; | 36 }; |
36 | 37 |
37 | 38 |
38 } // namespace compiler | 39 } // namespace compiler |
39 } // namespace internal | 40 } // namespace internal |
40 } // namespace v8 | 41 } // namespace v8 |
41 | 42 |
42 #endif // V8_COMPILER_LOOP_PEELING_H_ | 43 #endif // V8_COMPILER_LOOP_PEELING_H_ |
OLD | NEW |