]> Cypherpunks repositories - gostls13.git/commit
[dev.power64] runtime: fix atomicor8 for power64x
authorAustin Clements <austin@google.com>
Tue, 28 Oct 2014 19:57:33 +0000 (15:57 -0400)
committerAustin Clements <austin@google.com>
Tue, 28 Oct 2014 19:57:33 +0000 (15:57 -0400)
commit87b4149b22feb9d8d52da1730b455e39436a3a8d
tree18ab3a6f8079b14659188eb48b086542da23f168
parentc8f50b298cdf378889cff2a1b7355f7a1cb08a0a
[dev.power64] runtime: fix atomicor8 for power64x

Power64 servers do not currently support sub-word size atomic
memory access, so atomicor8 uses word size atomic access.
However, previously atomicor8 made no attempt to align this
access, resulting in errors.  Fix this by aligning the pointer
to a word boundary and shifting the value appropriately.
Since atomicor8 is used in GC, add a test to runtime·check to
make sure this doesn't break in the future.

This also fixes an incorrect branch label, an incorrectly
sized argument move, and adds argument names to help go vet.

LGTM=rsc
R=rsc, dave
CC=golang-codereviews
https://golang.org/cl/165820043
src/runtime/asm_power64x.s
src/runtime/runtime.c