81fadf1c8d
They are wrappers of libc functions that use no stack. Mark them nosplit so the linker won't patch it to call __morestack_non_split. Reviewed-on: https://go-review.googlesource.com/c/gofrontend/+/183629 From-SVN: r272633
18 lines
450 B
C
18 lines
450 B
C
/* go-memclr.c -- clear a memory buffer
|
|
|
|
Copyright 2016 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. */
|
|
|
|
#include "runtime.h"
|
|
|
|
void memclrNoHeapPointers(void *, uintptr)
|
|
__asm__ (GOSYM_PREFIX "runtime.memclrNoHeapPointers")
|
|
__attribute__ ((no_split_stack));
|
|
|
|
void
|
|
memclrNoHeapPointers (void *p1, uintptr len)
|
|
{
|
|
__builtin_memset (p1, 0, len);
|
|
}
|