A call to memcpy is sometimes created by the compiler, for example when
compiling with -opt=s or opt=2.
Этот коммит содержится в:
Ayke van Laethem 2019-09-16 14:11:53 +02:00 коммит произвёл Ron Evans
родитель b4859240e1
коммит e0ebc75df2

Просмотреть файл

@ -132,3 +132,9 @@ func libc_memset(ptr unsafe.Pointer, c byte, size uintptr) {
func libc_memmove(dst, src unsafe.Pointer, size uintptr) {
memmove(dst, src, size)
}
// Implement memcpy for LLVM and compiler-rt.
//go:export memcpy
func libc_memcpy(dst, src unsafe.Pointer, size uintptr) {
memcpy(dst, src, size)
}