diff options
author | H.J. Lu <hjl.tools@gmail.com> | 2017-05-26 06:50:44 -0700 |
---|---|---|
committer | H.J. Lu <hjl.tools@gmail.com> | 2017-05-26 06:50:44 -0700 |
commit | 8d9032687a8943f494dec5421ba746f4ffc321e9 (patch) | |
tree | e8258069e6064629d406be84631132aa6ed92929 /sysdeps/x86_64/multiarch/wcsrchr-old-2.S | |
parent | 0053a98eb7a7e25eaa230acbda01840b2762143b (diff) | |
download | glibc-8d9032687a8943f494dec5421ba746f4ffc321e9.tar.gz |
bad wcsrchr-old-2.Shjl/wcsrchr/sse2
Diffstat (limited to 'sysdeps/x86_64/multiarch/wcsrchr-old-2.S')
-rw-r--r-- | sysdeps/x86_64/multiarch/wcsrchr-old-2.S | 26 |
1 files changed, 10 insertions, 16 deletions
diff --git a/sysdeps/x86_64/multiarch/wcsrchr-old-2.S b/sysdeps/x86_64/multiarch/wcsrchr-old-2.S index 8f42d4fd50..33f7c56425 100644 --- a/sysdeps/x86_64/multiarch/wcsrchr-old-2.S +++ b/sysdeps/x86_64/multiarch/wcsrchr-old-2.S @@ -138,8 +138,8 @@ L(return_value): mov %r8d, %eax mov %rsi, %rdi - andl $0x11111111, %eax - bsrl %eax, %eax + and $0x11111111, %eax + bsr %eax, %eax lea -16(%rdi, %rax), %rax ret @@ -164,8 +164,8 @@ L(find_zero): and $1 << 13 - 1, %eax jz L(return_value) - andl $0x11111111, %eax - bsrl %eax, %eax + and $0x11111111, %eax + bsr %eax, %eax lea -16(%rdi, %rax), %rax ret @@ -203,18 +203,12 @@ L(prolog_find_zero): add %rcx, %rdi mov %edx, %ecx L(prolog_find_zero_1): - test $15, %cl - jnz L(prolog_find_zero_in_first_wchar) - test %cl, %cl - jnz L(prolog_find_zero_in_second_wchar) - test $15, %ch - jnz L(prolog_find_zero_in_third_wchar) - - and $1 << 13 - 1, %eax - jz L(return_null) - - andl $0x11111111, %eax - bsrl %eax, %eax + and $0x11111111, %ecx + and $0x11111111, %eax + bsf %ecx, %ecx + bsr %eax, %eax + cmp %eax, %ecx + jl L(return_null) lea -16(%rdi, %rax), %rax ret |