| 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 #include "src/base/adapters.h" | 5 #include "src/base/adapters.h" |
| 6 #include "src/compiler/instruction-selector-impl.h" | 6 #include "src/compiler/instruction-selector-impl.h" |
| 7 #include "src/compiler/node-matchers.h" | 7 #include "src/compiler/node-matchers.h" |
| 8 #include "src/compiler/node-properties.h" | 8 #include "src/compiler/node-properties.h" |
| 9 #include "src/ppc/frames-ppc.h" | 9 #include "src/ppc/frames-ppc.h" |
| 10 | 10 |
| (...skipping 309 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 320 } else if (g.CanBeImmediate(base, mode)) { | 320 } else if (g.CanBeImmediate(base, mode)) { |
| 321 Emit(opcode | AddressingModeField::encode(kMode_MRI), g.NoOutput(), | 321 Emit(opcode | AddressingModeField::encode(kMode_MRI), g.NoOutput(), |
| 322 g.UseRegister(offset), g.UseImmediate(base), g.UseRegister(value)); | 322 g.UseRegister(offset), g.UseImmediate(base), g.UseRegister(value)); |
| 323 } else { | 323 } else { |
| 324 Emit(opcode | AddressingModeField::encode(kMode_MRR), g.NoOutput(), | 324 Emit(opcode | AddressingModeField::encode(kMode_MRR), g.NoOutput(), |
| 325 g.UseRegister(base), g.UseRegister(offset), g.UseRegister(value)); | 325 g.UseRegister(base), g.UseRegister(offset), g.UseRegister(value)); |
| 326 } | 326 } |
| 327 } | 327 } |
| 328 } | 328 } |
| 329 | 329 |
| 330 // Architecture supports unaligned access, therefore VisitLoad is used instead |
| 331 void InstructionSelector::VisitUnalignedLoad(Node* node) { UNREACHABLE(); } |
| 332 |
| 333 // Architecture supports unaligned access, therefore VisitStore is used instead |
| 334 void InstructionSelector::VisitUnalignedStore(Node* node) { UNREACHABLE(); } |
| 330 | 335 |
| 331 void InstructionSelector::VisitCheckedLoad(Node* node) { | 336 void InstructionSelector::VisitCheckedLoad(Node* node) { |
| 332 CheckedLoadRepresentation load_rep = CheckedLoadRepresentationOf(node->op()); | 337 CheckedLoadRepresentation load_rep = CheckedLoadRepresentationOf(node->op()); |
| 333 PPCOperandGenerator g(this); | 338 PPCOperandGenerator g(this); |
| 334 Node* const base = node->InputAt(0); | 339 Node* const base = node->InputAt(0); |
| 335 Node* const offset = node->InputAt(1); | 340 Node* const offset = node->InputAt(1); |
| 336 Node* const length = node->InputAt(2); | 341 Node* const length = node->InputAt(2); |
| 337 ArchOpcode opcode = kArchNop; | 342 ArchOpcode opcode = kArchNop; |
| 338 switch (load_rep.representation()) { | 343 switch (load_rep.representation()) { |
| 339 case MachineRepresentation::kWord8: | 344 case MachineRepresentation::kWord8: |
| (...skipping 1681 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2021 // static | 2026 // static |
| 2022 MachineOperatorBuilder::AlignmentRequirements | 2027 MachineOperatorBuilder::AlignmentRequirements |
| 2023 InstructionSelector::AlignmentRequirements() { | 2028 InstructionSelector::AlignmentRequirements() { |
| 2024 return MachineOperatorBuilder::AlignmentRequirements:: | 2029 return MachineOperatorBuilder::AlignmentRequirements:: |
| 2025 FullUnalignedAccessSupport(); | 2030 FullUnalignedAccessSupport(); |
| 2026 } | 2031 } |
| 2027 | 2032 |
| 2028 } // namespace compiler | 2033 } // namespace compiler |
| 2029 } // namespace internal | 2034 } // namespace internal |
| 2030 } // namespace v8 | 2035 } // namespace v8 |
| OLD | NEW |