Age | Commit message (Collapse) | Author |
|
|
|
added check for src == dest. run tested.
text data bss dec hex filename
- 39 0 0 39 27 libc/string/i386/memmove.os
+ 37 0 0 37 25 libc/string/i386/memmove.os
|
|
memchr: add small embedded test
strnlen: make small embedded test easier to use
strncmp: reformat assembly to make it readable, no code changes
(verified with objdump)
text data bss dec hex filename
- 46 0 0 46 2e libc/string/i386/strncat.os
+ 39 0 0 39 27 libc/string/i386/strncat.os
|
|
text data bss dec hex filename
- 25 0 0 25 19 libc/string/i386/strnlen.os
+ 24 0 0 24 18 libc/string/i386/strnlen.os
|
|
|
|
implement inline versions of some of them.
Enable only those which result roughly in the same
code size as using out-or-line versions.
None of this affects users, installed headers won't have
any trace of it.
|
|
strrchr: smaller i386 version
text data bss dec hex filename
- 33 0 0 33 21 libc/string/i386/memchr.o
+ 28 0 0 28 1c libc/string/i386/memchr.o
- 31 0 0 31 1f libc/string/i386/strrchr.o
+ 26 0 0 26 1a libc/string/i386/strrchr.o
|
|
"Bounds Checking Projects... This project has been abandoned"
for four years at least.
|
|
for ancient compilers. none of other string/*.c files have them.
|
|
it is dead (not supported by gcc) for years.
(more of it remains in multiple copies of sigaction.c)
|
|
text data bss dec hex filename
- 39 0 0 39 27 libc/string/i386/memcpy.os
+ 35 0 0 35 23 libc/string/i386/memcpy.os
|
|
TARGET_SUBARCH implementation too.
Signed-off-by: Carmelo Amoroso <carmelo.amoroso@st.com>
|
|
|
|
Signed-off-by: Filippo Arcidiacono <filippo.arcidiacono@st.com>
|
|
Appears to build fine (several .configs tried)
|
|
|
|
|
|
|
|
|
|
Looks a bit like we wouldn't need to calculate the carry flag there?
|
|
Add a new strncmp testcase.
|
|
Closes issue #5194
|
|
UCLIBC_HAS_STRING_GENERIC_OPT=y
UCLIBC_HAS_STRING_ARCH_OPT is not set
by making WORD_COPY_FWD macros visible.
Signed-off-by: Carmelo Amoroso <carmelo.amoroso@st.com>
|
|
found in newlib rather than the ones found in glibc. This should make them
smaller and (hopefully) make them compile with newer versions of gcc.
|
|
|
|
|
|
__UCLIBC_HAS_LOCALE__ macro but it does not include <features.h>, so that macro is never defined. This causes problems with strcoll when locale support is enabled.
|
|
@STMicroelectronics).
This implementation is based on 'backward copying'.
Signed-off-by: Carmelo Amoroso <carmelo.amoroso@st.com>
|
|
libc/stdlib/_strtod.c -> tst_wcstod;
libc/stdlib/stdlib.c -> tst_mblen, tst_mbtowc, tst_wctomb;
libc/stdio/_scanf.c -> tst_swscanf;
libc/string/strncmp.c -> tst_wcsncmp;
libc/misc/wchar/wchar.c -> tst_mbrlen, tst_mbrtowc, tst_wcswidth.
Signed-off-by: Filippo Arcidiacono <filippo.arcidiacono@st.com>
Signed-off-by: Carmelo Amoroso <carmelo.amoroso@st.com>
|
|
|
|
|
|
no libc_hidden_def exists for the function.
|
|
The obsolete functions bcopy, index, etc. are not supposed to be used within
uClibc itself. Hence, there is no libc_hidden_def for them, but the previous
patch did not just move libc_hidden_protos, it also added new ones for the
legacy functions. As a result, programs which use these functions can no
longer link with uClibc.
This fixes it by removing the unnecessary libc_hidden_protos. I've also
removed all inclusions of <strings.h> from uClibc source files: since we
define _GNU_SOURCE, it is sufficient to include <string.h>. We then do not
need to duplicate the libc_hidden_proto block in <strings.h>.
|
|
|
|
by adding include <wchar.h> in strcasecmp.c
|
|
|
|
sources separately for now.
|
|
|
|
|
|
|
|
|
|
in string.h and strings.h. This caught unguarded string ops in
libc/inet/ethers.c __ether_line_w() function.
I will wait for fallout reports for a week or so,
then continue converting more libc_hidden_proto's.
|
|
|
|
|
|
|
|
By capping max padding to not be bigger than three next insns,
we avoid having ridiculously big NOPs like this one:
53:66 66 66 66 2e 0f 1f nopw %cs:0x0(%rax,%rax,1)
5a:84 00 00 00 00 00
which was bigger than next three insns combined!
Size changes:
text data bss dec hex filename
102 0 0 102 66 x86_64/memcpy.o
102 0 0 102 66 x86_64.old/memcpy.o
90 0 0 90 5a x86_64/mempcpy.o
102 0 0 102 66 x86_64.old/mempcpy.o
210 0 0 210 d2 x86_64/memset.o
242 0 0 242 f2 x86_64.old/memset.o
213 0 0 213 d5 x86_64/stpcpy.o
220 0 0 220 dc x86_64.old/stpcpy.o
428 0 0 428 1ac x86_64/strcat.o
444 0 0 444 1bc x86_64.old/strcat.o
417 0 0 417 1a1 x86_64/strchr.o
418 0 0 418 1a2 x86_64.old/strchr.o
33 0 0 33 21 x86_64/strcmp.o
33 0 0 33 21 x86_64.old/strcmp.o
213 0 0 213 d5 x86_64/strcpy.o
220 0 0 220 dc x86_64.old/strcpy.o
135 0 0 135 87 x86_64/strcspn.o
151 0 0 151 97 x86_64.old/strcspn.o
225 0 0 225 e1 x86_64/strlen.o
233 0 0 233 e9 x86_64.old/strlen.o
140 0 0 140 8c x86_64/strpbrk.o
156 0 0 156 9c x86_64.old/strpbrk.o
135 0 0 135 87 x86_64/strspn.o
151 0 0 151 97 x86_64.old/strspn.o
Also, a few files got their .text alignment relaxed from 16 to 8 bytes,
which reduces padding at link time.
|
|
e.g. testb $0xff, %cl -> testb %cl, %cl
|
|
The attached patch adds support for compiling arm uClibc as pure Thumb code.
This is needed because some recent ARM codes do not implement traditional ARM
mode. Specifically:
* Cortex-M1 - An extremely minimal FPGA based core that only implements
Thumb-1 (aka ARMv6-M).
* Cortex-M3 - A Thumb-2 only ARMv7-M core.
Most of uClibc already builds in Thumb mode, all that is left are a handful of
assembly bits.
Tested on arm-uclinuxeabi.
|
|
Also, remove the hidden __memset symbol from memset.S
|
|
Found a problem with the AVR32 optimized bzero() code. Due to a
missing #include, it actually generated no code.
|