summaryrefslogtreecommitdiffhomepage
path: root/pkg/atomicbitops/atomic_bitops.go
diff options
context:
space:
mode:
authorgVisor bot <gvisor-bot@google.com>2019-10-10 12:46:46 -0700
committergVisor bot <gvisor-bot@google.com>2019-10-10 12:46:46 -0700
commit14952d01fb5fa03a40dbb241b4c12f5a400a3577 (patch)
tree247cfaf9f707a2c2fb63b8207479415e37b95c2b /pkg/atomicbitops/atomic_bitops.go
parentbf870c1a423063eb86a62c6268fe5d83fb6b87ba (diff)
parentebbf2b7fbdcda80d158b72276786a4a1dcad664a (diff)
Merge pull request #909 from xiaobo55x:atomic_bitsops
PiperOrigin-RevId: 274011064
Diffstat (limited to 'pkg/atomicbitops/atomic_bitops.go')
-rw-r--r--pkg/atomicbitops/atomic_bitops.go5
1 files changed, 3 insertions, 2 deletions
diff --git a/pkg/atomicbitops/atomic_bitops.go b/pkg/atomicbitops/atomic_bitops.go
index 63aa2b7f1..fcc41a9ea 100644
--- a/pkg/atomicbitops/atomic_bitops.go
+++ b/pkg/atomicbitops/atomic_bitops.go
@@ -12,11 +12,12 @@
// See the License for the specific language governing permissions and
// limitations under the License.
-// +build amd64
+// +build amd64 arm64
// Package atomicbitops provides basic bitwise operations in an atomic way.
// The implementation on amd64 leverages the LOCK prefix directly instead of
-// relying on the generic cas primitives.
+// relying on the generic cas primitives, and the arm64 leverages the LDAXR
+// and STLXR pair primitives.
//
// WARNING: the bitwise ops provided in this package doesn't imply any memory
// ordering. Using them to construct locks must employ proper memory barriers.