1// Copyright 2018 The Go Authors. All rights reserved.
2// Use of this source code is governed by a BSD-style
3// license that can be found in the LICENSE file.
4
5#include "textflag.h"
6
7// func memclrNoHeapPointers(ptr unsafe.Pointer, n uintptr)
8TEXT runtime·memclrNoHeapPointers(SB), NOSPLIT, $0-16
9	MOVD ptr+0(FP), R0
10	MOVD n+8(FP), R1
11
12loop:
13	Loop
14		Get R1
15		I64Eqz
16		If
17			RET
18		End
19
20		Get R0
21		I32WrapI64
22		I64Const $0
23		I64Store8 $0
24
25		Get R0
26		I64Const $1
27		I64Add
28		Set R0
29
30		Get R1
31		I64Const $1
32		I64Sub
33		Set R1
34
35		Br loop
36	End
37	UNDEF
38