aboutsummaryrefslogtreecommitdiff
path: root/src/runtime/softfloat_arm.go
diff options
context:
space:
mode:
authorMichael Hudson-Doyle <michael.hudson@canonical.com>2015-09-04 14:57:59 +1200
committerMichael Hudson-Doyle <michael.hudson@canonical.com>2015-09-04 06:43:35 +0000
commit40af15f28e63709859138f00179dc7bcdfdc834b (patch)
treec7694e73a925c9bf692e075b6d9a9e6d7341043b /src/runtime/softfloat_arm.go
parent821e124c24c2b2d753be22a04a3b20b7bf579627 (diff)
downloadgo-40af15f28e63709859138f00179dc7bcdfdc834b.tar.xz
runtime: teach softfloat interpreter about "add r11, pc, r11"
This is generated during fp code when -shared is active. Change-Id: Ia1092299b9c3b63ff771ca4842158b42c34bd008 Reviewed-on: https://go-review.googlesource.com/14286 Reviewed-by: Ian Lance Taylor <iant@golang.org> Reviewed-by: Dave Cheney <dave@cheney.net>
Diffstat (limited to 'src/runtime/softfloat_arm.go')
-rw-r--r--src/runtime/softfloat_arm.go11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/runtime/softfloat_arm.go b/src/runtime/softfloat_arm.go
index c6eba58f1c..202e7bbf86 100644
--- a/src/runtime/softfloat_arm.go
+++ b/src/runtime/softfloat_arm.go
@@ -157,6 +157,17 @@ execute:
}
return 1
}
+ if i == 0xe08fb00b {
+ // add pc to r11
+ // might be part of a PIC floating point move
+ // (or might not, but again no harm done).
+ regs[11] += uint32(uintptr(unsafe.Pointer(pc))) + 8
+
+ if fptrace > 0 {
+ print("*** cpu R[11] += pc ", hex(regs[11]), "\n")
+ }
+ return 1
+ }
if i == 0xe08bb00d {
// add sp to r11.
// might be part of a large stack offset address