diff options
-rw-r--r-- | elf/dl-cache.c | 22 |
1 files changed, 3 insertions, 19 deletions
diff --git a/elf/dl-cache.c b/elf/dl-cache.c index 85f3f179ed..7c7dc58745 100644 --- a/elf/dl-cache.c +++ b/elf/dl-cache.c @@ -27,10 +27,6 @@ #include <dl-hwcaps.h> #include <dl-isa-level.h> -#ifndef _DL_PLATFORMS_COUNT -# define _DL_PLATFORMS_COUNT 0 -#endif - /* This is the starting address and the size of the mmap()ed file. */ static struct cache_file *cache; static struct cache_file_new *cache_new; @@ -201,15 +197,6 @@ search_cache (const char *string_table, uint32_t string_table_size, struct file_entry *libs, uint32_t nlibs, uint32_t entry_size, const char *name) { - /* Used by the HWCAP check in the struct file_entry_new case. */ - uint64_t platform = _dl_string_platform (GLRO (dl_platform)); - if (platform != (uint64_t) -1) - platform = 1ULL << platform; - uint64_t hwcap_mask = TUNABLE_GET (glibc, cpu, hwcap_mask, uint64_t, NULL); -#define _DL_HWCAP_TLS_MASK (1LL << 63) - uint64_t hwcap_exclude = ~((GLRO (dl_hwcap) & hwcap_mask) - | _DL_HWCAP_PLATFORM | _DL_HWCAP_TLS_MASK); - int left = 0; int right = nlibs - 1; const char *best = NULL; @@ -295,12 +282,9 @@ search_cache (const char *string_table, uint32_t string_table_size, if (!named_hwcap && best != NULL) break; - if ((libnew->hwcap & hwcap_exclude) && !named_hwcap) - continue; - if (_DL_PLATFORMS_COUNT - && (libnew->hwcap & _DL_HWCAP_PLATFORM) != 0 - && ((libnew->hwcap & _DL_HWCAP_PLATFORM) - != platform)) + /* Skip entries with the legacy hwcap/platform mechanism + which was removed with glibc 2.37. */ + if (!named_hwcap && libnew->hwcap != 0) continue; #ifdef SHARED |