mirror of
https://sourceware.org/git/glibc.git
synced 2024-11-08 14:20:07 +00:00
i386: Check PIC to enable PIC setups in multiarch functions
Check PIC, instead of SHARED, to enable PIC setups. * sysdeps/i386/i686/multiarch/memcmp-sse4.S: Check PIC instead of SHARED. * sysdeps/i386/i686/multiarch/memcpy-sse2-unaligned.S: Likewise. * sysdeps/i386/i686/multiarch/memcpy-ssse3-rep.S: Likewise. * sysdeps/i386/i686/multiarch/memcpy-ssse3.S: Likewise. * sysdeps/i386/i686/multiarch/memset-sse2-rep.S: Likewise. * sysdeps/i386/i686/multiarch/memset-sse2.S: Likewise. * sysdeps/i386/i686/multiarch/strcat-sse2.S: Likewise. * sysdeps/i386/i686/multiarch/strcpy-sse2.S: Likewise.
This commit is contained in:
parent
2fee621de0
commit
dfc93c41ee
12
ChangeLog
12
ChangeLog
@ -1,3 +1,15 @@
|
||||
2017-08-02 H.J. Lu <hongjiu.lu@intel.com>
|
||||
|
||||
* sysdeps/i386/i686/multiarch/memcmp-sse4.S: Check PIC instead
|
||||
of SHARED.
|
||||
* sysdeps/i386/i686/multiarch/memcpy-sse2-unaligned.S: Likewise.
|
||||
* sysdeps/i386/i686/multiarch/memcpy-ssse3-rep.S: Likewise.
|
||||
* sysdeps/i386/i686/multiarch/memcpy-ssse3.S: Likewise.
|
||||
* sysdeps/i386/i686/multiarch/memset-sse2-rep.S: Likewise.
|
||||
* sysdeps/i386/i686/multiarch/memset-sse2.S: Likewise.
|
||||
* sysdeps/i386/i686/multiarch/strcat-sse2.S: Likewise.
|
||||
* sysdeps/i386/i686/multiarch/strcpy-sse2.S: Likewise.
|
||||
|
||||
2017-08-02 Joseph Myers <joseph@codesourcery.com>
|
||||
|
||||
[BZ #21685]
|
||||
|
@ -43,7 +43,7 @@
|
||||
# define RETURN POP (%ebx); ret; CFI_PUSH (%ebx)
|
||||
|
||||
|
||||
# ifdef SHARED
|
||||
# ifdef PIC
|
||||
# define JMPTBL(I, B) I - B
|
||||
|
||||
/* Load an entry in a jump table into EBX and branch to it. TABLE is a
|
||||
|
@ -157,7 +157,7 @@ L(mm_len_128_or_more_backward):
|
||||
# ifdef SHARED_CACHE_SIZE_HALF
|
||||
cmp $SHARED_CACHE_SIZE_HALF, %edi
|
||||
# else
|
||||
# ifdef SHARED
|
||||
# ifdef PIC
|
||||
PUSH (%ebx)
|
||||
SETUP_PIC_REG (bx)
|
||||
add $_GLOBAL_OFFSET_TABLE_, %ebx
|
||||
@ -351,7 +351,7 @@ L(mm_len_128_or_more_forward):
|
||||
# ifdef SHARED_CACHE_SIZE_HALF
|
||||
cmp $SHARED_CACHE_SIZE_HALF, %edi
|
||||
# else
|
||||
# ifdef SHARED
|
||||
# ifdef PIC
|
||||
PUSH (%ebx)
|
||||
SETUP_PIC_REG(bx)
|
||||
add $_GLOBAL_OFFSET_TABLE_, %ebx
|
||||
@ -469,7 +469,7 @@ L(forward):
|
||||
# ifdef SHARED_CACHE_SIZE_HALF
|
||||
cmp $SHARED_CACHE_SIZE_HALF, %ecx
|
||||
# else
|
||||
# ifdef SHARED
|
||||
# ifdef PIC
|
||||
SETUP_PIC_REG(bx)
|
||||
add $_GLOBAL_OFFSET_TABLE_, %ebx
|
||||
cmp __x86_shared_cache_size_half@GOTOFF(%ebx), %ecx
|
||||
|
@ -52,7 +52,7 @@
|
||||
#define PUSH(REG) pushl REG; CFI_PUSH (REG)
|
||||
#define POP(REG) popl REG; CFI_POP (REG)
|
||||
|
||||
#ifdef SHARED
|
||||
#ifdef PIC
|
||||
# define PARMS 8 /* Preserve EBX. */
|
||||
# define ENTRANCE PUSH (%ebx);
|
||||
# define RETURN_END POP (%ebx); ret
|
||||
@ -160,7 +160,7 @@ L(48bytesormore):
|
||||
#ifdef SHARED_CACHE_SIZE_HALF
|
||||
cmp $SHARED_CACHE_SIZE_HALF, %ecx
|
||||
#else
|
||||
# ifdef SHARED
|
||||
# ifdef PIC
|
||||
SETUP_PIC_REG(bx)
|
||||
add $_GLOBAL_OFFSET_TABLE_, %ebx
|
||||
cmp __x86_shared_cache_size_half@GOTOFF(%ebx), %ecx
|
||||
@ -230,7 +230,7 @@ L(shl_0_gobble):
|
||||
#ifdef DATA_CACHE_SIZE_HALF
|
||||
cmp $DATA_CACHE_SIZE_HALF, %ecx
|
||||
#else
|
||||
# ifdef SHARED
|
||||
# ifdef PIC
|
||||
SETUP_PIC_REG(bx)
|
||||
add $_GLOBAL_OFFSET_TABLE_, %ebx
|
||||
mov __x86_data_cache_size_half@GOTOFF(%ebx), %edi
|
||||
|
@ -51,7 +51,7 @@
|
||||
# define PUSH(REG) pushl REG; CFI_PUSH (REG)
|
||||
# define POP(REG) popl REG; CFI_POP (REG)
|
||||
|
||||
# ifdef SHARED
|
||||
# ifdef PIC
|
||||
# define PARMS 8 /* Preserve EBX. */
|
||||
# define ENTRANCE PUSH (%ebx);
|
||||
# define RETURN_END POP (%ebx); ret
|
||||
@ -157,7 +157,7 @@ L(48bytesormore):
|
||||
# ifdef SHARED_CACHE_SIZE_HALF
|
||||
cmp $SHARED_CACHE_SIZE_HALF, %ecx
|
||||
# else
|
||||
# ifdef SHARED
|
||||
# ifdef PIC
|
||||
SETUP_PIC_REG(bx)
|
||||
add $_GLOBAL_OFFSET_TABLE_, %ebx
|
||||
cmp __x86_shared_cache_size_half@GOTOFF(%ebx), %ecx
|
||||
@ -231,7 +231,7 @@ L(shl_0_gobble):
|
||||
# ifdef DATA_CACHE_SIZE_HALF
|
||||
cmp $DATA_CACHE_SIZE_HALF, %ecx
|
||||
# else
|
||||
# ifdef SHARED
|
||||
# ifdef PIC
|
||||
SETUP_PIC_REG(bx)
|
||||
add $_GLOBAL_OFFSET_TABLE_, %ebx
|
||||
cmp __x86_data_cache_size_half@GOTOFF(%ebx), %ecx
|
||||
@ -390,7 +390,7 @@ L(shl_1):
|
||||
# ifdef DATA_CACHE_SIZE_HALF
|
||||
cmp $DATA_CACHE_SIZE_HALF, %ecx
|
||||
# else
|
||||
# ifdef SHARED
|
||||
# ifdef PIC
|
||||
SETUP_PIC_REG(bx)
|
||||
add $_GLOBAL_OFFSET_TABLE_, %ebx
|
||||
cmp __x86_data_cache_size_half@GOTOFF(%ebx), %ecx
|
||||
@ -494,7 +494,7 @@ L(shl_2):
|
||||
# ifdef DATA_CACHE_SIZE_HALF
|
||||
cmp $DATA_CACHE_SIZE_HALF, %ecx
|
||||
# else
|
||||
# ifdef SHARED
|
||||
# ifdef PIC
|
||||
SETUP_PIC_REG(bx)
|
||||
add $_GLOBAL_OFFSET_TABLE_, %ebx
|
||||
cmp __x86_data_cache_size_half@GOTOFF(%ebx), %ecx
|
||||
@ -598,7 +598,7 @@ L(shl_3):
|
||||
# ifdef DATA_CACHE_SIZE_HALF
|
||||
cmp $DATA_CACHE_SIZE_HALF, %ecx
|
||||
# else
|
||||
# ifdef SHARED
|
||||
# ifdef PIC
|
||||
SETUP_PIC_REG(bx)
|
||||
add $_GLOBAL_OFFSET_TABLE_, %ebx
|
||||
cmp __x86_data_cache_size_half@GOTOFF(%ebx), %ecx
|
||||
@ -704,7 +704,7 @@ L(shl_4):
|
||||
# ifdef DATA_CACHE_SIZE_HALF
|
||||
cmp $DATA_CACHE_SIZE_HALF, %ecx
|
||||
# else
|
||||
# ifdef SHARED
|
||||
# ifdef PIC
|
||||
SETUP_PIC_REG(bx)
|
||||
add $_GLOBAL_OFFSET_TABLE_, %ebx
|
||||
cmp __x86_data_cache_size_half@GOTOFF(%ebx), %ecx
|
||||
@ -810,7 +810,7 @@ L(shl_5):
|
||||
# ifdef DATA_CACHE_SIZE_HALF
|
||||
cmp $DATA_CACHE_SIZE_HALF, %ecx
|
||||
# else
|
||||
# ifdef SHARED
|
||||
# ifdef PIC
|
||||
SETUP_PIC_REG(bx)
|
||||
add $_GLOBAL_OFFSET_TABLE_, %ebx
|
||||
cmp __x86_data_cache_size_half@GOTOFF(%ebx), %ecx
|
||||
@ -916,7 +916,7 @@ L(shl_6):
|
||||
# ifdef DATA_CACHE_SIZE_HALF
|
||||
cmp $DATA_CACHE_SIZE_HALF, %ecx
|
||||
# else
|
||||
# ifdef SHARED
|
||||
# ifdef PIC
|
||||
SETUP_PIC_REG(bx)
|
||||
add $_GLOBAL_OFFSET_TABLE_, %ebx
|
||||
cmp __x86_data_cache_size_half@GOTOFF(%ebx), %ecx
|
||||
@ -1022,7 +1022,7 @@ L(shl_7):
|
||||
# ifdef DATA_CACHE_SIZE_HALF
|
||||
cmp $DATA_CACHE_SIZE_HALF, %ecx
|
||||
# else
|
||||
# ifdef SHARED
|
||||
# ifdef PIC
|
||||
SETUP_PIC_REG(bx)
|
||||
add $_GLOBAL_OFFSET_TABLE_, %ebx
|
||||
cmp __x86_data_cache_size_half@GOTOFF(%ebx), %ecx
|
||||
@ -1126,7 +1126,7 @@ L(shl_8):
|
||||
# ifdef DATA_CACHE_SIZE_HALF
|
||||
cmp $DATA_CACHE_SIZE_HALF, %ecx
|
||||
# else
|
||||
# ifdef SHARED
|
||||
# ifdef PIC
|
||||
SETUP_PIC_REG(bx)
|
||||
add $_GLOBAL_OFFSET_TABLE_, %ebx
|
||||
cmp __x86_data_cache_size_half@GOTOFF(%ebx), %ecx
|
||||
@ -1230,7 +1230,7 @@ L(shl_9):
|
||||
# ifdef DATA_CACHE_SIZE_HALF
|
||||
cmp $DATA_CACHE_SIZE_HALF, %ecx
|
||||
# else
|
||||
# ifdef SHARED
|
||||
# ifdef PIC
|
||||
SETUP_PIC_REG(bx)
|
||||
add $_GLOBAL_OFFSET_TABLE_, %ebx
|
||||
cmp __x86_data_cache_size_half@GOTOFF(%ebx), %ecx
|
||||
@ -1335,7 +1335,7 @@ L(shl_10):
|
||||
# ifdef DATA_CACHE_SIZE_HALF
|
||||
cmp $DATA_CACHE_SIZE_HALF, %ecx
|
||||
# else
|
||||
# ifdef SHARED
|
||||
# ifdef PIC
|
||||
SETUP_PIC_REG(bx)
|
||||
add $_GLOBAL_OFFSET_TABLE_, %ebx
|
||||
cmp __x86_data_cache_size_half@GOTOFF(%ebx), %ecx
|
||||
@ -1440,7 +1440,7 @@ L(shl_11):
|
||||
# ifdef DATA_CACHE_SIZE_HALF
|
||||
cmp $DATA_CACHE_SIZE_HALF, %ecx
|
||||
# else
|
||||
# ifdef SHARED
|
||||
# ifdef PIC
|
||||
SETUP_PIC_REG(bx)
|
||||
add $_GLOBAL_OFFSET_TABLE_, %ebx
|
||||
cmp __x86_data_cache_size_half@GOTOFF(%ebx), %ecx
|
||||
@ -1545,7 +1545,7 @@ L(shl_12):
|
||||
# ifdef DATA_CACHE_SIZE_HALF
|
||||
cmp $DATA_CACHE_SIZE_HALF, %ecx
|
||||
# else
|
||||
# ifdef SHARED
|
||||
# ifdef PIC
|
||||
SETUP_PIC_REG(bx)
|
||||
add $_GLOBAL_OFFSET_TABLE_, %ebx
|
||||
cmp __x86_data_cache_size_half@GOTOFF(%ebx), %ecx
|
||||
@ -1650,7 +1650,7 @@ L(shl_13):
|
||||
# ifdef DATA_CACHE_SIZE_HALF
|
||||
cmp $DATA_CACHE_SIZE_HALF, %ecx
|
||||
# else
|
||||
# ifdef SHARED
|
||||
# ifdef PIC
|
||||
SETUP_PIC_REG(bx)
|
||||
add $_GLOBAL_OFFSET_TABLE_, %ebx
|
||||
cmp __x86_data_cache_size_half@GOTOFF(%ebx), %ecx
|
||||
@ -1755,7 +1755,7 @@ L(shl_14):
|
||||
# ifdef DATA_CACHE_SIZE_HALF
|
||||
cmp $DATA_CACHE_SIZE_HALF, %ecx
|
||||
# else
|
||||
# ifdef SHARED
|
||||
# ifdef PIC
|
||||
SETUP_PIC_REG(bx)
|
||||
add $_GLOBAL_OFFSET_TABLE_, %ebx
|
||||
cmp __x86_data_cache_size_half@GOTOFF(%ebx), %ecx
|
||||
@ -1860,7 +1860,7 @@ L(shl_15):
|
||||
# ifdef DATA_CACHE_SIZE_HALF
|
||||
cmp $DATA_CACHE_SIZE_HALF, %ecx
|
||||
# else
|
||||
# ifdef SHARED
|
||||
# ifdef PIC
|
||||
SETUP_PIC_REG(bx)
|
||||
add $_GLOBAL_OFFSET_TABLE_, %ebx
|
||||
cmp __x86_data_cache_size_half@GOTOFF(%ebx), %ecx
|
||||
|
@ -44,7 +44,7 @@
|
||||
# define SETRTNVAL movl DEST(%esp), %eax
|
||||
#endif
|
||||
|
||||
#ifdef SHARED
|
||||
#ifdef PIC
|
||||
# define ENTRANCE PUSH (%ebx);
|
||||
# define RETURN_END POP (%ebx); ret
|
||||
# define RETURN RETURN_END; CFI_PUSH (%ebx)
|
||||
@ -262,7 +262,7 @@ L(128bytesormore):
|
||||
PUSH (%ebx)
|
||||
mov $DATA_CACHE_SIZE, %ebx
|
||||
#else
|
||||
# ifdef SHARED
|
||||
# ifdef PIC
|
||||
SETUP_PIC_REG(bx)
|
||||
add $_GLOBAL_OFFSET_TABLE_, %ebx
|
||||
mov __x86_data_cache_size@GOTOFF(%ebx), %ebx
|
||||
@ -274,7 +274,7 @@ L(128bytesormore):
|
||||
mov %ebx, %edi
|
||||
shr $4, %ebx
|
||||
sub %ebx, %edi
|
||||
#if defined DATA_CACHE_SIZE || !defined SHARED
|
||||
#if defined DATA_CACHE_SIZE || !defined PIC
|
||||
POP (%ebx)
|
||||
#endif
|
||||
/*
|
||||
|
@ -44,7 +44,7 @@
|
||||
# define SETRTNVAL movl DEST(%esp), %eax
|
||||
#endif
|
||||
|
||||
#ifdef SHARED
|
||||
#ifdef PIC
|
||||
# define ENTRANCE PUSH (%ebx);
|
||||
# define RETURN_END POP (%ebx); ret
|
||||
# define RETURN RETURN_END; CFI_PUSH (%ebx)
|
||||
@ -261,7 +261,7 @@ L(128bytesormore):
|
||||
PUSH (%ebx)
|
||||
mov $SHARED_CACHE_SIZE, %ebx
|
||||
#else
|
||||
# ifdef SHARED
|
||||
# ifdef PIC
|
||||
SETUP_PIC_REG(bx)
|
||||
add $_GLOBAL_OFFSET_TABLE_, %ebx
|
||||
mov __x86_shared_cache_size@GOTOFF(%ebx), %ebx
|
||||
@ -279,7 +279,7 @@ L(128bytesormore):
|
||||
# define RESTORE_EBX_STATE CFI_PUSH (%ebx)
|
||||
cmp $DATA_CACHE_SIZE, %ecx
|
||||
#else
|
||||
# ifdef SHARED
|
||||
# ifdef PIC
|
||||
# define RESTORE_EBX_STATE
|
||||
SETUP_PIC_REG(bx)
|
||||
add $_GLOBAL_OFFSET_TABLE_, %ebx
|
||||
@ -380,7 +380,7 @@ L(128bytesormore_nt):
|
||||
jae L(128bytesormore_nt)
|
||||
sfence
|
||||
L(shared_cache_loop_end):
|
||||
#if defined DATA_CACHE_SIZE || !defined SHARED
|
||||
#if defined DATA_CACHE_SIZE || !defined PIC
|
||||
POP (%ebx)
|
||||
#endif
|
||||
BRANCH_TO_JMPTBL_ENTRY (L(table_16_128bytes))
|
||||
|
@ -34,7 +34,7 @@
|
||||
# define PUSH(REG) pushl REG; CFI_PUSH (REG)
|
||||
# define POP(REG) popl REG; CFI_POP (REG)
|
||||
|
||||
# ifdef SHARED
|
||||
# ifdef PIC
|
||||
# define JMPTBL(I, B) I - B
|
||||
|
||||
/* Load an entry in a jump table into ECX and branch to it. TABLE is a
|
||||
|
@ -48,7 +48,7 @@
|
||||
# define RETURN POP(%edi); POP(%esi); POP(%ebx); ret; \
|
||||
CFI_PUSH(%ebx); CFI_PUSH(%esi); CFI_PUSH(%edi);
|
||||
|
||||
# ifdef SHARED
|
||||
# ifdef PIC
|
||||
# define JMPTBL(I, B) I - B
|
||||
|
||||
/* Load an entry in a jump table into ECX and branch to it. TABLE is a
|
||||
|
Loading…
Reference in New Issue
Block a user