| 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/state-values-utils.h" | 5 #include "src/compiler/state-values-utils.h" |
| 6 | 6 |
| 7 namespace v8 { | 7 namespace v8 { |
| 8 namespace internal { | 8 namespace internal { |
| 9 namespace compiler { | 9 namespace compiler { |
| 10 | 10 |
| (...skipping 256 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 267 return Top()->node->InputAt(Top()->index); | 267 return Top()->node->InputAt(Top()->index); |
| 268 } | 268 } |
| 269 | 269 |
| 270 | 270 |
| 271 MachineType StateValuesAccess::iterator::type() { | 271 MachineType StateValuesAccess::iterator::type() { |
| 272 Node* state = Top()->node; | 272 Node* state = Top()->node; |
| 273 if (state->opcode() == IrOpcode::kStateValues) { | 273 if (state->opcode() == IrOpcode::kStateValues) { |
| 274 return MachineType::AnyTagged(); | 274 return MachineType::AnyTagged(); |
| 275 } else { | 275 } else { |
| 276 DCHECK_EQ(IrOpcode::kTypedStateValues, state->opcode()); | 276 DCHECK_EQ(IrOpcode::kTypedStateValues, state->opcode()); |
| 277 const ZoneVector<MachineType>* types = | 277 ZoneVector<MachineType> const* types = MachineTypesOf(state->op()); |
| 278 OpParameter<const ZoneVector<MachineType>*>(state); | |
| 279 return (*types)[Top()->index]; | 278 return (*types)[Top()->index]; |
| 280 } | 279 } |
| 281 } | 280 } |
| 282 | 281 |
| 283 | 282 |
| 284 bool StateValuesAccess::iterator::operator!=(iterator& other) { | 283 bool StateValuesAccess::iterator::operator!=(iterator& other) { |
| 285 // We only allow comparison with end(). | 284 // We only allow comparison with end(). |
| 286 CHECK(other.done()); | 285 CHECK(other.done()); |
| 287 return !done(); | 286 return !done(); |
| 288 } | 287 } |
| (...skipping 19 matching lines...) Expand all Loading... |
| 308 } else { | 307 } else { |
| 309 count++; | 308 count++; |
| 310 } | 309 } |
| 311 } | 310 } |
| 312 return count; | 311 return count; |
| 313 } | 312 } |
| 314 | 313 |
| 315 } // namespace compiler | 314 } // namespace compiler |
| 316 } // namespace internal | 315 } // namespace internal |
| 317 } // namespace v8 | 316 } // namespace v8 |
| OLD | NEW |