From 9cb79e9536a2f7977f9139a808f912d216094ecc Mon Sep 17 00:00:00 2001 From: Keith Randall Date: Mon, 25 Apr 2016 14:12:26 -0700 Subject: runtime: arm5, fix large-offset floating-point stores The code sequence for large-offset floating-point stores includes adding the base pointer to r11. Make sure we can interpret that instruction correctly. Fixes build. Fixes #15440 Change-Id: I7fe5a4a57e08682967052bf77c54e0ec47fcb53e Reviewed-on: https://go-review.googlesource.com/22440 Reviewed-by: Michael Hudson-Doyle --- src/runtime/softfloat_arm.go | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) (limited to 'src/runtime/softfloat_arm.go') diff --git a/src/runtime/softfloat_arm.go b/src/runtime/softfloat_arm.go index b1f1a72925..648b2e1169 100644 --- a/src/runtime/softfloat_arm.go +++ b/src/runtime/softfloat_arm.go @@ -168,14 +168,15 @@ execute: } return 1 } - if i == 0xe08bb00d { - // add sp to r11. - // might be part of a large stack offset address + if i&0xfffffff0 == 0xe08bb000 { + r := i & 0xf + // add r to r11. + // might be part of a large offset address calculation // (or might not, but again no harm done). - regs[11] += regs[13] + regs[11] += regs[r] if fptrace > 0 { - print("*** cpu R[11] += R[13] ", hex(regs[11]), "\n") + print("*** cpu R[11] += R[", r, "] ", hex(regs[11]), "\n") } return 1 } -- cgit v1.3