Index: src/compiler/arm/instruction-selector-arm.cc |
diff --git a/src/compiler/arm/instruction-selector-arm.cc b/src/compiler/arm/instruction-selector-arm.cc |
index ae93b27f453f0767343202b036a4c2dd87f182e4..a3ba767eb8317d8864f41f83c195d4813137ba12 100644 |
--- a/src/compiler/arm/instruction-selector-arm.cc |
+++ b/src/compiler/arm/instruction-selector-arm.cc |
@@ -11,7 +11,7 @@ namespace internal { |
namespace compiler { |
// Adds Arm-specific methods for generating InstructionOperands. |
-class ArmOperandGenerator FINAL : public OperandGenerator { |
+class ArmOperandGenerator : public OperandGenerator { |
public: |
explicit ArmOperandGenerator(InstructionSelector* selector) |
: OperandGenerator(selector) {} |
@@ -49,10 +49,10 @@ class ArmOperandGenerator FINAL : public OperandGenerator { |
case kArmRsb: |
return ImmediateFitsAddrMode1Instruction(value); |
- case kArmVldr32: |
- case kArmVstr32: |
- case kArmVldr64: |
- case kArmVstr64: |
+ case kArmVldrF32: |
+ case kArmVstrF32: |
+ case kArmVldrF64: |
+ case kArmVstrF64: |
return value >= -1020 && value <= 1020 && (value % 4) == 0; |
case kArmLdrb: |
@@ -91,6 +91,8 @@ class ArmOperandGenerator FINAL : public OperandGenerator { |
case kArmVmodF64: |
case kArmVnegF64: |
case kArmVsqrtF64: |
+ case kArmVcvtF32F64: |
+ case kArmVcvtF64F32: |
case kArmVcvtF64S32: |
case kArmVcvtF64U32: |
case kArmVcvtS32F64: |
@@ -291,10 +293,10 @@ void InstructionSelector::VisitLoad(Node* node) { |
ArchOpcode opcode; |
switch (rep) { |
case kRepFloat32: |
- opcode = kArmVldr32; |
+ opcode = kArmVldrF32; |
break; |
case kRepFloat64: |
- opcode = kArmVldr64; |
+ opcode = kArmVldrF64; |
break; |
case kRepBit: // Fall through. |
case kRepWord8: |
@@ -346,10 +348,10 @@ void InstructionSelector::VisitStore(Node* node) { |
ArchOpcode opcode; |
switch (rep) { |
case kRepFloat32: |
- opcode = kArmVstr32; |
+ opcode = kArmVstrF32; |
break; |
case kRepFloat64: |
- opcode = kArmVstr64; |
+ opcode = kArmVstrF64; |
break; |
case kRepBit: // Fall through. |
case kRepWord8: |
@@ -683,6 +685,13 @@ void InstructionSelector::VisitInt32UMod(Node* node) { |
} |
+void InstructionSelector::VisitChangeFloat32ToFloat64(Node* node) { |
+ ArmOperandGenerator g(this); |
+ Emit(kArmVcvtF64F32, g.DefineAsRegister(node), |
+ g.UseRegister(node->InputAt(0))); |
+} |
+ |
+ |
void InstructionSelector::VisitChangeInt32ToFloat64(Node* node) { |
ArmOperandGenerator g(this); |
Emit(kArmVcvtF64S32, g.DefineAsRegister(node), |
@@ -711,6 +720,13 @@ void InstructionSelector::VisitChangeFloat64ToUint32(Node* node) { |
} |
+void InstructionSelector::VisitTruncateFloat64ToFloat32(Node* node) { |
+ ArmOperandGenerator g(this); |
+ Emit(kArmVcvtF32F64, g.DefineAsRegister(node), |
+ g.UseRegister(node->InputAt(0))); |
+} |
+ |
+ |
void InstructionSelector::VisitFloat64Add(Node* node) { |
ArmOperandGenerator g(this); |
Int32BinopMatcher m(node); |