mirror of
https://github.com/apache/nuttx.git
synced 2026-06-07 01:05:54 +08:00
Eliminate CONFIG_ARCH_OPTIMIZED_FUNCTIONS. Move options to select architectur-specific C library options from libc/Kconfig to libc/machine/Kconfig and rename.
This commit is contained in:
@@ -43,7 +43,7 @@ CSRCS += lib_strnlen.c lib_strncasecmp.c lib_strncat.c lib_strncmp.c
|
||||
CSRCS += lib_strncpy.c lib_strndup.c lib_strcasestr.c lib_strpbrk.c
|
||||
CSRCS += lib_strrchr.c lib_strspn.c lib_strstr.c lib_strtok.c lib_strtokr.c
|
||||
|
||||
ifneq ($(CONFIG_ARCH_MEMCPY),y)
|
||||
ifneq ($(CONFIG_LIBC_ARCH_MEMCPY),y)
|
||||
ifeq ($(CONFIG_MEMCPY_VIK),y)
|
||||
CSRCS += lib_vikmemcpy.c
|
||||
else
|
||||
|
||||
@@ -49,7 +49,7 @@
|
||||
* Public Functions
|
||||
****************************************************************************/
|
||||
|
||||
#ifndef CONFIG_ARCH_MEMCMP
|
||||
#ifndef CONFIG_LIBC_ARCH_MEMCMP
|
||||
int memcmp(FAR const void *s1, FAR const void *s2, size_t n)
|
||||
{
|
||||
unsigned char *p1 = (unsigned char *)s1;
|
||||
|
||||
@@ -53,7 +53,7 @@
|
||||
* Name: memcpy
|
||||
****************************************************************************/
|
||||
|
||||
#ifndef CONFIG_ARCH_MEMCPY
|
||||
#ifndef CONFIG_LIBC_ARCH_MEMCPY
|
||||
FAR void *memcpy(FAR void *dest, FAR const void *src, size_t n)
|
||||
{
|
||||
FAR unsigned char *pout = (FAR unsigned char *)dest;
|
||||
|
||||
@@ -49,7 +49,7 @@
|
||||
* Public Functions
|
||||
****************************************************************************/
|
||||
|
||||
#ifndef CONFIG_ARCH_MEMMOVE
|
||||
#ifndef CONFIG_LIBC_ARCH_MEMMOVE
|
||||
FAR void *memmove(FAR void *dest, FAR const void *src, size_t count)
|
||||
{
|
||||
FAR char *tmp;
|
||||
|
||||
@@ -63,7 +63,7 @@
|
||||
* Public Functions
|
||||
****************************************************************************/
|
||||
|
||||
#ifndef CONFIG_ARCH_MEMSET
|
||||
#ifndef CONFIG_LIBC_ARCH_MEMSET
|
||||
FAR void *memset(FAR void *s, int c, size_t n)
|
||||
{
|
||||
#ifdef CONFIG_MEMSET_OPTSPEED
|
||||
|
||||
@@ -59,7 +59,7 @@
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
#ifndef CONFIG_ARCH_STRCHR
|
||||
#ifndef CONFIG_LIBC_ARCH_STRCHR
|
||||
FAR char *strchr(FAR const char *s, int c)
|
||||
{
|
||||
if (s)
|
||||
|
||||
@@ -45,7 +45,7 @@
|
||||
* Public Functions
|
||||
****************************************************************************/
|
||||
|
||||
#ifndef CONFIG_ARCH_STRCMP
|
||||
#ifndef CONFIG_LIBC_ARCH_STRCMP
|
||||
int strcmp(FAR const char *cs, FAR const char *ct)
|
||||
{
|
||||
register signed char result;
|
||||
|
||||
@@ -57,7 +57,7 @@
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
#ifndef CONFIG_ARCH_STRCPY
|
||||
#ifndef CONFIG_LIBC_ARCH_STRCPY
|
||||
FAR char *strcpy(FAR char *dest, FAR const char *src)
|
||||
{
|
||||
char *tmp = dest;
|
||||
|
||||
@@ -45,7 +45,7 @@
|
||||
* Public Functions
|
||||
****************************************************************************/
|
||||
|
||||
#ifndef CONFIG_ARCH_STRLEN
|
||||
#ifndef CONFIG_LIBC_ARCH_STRLEN
|
||||
size_t strlen(const char *s)
|
||||
{
|
||||
const char *sc;
|
||||
|
||||
@@ -49,7 +49,7 @@
|
||||
* Name: strncpy
|
||||
****************************************************************************/
|
||||
|
||||
#ifndef CONFIG_ARCH_STRNCPY
|
||||
#ifndef CONFIG_LIBC_ARCH_STRNCPY
|
||||
char *strncpy(FAR char *dest, FAR const char *src, size_t n)
|
||||
{
|
||||
char *ret = dest; /* Value to be returned */
|
||||
|
||||
@@ -52,7 +52,7 @@
|
||||
* Public Functions
|
||||
****************************************************************************/
|
||||
|
||||
#ifndef CONFIG_ARCH_STRNLEN
|
||||
#ifndef CONFIG_LIBC_ARCH_STRNLEN
|
||||
size_t strnlen(const char *s, size_t maxlen)
|
||||
{
|
||||
const char *sc;
|
||||
|
||||
Reference in New Issue
Block a user