Index: src/arm64/deoptimizer-arm64.cc |
diff --git a/src/arm64/deoptimizer-arm64.cc b/src/arm64/deoptimizer-arm64.cc |
index a70104fcc28992db7656326f5e9126a7c6e4c0e3..cd2899a5e29f71562f8150275b532d7f360ecf44 100644 |
--- a/src/arm64/deoptimizer-arm64.cc |
+++ b/src/arm64/deoptimizer-arm64.cc |
@@ -167,11 +167,13 @@ void Deoptimizer::TableEntryGenerator::Generate() { |
} |
// Copy FP registers to the input frame. |
+ CPURegList copy_fp_to_input = saved_fp_registers; |
for (int i = 0; i < saved_fp_registers.Count(); i++) { |
- int dst_offset = FrameDescription::double_registers_offset() + |
- (i * kDoubleSize); |
int src_offset = kFPRegistersOffset + (i * kDoubleSize); |
__ Peek(x2, src_offset); |
+ CPURegister reg = copy_fp_to_input.PopLowestIndex(); |
+ int dst_offset = FrameDescription::double_registers_offset() + |
+ (reg.code() * kDoubleSize); |
Jakob Kummerow
2016/03/09 11:07:25
The change here is s/i/reg.code()/. We must not us
|
__ Str(x2, MemOperand(x1, dst_offset)); |
} |
@@ -240,11 +242,11 @@ void Deoptimizer::TableEntryGenerator::Generate() { |
DCHECK(!saved_fp_registers.IncludesAliasOf(crankshaft_fp_scratch) && |
!saved_fp_registers.IncludesAliasOf(fp_zero) && |
!saved_fp_registers.IncludesAliasOf(fp_scratch)); |
- int src_offset = FrameDescription::double_registers_offset(); |
while (!saved_fp_registers.IsEmpty()) { |
const CPURegister reg = saved_fp_registers.PopLowestIndex(); |
+ int src_offset = FrameDescription::double_registers_offset() + |
+ (reg.code() * kDoubleSize); |
__ Ldr(reg, MemOperand(x1, src_offset)); |
- src_offset += kDoubleSize; |
} |
// Push state from the last output frame. |