* commit 'aa3c74d175634ab2222ee5a771b01e7434093dbf': Remove useless x86 fallbacks.
This commit is contained in:
commit
bc109ea47d
@ -580,26 +580,7 @@ ifeq ($(TARGET_ARCH),arm)
|
|||||||
libc_common_cflags += -DSOFTFLOAT
|
libc_common_cflags += -DSOFTFLOAT
|
||||||
libc_common_cflags += -fstrict-aliasing
|
libc_common_cflags += -fstrict-aliasing
|
||||||
libc_crt_target_cflags := -mthumb-interwork
|
libc_crt_target_cflags := -mthumb-interwork
|
||||||
endif # !arm
|
endif # arm
|
||||||
|
|
||||||
ifeq ($(TARGET_ARCH),x86)
|
|
||||||
libc_crt_target_cflags := -m32
|
|
||||||
libc_crt_target_ldflags := -melf_i386
|
|
||||||
endif
|
|
||||||
ifeq ($(TARGET_ARCH),x86_64)
|
|
||||||
libc_crt_target_cflags := -m64
|
|
||||||
libc_crt_target_ldflags := -melf_x86_64
|
|
||||||
endif
|
|
||||||
|
|
||||||
ifeq ($(TARGET_ARCH),$(filter $(TARGET_ARCH),x86 x86_64))
|
|
||||||
libc_common_cflags += -DSOFTFLOAT
|
|
||||||
ifeq ($(ARCH_X86_HAVE_SSE2),true)
|
|
||||||
libc_crt_target_cflags += -DUSE_SSE2=1
|
|
||||||
endif
|
|
||||||
ifeq ($(ARCH_X86_HAVE_SSSE3),true)
|
|
||||||
libc_crt_target_cflags += -DUSE_SSSE3=1
|
|
||||||
endif
|
|
||||||
endif
|
|
||||||
|
|
||||||
ifeq ($(TARGET_ARCH),mips)
|
ifeq ($(TARGET_ARCH),mips)
|
||||||
ifneq ($(ARCH_MIPS_HAS_FPU),true)
|
ifneq ($(ARCH_MIPS_HAS_FPU),true)
|
||||||
@ -609,6 +590,18 @@ ifeq ($(TARGET_ARCH),mips)
|
|||||||
libc_crt_target_cflags := $(TARGET_GLOBAL_CFLAGS)
|
libc_crt_target_cflags := $(TARGET_GLOBAL_CFLAGS)
|
||||||
endif # mips
|
endif # mips
|
||||||
|
|
||||||
|
ifeq ($(TARGET_ARCH),x86)
|
||||||
|
libc_common_cflags += -DSOFTFLOAT
|
||||||
|
libc_crt_target_cflags := -m32
|
||||||
|
libc_crt_target_ldflags := -melf_i386
|
||||||
|
endif # x86
|
||||||
|
|
||||||
|
ifeq ($(TARGET_ARCH),x86_64)
|
||||||
|
libc_common_cflags += -DSOFTFLOAT
|
||||||
|
libc_crt_target_cflags := -m64
|
||||||
|
libc_crt_target_ldflags := -melf_x86_64
|
||||||
|
endif # x86_64
|
||||||
|
|
||||||
# Define ANDROID_SMP appropriately.
|
# Define ANDROID_SMP appropriately.
|
||||||
ifeq ($(TARGET_CPU_SMP),true)
|
ifeq ($(TARGET_CPU_SMP),true)
|
||||||
libc_common_cflags += -DANDROID_SMP=1
|
libc_common_cflags += -DANDROID_SMP=1
|
||||||
|
@ -1,44 +0,0 @@
|
|||||||
/* $OpenBSD: bzero.S,v 1.3 2005/08/07 11:30:38 espie Exp $ */
|
|
||||||
/*
|
|
||||||
* Written by J.T. Conklin <jtc@netbsd.org>.
|
|
||||||
* Public domain.
|
|
||||||
*/
|
|
||||||
|
|
||||||
#include <machine/asm.h>
|
|
||||||
|
|
||||||
ENTRY(bzero)
|
|
||||||
pushl %edi
|
|
||||||
movl 8(%esp),%edi
|
|
||||||
movl 12(%esp),%edx
|
|
||||||
|
|
||||||
cld /* set fill direction forward */
|
|
||||||
xorl %eax,%eax /* set fill data to 0 */
|
|
||||||
|
|
||||||
/*
|
|
||||||
* if the string is too short, it's really not worth the overhead
|
|
||||||
* of aligning to word boundries, etc. So we jump to a plain
|
|
||||||
* unaligned set.
|
|
||||||
*/
|
|
||||||
cmpl $16,%edx
|
|
||||||
jb L1
|
|
||||||
|
|
||||||
movl %edi,%ecx /* compute misalignment */
|
|
||||||
negl %ecx
|
|
||||||
andl $3,%ecx
|
|
||||||
subl %ecx,%edx
|
|
||||||
rep /* zero until word aligned */
|
|
||||||
stosb
|
|
||||||
|
|
||||||
movl %edx,%ecx /* zero by words */
|
|
||||||
shrl $2,%ecx
|
|
||||||
andl $3,%edx
|
|
||||||
rep
|
|
||||||
stosl
|
|
||||||
|
|
||||||
L1: movl %edx,%ecx /* zero remainder by bytes */
|
|
||||||
rep
|
|
||||||
stosb
|
|
||||||
|
|
||||||
popl %edi
|
|
||||||
ret
|
|
||||||
END(bzero)
|
|
@ -1,56 +0,0 @@
|
|||||||
/* $OpenBSD: memset.S,v 1.3 2005/08/07 11:30:38 espie Exp $ */
|
|
||||||
/*
|
|
||||||
* Written by J.T. Conklin <jtc@netbsd.org>.
|
|
||||||
* Public domain.
|
|
||||||
*/
|
|
||||||
|
|
||||||
#include <machine/asm.h>
|
|
||||||
|
|
||||||
ENTRY(memset)
|
|
||||||
pushl %edi
|
|
||||||
pushl %ebx
|
|
||||||
movl 12(%esp),%edi
|
|
||||||
movzbl 16(%esp),%eax /* unsigned char, zero extend */
|
|
||||||
movl 20(%esp),%ecx
|
|
||||||
pushl %edi /* push address of buffer */
|
|
||||||
|
|
||||||
cld /* set fill direction forward */
|
|
||||||
|
|
||||||
/*
|
|
||||||
* if the string is too short, it's really not worth the overhead
|
|
||||||
* of aligning to word boundries, etc. So we jump to a plain
|
|
||||||
* unaligned set.
|
|
||||||
*/
|
|
||||||
cmpl $0x0f,%ecx
|
|
||||||
jle L1
|
|
||||||
|
|
||||||
movb %al,%ah /* copy char to all bytes in word */
|
|
||||||
movl %eax,%edx
|
|
||||||
sall $16,%eax
|
|
||||||
orl %edx,%eax
|
|
||||||
|
|
||||||
movl %edi,%edx /* compute misalignment */
|
|
||||||
negl %edx
|
|
||||||
andl $3,%edx
|
|
||||||
movl %ecx,%ebx
|
|
||||||
subl %edx,%ebx
|
|
||||||
|
|
||||||
movl %edx,%ecx /* set until word aligned */
|
|
||||||
rep
|
|
||||||
stosb
|
|
||||||
|
|
||||||
movl %ebx,%ecx
|
|
||||||
shrl $2,%ecx /* set by words */
|
|
||||||
rep
|
|
||||||
stosl
|
|
||||||
|
|
||||||
movl %ebx,%ecx /* set remainder by bytes */
|
|
||||||
andl $3,%ecx
|
|
||||||
L1: rep
|
|
||||||
stosb
|
|
||||||
|
|
||||||
popl %eax /* pop address of buffer */
|
|
||||||
popl %ebx
|
|
||||||
popl %edi
|
|
||||||
ret
|
|
||||||
END(memset)
|
|
@ -1,21 +0,0 @@
|
|||||||
/* $OpenBSD: strlen.S,v 1.3 2005/08/07 11:30:38 espie Exp $ */
|
|
||||||
/*
|
|
||||||
* Written by J.T. Conklin <jtc@netbsd.org>.
|
|
||||||
* Public domain.
|
|
||||||
*/
|
|
||||||
|
|
||||||
#include <machine/asm.h>
|
|
||||||
|
|
||||||
ENTRY(strlen)
|
|
||||||
pushl %edi
|
|
||||||
movl 8(%esp),%edi /* string address */
|
|
||||||
cld /* set search forward */
|
|
||||||
xorl %eax,%eax /* set search for null terminator */
|
|
||||||
movl $-1,%ecx /* set search for lots of characters */
|
|
||||||
repne /* search! */
|
|
||||||
scasb
|
|
||||||
notl %ecx /* get length by taking complement */
|
|
||||||
leal -1(%ecx),%eax /* and subtracting one */
|
|
||||||
popl %edi
|
|
||||||
ret
|
|
||||||
END(strlen)
|
|
@ -50,7 +50,6 @@ _LIBC_ARCH_COMMON_SRC_FILES += \
|
|||||||
upstream-freebsd/lib/libc/string/wmemcmp.c
|
upstream-freebsd/lib/libc/string/wmemcmp.c
|
||||||
endif
|
endif
|
||||||
|
|
||||||
ifeq ($(ARCH_X86_HAVE_SSE2),true)
|
|
||||||
_LIBC_ARCH_COMMON_SRC_FILES += \
|
_LIBC_ARCH_COMMON_SRC_FILES += \
|
||||||
arch-x86/string/sse2-memset-atom.S \
|
arch-x86/string/sse2-memset-atom.S \
|
||||||
arch-x86/string/sse2-bzero-atom.S \
|
arch-x86/string/sse2-bzero-atom.S \
|
||||||
@ -64,23 +63,7 @@ _LIBC_ARCH_COMMON_SRC_FILES += \
|
|||||||
arch-x86/string/sse2-wcschr-atom.S \
|
arch-x86/string/sse2-wcschr-atom.S \
|
||||||
arch-x86/string/sse2-wcsrchr-atom.S \
|
arch-x86/string/sse2-wcsrchr-atom.S \
|
||||||
arch-x86/string/sse2-wcslen-atom.S \
|
arch-x86/string/sse2-wcslen-atom.S \
|
||||||
arch-x86/string/sse2-wcscmp-atom.S
|
arch-x86/string/sse2-wcscmp-atom.S \
|
||||||
else
|
|
||||||
_LIBC_ARCH_COMMON_SRC_FILES += \
|
|
||||||
arch-x86/string/memset.S \
|
|
||||||
arch-x86/string/strlen.S \
|
|
||||||
arch-x86/string/bzero.S \
|
|
||||||
bionic/memrchr.c \
|
|
||||||
bionic/memchr.c \
|
|
||||||
bionic/strchr.cpp \
|
|
||||||
string/strrchr.c \
|
|
||||||
string/index.c \
|
|
||||||
bionic/strnlen.c \
|
|
||||||
upstream-freebsd/lib/libc/string/wcschr.c \
|
|
||||||
upstream-freebsd/lib/libc/string/wcsrchr.c \
|
|
||||||
upstream-freebsd/lib/libc/string/wcslen.c \
|
|
||||||
upstream-freebsd/lib/libc/string/wcscmp.c
|
|
||||||
endif
|
|
||||||
|
|
||||||
_LIBC_ARCH_STATIC_SRC_FILES := \
|
_LIBC_ARCH_STATIC_SRC_FILES := \
|
||||||
bionic/dl_iterate_phdr_static.c \
|
bionic/dl_iterate_phdr_static.c \
|
||||||
|
Loading…
Reference in New Issue
Block a user