From: Austin Clements Date: Wed, 11 Nov 2015 15:23:44 +0000 (-0500) Subject: runtime: fix use of xadd64 X-Git-Tag: go1.6beta1~556 X-Git-Url: http://www.git.cypherpunks.su/?a=commitdiff_plain;h=7d1d642956940f78e7f1531ec9810048f4358f85;p=gostls13.git runtime: fix use of xadd64 Commit 7407d8e was rebased over the switch to runtime/internal/atomic and introduced a call to xadd64, which no longer exists. Fix that call. Change-Id: I99c93469794c16504ae4a8ffe3066ac382c66a3a Reviewed-on: https://go-review.googlesource.com/16816 Reviewed-by: Brad Fitzpatrick Reviewed-by: Rick Hudson --- diff --git a/src/runtime/mgcsweep.go b/src/runtime/mgcsweep.go index 84b6181b6e..812ba60f40 100644 --- a/src/runtime/mgcsweep.go +++ b/src/runtime/mgcsweep.go @@ -392,7 +392,7 @@ func reimburseSweepCredit(unusableBytes uintptr) { // Nobody cares about the credit. Avoid the atomic. return } - xadd64(&mheap_.spanBytesAlloc, -int64(unusableBytes)) + atomic.Xadd64(&mheap_.spanBytesAlloc, -int64(unusableBytes)) } func dumpFreeList(s *mspan) {