1*93cec697SDaniel Boulby//===-- aeabi_memcpy.S - EABI memcpy implementation -----------------------===// 2*93cec697SDaniel Boulby// 3*93cec697SDaniel Boulby// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. 4*93cec697SDaniel Boulby// See https://llvm.org/LICENSE.txt for license information. 5*93cec697SDaniel Boulby// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception 6*93cec697SDaniel Boulby// 7*93cec697SDaniel Boulby//===----------------------------------------------------------------------===// 8*93cec697SDaniel Boulby 9*93cec697SDaniel Boulby#include "../assembly.h" 10*93cec697SDaniel Boulby 11*93cec697SDaniel Boulby// void __aeabi_memcpy(void *dest, void *src, size_t n) { memcpy(dest, src, n); } 12*93cec697SDaniel Boulby 13*93cec697SDaniel Boulby .syntax unified 14*93cec697SDaniel Boulby .p2align 2 15*93cec697SDaniel BoulbyDEFINE_COMPILERRT_FUNCTION(__aeabi_memcpy) 16*93cec697SDaniel Boulby#ifdef USE_THUMB_1 17*93cec697SDaniel Boulby push {r7, lr} 18*93cec697SDaniel Boulby bl memcpy 19*93cec697SDaniel Boulby pop {r7, pc} 20*93cec697SDaniel Boulby#else 21*93cec697SDaniel Boulby b memcpy 22*93cec697SDaniel Boulby#endif 23*93cec697SDaniel BoulbyEND_COMPILERRT_FUNCTION(__aeabi_memcpy) 24*93cec697SDaniel Boulby 25*93cec697SDaniel BoulbyDEFINE_AEABI_FUNCTION_ALIAS(__aeabi_memcpy4, __aeabi_memcpy) 26*93cec697SDaniel BoulbyDEFINE_AEABI_FUNCTION_ALIAS(__aeabi_memcpy8, __aeabi_memcpy) 27*93cec697SDaniel Boulby 28*93cec697SDaniel BoulbyNO_EXEC_STACK_DIRECTIVE 29*93cec697SDaniel Boulby 30