OLD | NEW |
1 // Copyright 2016 the V8 project authors. All rights reserved. | 1 // Copyright 2016 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_LOAD_ELIMINATION_H_ | 5 #ifndef V8_COMPILER_LOAD_ELIMINATION_H_ |
6 #define V8_COMPILER_LOAD_ELIMINATION_H_ | 6 #define V8_COMPILER_LOAD_ELIMINATION_H_ |
7 | 7 |
8 #include "src/compiler/graph-reducer.h" | 8 #include "src/compiler/graph-reducer.h" |
9 | 9 |
10 namespace v8 { | 10 namespace v8 { |
(...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
100 copy->info_for_node_.insert(this_it); | 100 copy->info_for_node_.insert(this_it); |
101 } | 101 } |
102 } | 102 } |
103 return copy; | 103 return copy; |
104 } | 104 } |
105 | 105 |
106 private: | 106 private: |
107 ZoneMap<Node*, Node*> info_for_node_; | 107 ZoneMap<Node*, Node*> info_for_node_; |
108 }; | 108 }; |
109 | 109 |
110 static size_t const kMaxTrackedFields = 16; | 110 static size_t const kMaxTrackedFields = 32; |
111 | 111 |
112 class AbstractState final : public ZoneObject { | 112 class AbstractState final : public ZoneObject { |
113 public: | 113 public: |
114 AbstractState() { | 114 AbstractState() { |
115 for (size_t i = 0; i < arraysize(fields_); ++i) { | 115 for (size_t i = 0; i < arraysize(fields_); ++i) { |
116 fields_[i] = nullptr; | 116 fields_[i] = nullptr; |
117 } | 117 } |
118 } | 118 } |
119 | 119 |
120 bool Equals(AbstractState const* that) const; | 120 bool Equals(AbstractState const* that) const; |
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
171 AbstractStateForEffectNodes node_states_; | 171 AbstractStateForEffectNodes node_states_; |
172 | 172 |
173 DISALLOW_COPY_AND_ASSIGN(LoadElimination); | 173 DISALLOW_COPY_AND_ASSIGN(LoadElimination); |
174 }; | 174 }; |
175 | 175 |
176 } // namespace compiler | 176 } // namespace compiler |
177 } // namespace internal | 177 } // namespace internal |
178 } // namespace v8 | 178 } // namespace v8 |
179 | 179 |
180 #endif // V8_COMPILER_LOAD_ELIMINATION_H_ | 180 #endif // V8_COMPILER_LOAD_ELIMINATION_H_ |
OLD | NEW |