aboutsummaryrefslogtreecommitdiff
path: root/src/runtime/memclr_ppc64x.s
diff options
context:
space:
mode:
authorRuss Cox <rsc@golang.org>2014-12-05 19:13:20 -0500
committerRuss Cox <rsc@golang.org>2014-12-05 19:13:20 -0500
commit09d92b6bbf26f195a1fe136513238d227bc73f82 (patch)
tree1c053dbb28cfcaf4cae911f24f096b581c384d4b /src/runtime/memclr_ppc64x.s
parentdcb2ec3b654eb42d8e6bb6e66801ddf2f7f21c7a (diff)
downloadgo-09d92b6bbf26f195a1fe136513238d227bc73f82.tar.gz
go-09d92b6bbf26f195a1fe136513238d227bc73f82.zip
all: power64 is now ppc64
Fixes #8654. LGTM=austin R=austin CC=golang-codereviews https://golang.org/cl/180600043
Diffstat (limited to 'src/runtime/memclr_ppc64x.s')
-rw-r--r--src/runtime/memclr_ppc64x.s20
1 files changed, 20 insertions, 0 deletions
diff --git a/src/runtime/memclr_ppc64x.s b/src/runtime/memclr_ppc64x.s
new file mode 100644
index 0000000000..535faa1c0e
--- /dev/null
+++ b/src/runtime/memclr_ppc64x.s
@@ -0,0 +1,20 @@
+// Copyright 2014 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// +build ppc64 ppc64le
+
+#include "textflag.h"
+
+// void runtime·memclr(void*, uintptr)
+TEXT runtime·memclr(SB),NOSPLIT,$0-16
+ MOVD ptr+0(FP), R3
+ MOVD n+8(FP), R4
+ CMP R4, $0
+ BEQ done
+ SUB $1, R3
+ MOVD R4, CTR
+ MOVBU R0, 1(R3)
+ BC 25, 0, -1(PC) // bdnz+ $-4
+done:
+ RETURN