// NOTE: Windows externalthreadhandler expects memclr to preserve DX.
+// See memclrNoHeapPointers Go doc for important implementation constraints.
+
// func memclrNoHeapPointers(ptr unsafe.Pointer, n uintptr)
TEXT runtime·memclrNoHeapPointers(SB), NOSPLIT, $0-8
MOVL ptr+0(FP), DI
// NOTE: Windows externalthreadhandler expects memclr to preserve DX.
+// See memclrNoHeapPointers Go doc for important implementation constraints.
+
// func memclrNoHeapPointers(ptr unsafe.Pointer, n uintptr)
TEXT runtime·memclrNoHeapPointers(SB), NOSPLIT, $0-16
MOVQ ptr+0(FP), DI
#define N R12
#define TMP R12 /* N and TMP don't overlap */
+// See memclrNoHeapPointers Go doc for important implementation constraints.
+
// func memclrNoHeapPointers(ptr unsafe.Pointer, n uintptr)
TEXT runtime·memclrNoHeapPointers(SB),NOSPLIT,$0-8
MOVW ptr+0(FP), TO
#include "textflag.h"
+// See memclrNoHeapPointers Go doc for important implementation constraints.
+
// func memclrNoHeapPointers(ptr unsafe.Pointer, n uintptr)
TEXT runtime·memclrNoHeapPointers(SB),NOSPLIT,$0-16
MOVD ptr+0(FP), R0
#include "go_asm.h"
#include "textflag.h"
+// See memclrNoHeapPointers Go doc for important implementation constraints.
+
// func memclrNoHeapPointers(ptr unsafe.Pointer, n uintptr)
TEXT runtime·memclrNoHeapPointers(SB),NOSPLIT,$0-16
MOVV ptr+0(FP), R1
#define MOVWLO MOVWL
#endif
+// See memclrNoHeapPointers Go doc for important implementation constraints.
+
// func memclrNoHeapPointers(ptr unsafe.Pointer, n uintptr)
TEXT runtime·memclrNoHeapPointers(SB),NOSPLIT,$0-8
MOVW n+4(FP), R2
#include "textflag.h"
+// See memclrNoHeapPointers Go doc for important implementation constraints.
+
// func memclrNoHeapPointers(ptr unsafe.Pointer, n uintptr)
TEXT runtime·memclrNoHeapPointers(SB), NOSPLIT, $0-8
MOVL ptr+0(FP), DI
#include "textflag.h"
+// See memclrNoHeapPointers Go doc for important implementation constraints.
+
// func memclrNoHeapPointers(ptr unsafe.Pointer, n uintptr)
TEXT runtime·memclrNoHeapPointers(SB),NOSPLIT,$0-16
MOVQ ptr+0(FP), DI
#include "textflag.h"
+// See memclrNoHeapPointers Go doc for important implementation constraints.
+
// func memclrNoHeapPointers(ptr unsafe.Pointer, n uintptr)
TEXT runtime·memclrNoHeapPointers(SB), NOSPLIT|NOFRAME, $0-16
MOVD ptr+0(FP), R3
#include "textflag.h"
+// See memclrNoHeapPointers Go doc for important implementation constraints.
+
// void runtime·memclrNoHeapPointers(void*, uintptr)
TEXT runtime·memclrNoHeapPointers(SB),NOSPLIT,$0-16
MOV ptr+0(FP), T1
#include "textflag.h"
+// See memclrNoHeapPointers Go doc for important implementation constraints.
+
// func memclrNoHeapPointers(ptr unsafe.Pointer, n uintptr)
TEXT runtime·memclrNoHeapPointers(SB),NOSPLIT|NOFRAME,$0-16
MOVD ptr+0(FP), R4
#include "textflag.h"
+// See memclrNoHeapPointers Go doc for important implementation constraints.
+
// func memclrNoHeapPointers(ptr unsafe.Pointer, n uintptr)
TEXT runtime·memclrNoHeapPointers(SB), NOSPLIT, $0-16
MOVD ptr+0(FP), R0
// *ptr is uninitialized memory (e.g., memory that's being reused
// for a new allocation) and hence contains only "junk".
//
+// memclrNoHeapPointers ensures that if ptr is pointer-aligned, and n
+// is a multiple of the pointer size, then any pointer-aligned,
+// pointer-sized portion is cleared atomically. Despite the function
+// name, this is necessary because this function is the underlying
+// implementation of typedmemclr and memclrHasPointers. See the doc of
+// memmove for more details.
+//
// The (CPU-specific) implementations of this function are in memclr_*.s.
+//
//go:noescape
func memclrNoHeapPointers(ptr unsafe.Pointer, n uintptr)