mirror of git://sourceware.org/git/glibc.git
x86: Use `testb` for case-locale check in str{n}casecmp-sse2
`testb` saves a bit of code size is the imm-operand can be encoded 1-bytes. Tested on x86-64.
This commit is contained in:
parent
b6d02d6457
commit
7775574ce0
|
|
@ -104,7 +104,7 @@ ENTRY (STRCMP)
|
|||
# else
|
||||
mov (%rdx), %RAX_LP
|
||||
# endif
|
||||
testl $1, LOCALE_DATA_VALUES+_NL_CTYPE_NONASCII_CASE*SIZEOF_VALUES(%rax)
|
||||
testb $1, LOCALE_DATA_VALUES+_NL_CTYPE_NONASCII_CASE*SIZEOF_VALUES(%rax)
|
||||
jne __strcasecmp_l_nonascii
|
||||
# elif defined USE_AS_STRNCASECMP_L
|
||||
/* We have to fall back on the C implementation for locales
|
||||
|
|
@ -114,7 +114,7 @@ ENTRY (STRCMP)
|
|||
# else
|
||||
mov (%rcx), %RAX_LP
|
||||
# endif
|
||||
testl $1, LOCALE_DATA_VALUES+_NL_CTYPE_NONASCII_CASE*SIZEOF_VALUES(%rax)
|
||||
testb $1, LOCALE_DATA_VALUES+_NL_CTYPE_NONASCII_CASE*SIZEOF_VALUES(%rax)
|
||||
jne __strncasecmp_l_nonascii
|
||||
# endif
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue