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 #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/js-operator.h" | 7 #include "src/compiler/js-operator.h" |
8 #include "src/compiler/linkage.h" | 8 #include "src/compiler/linkage.h" |
9 #include "src/compiler/node-properties.h" | 9 #include "src/compiler/node-properties.h" |
10 #include "src/compiler/operator-properties.h" | 10 #include "src/compiler/operator-properties.h" |
(...skipping 197 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
208 // Requires distinguishing between value, effect and control edges. | 208 // Requires distinguishing between value, effect and control edges. |
209 for (Edge edge : node->use_edges()) { | 209 for (Edge edge : node->use_edges()) { |
210 if (IsControlEdge(edge)) { | 210 if (IsControlEdge(edge)) { |
211 if (edge.from()->opcode() == IrOpcode::kIfSuccess) { | 211 if (edge.from()->opcode() == IrOpcode::kIfSuccess) { |
212 DCHECK_NOT_NULL(success); | 212 DCHECK_NOT_NULL(success); |
213 edge.UpdateTo(success); | 213 edge.UpdateTo(success); |
214 } else if (edge.from()->opcode() == IrOpcode::kIfException) { | 214 } else if (edge.from()->opcode() == IrOpcode::kIfException) { |
215 DCHECK_NOT_NULL(exception); | 215 DCHECK_NOT_NULL(exception); |
216 edge.UpdateTo(exception); | 216 edge.UpdateTo(exception); |
217 } else { | 217 } else { |
218 UNREACHABLE(); | 218 DCHECK_NOT_NULL(success); |
| 219 edge.UpdateTo(success); |
219 } | 220 } |
220 } else if (IsEffectEdge(edge)) { | 221 } else if (IsEffectEdge(edge)) { |
221 DCHECK_NOT_NULL(effect); | 222 DCHECK_NOT_NULL(effect); |
222 edge.UpdateTo(effect); | 223 edge.UpdateTo(effect); |
223 } else { | 224 } else { |
224 DCHECK_NOT_NULL(value); | 225 DCHECK_NOT_NULL(value); |
225 edge.UpdateTo(value); | 226 edge.UpdateTo(value); |
226 } | 227 } |
227 } | 228 } |
228 } | 229 } |
(...skipping 196 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
425 // static | 426 // static |
426 bool NodeProperties::IsInputRange(Edge edge, int first, int num) { | 427 bool NodeProperties::IsInputRange(Edge edge, int first, int num) { |
427 if (num == 0) return false; | 428 if (num == 0) return false; |
428 int const index = edge.index(); | 429 int const index = edge.index(); |
429 return first <= index && index < first + num; | 430 return first <= index && index < first + num; |
430 } | 431 } |
431 | 432 |
432 } // namespace compiler | 433 } // namespace compiler |
433 } // namespace internal | 434 } // namespace internal |
434 } // namespace v8 | 435 } // namespace v8 |
OLD | NEW |