From fbe4e644c0c8f1303ec91a25b8da6e626976500c Mon Sep 17 00:00:00 2001 From: Cherry Zhang Date: Wed, 8 May 2019 17:40:45 +0000 Subject: runtime: use builtin memmove directly We can use the intrinsic memmove directly, without going through C. Reviewed-on: https://go-review.googlesource.com/c/gofrontend/+/170004 * go-gcc.cc (Gcc_backend::Gcc_backend): Define memmove builtin. From-SVN: r271016 --- libgo/runtime/go-memmove.c | 16 ---------------- 1 file changed, 16 deletions(-) delete mode 100644 libgo/runtime/go-memmove.c (limited to 'libgo/runtime') diff --git a/libgo/runtime/go-memmove.c b/libgo/runtime/go-memmove.c deleted file mode 100644 index a6fda08..0000000 --- a/libgo/runtime/go-memmove.c +++ /dev/null @@ -1,16 +0,0 @@ -/* go-memmove.c -- move one memory buffer to another - - 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 move(void *, void *, uintptr) - __asm__ (GOSYM_PREFIX "runtime.memmove"); - -void -move (void *p1, void *p2, uintptr len) -{ - __builtin_memmove (p1, p2, len); -} -- cgit v1.1