summaryrefslogtreecommitdiff
path: root/gcc/config/i386
diff options
context:
space:
mode:
authorrsandifo <rsandifo@138bc75d-0d04-0410-961f-82ee72b054a4>2015-06-25 17:16:23 +0000
committerrsandifo <rsandifo@138bc75d-0d04-0410-961f-82ee72b054a4>2015-06-25 17:16:23 +0000
commitcbfc4bfa9965a87780a24f47a72e9849180ab043 (patch)
treeef11c0ce585dd35735de0a607dd716f3fa308d6e /gcc/config/i386
parent22fd03a551df35a59ba22f3f68464a7b25379c32 (diff)
downloadgcc-cbfc4bfa9965a87780a24f47a72e9849180ab043.tar.gz
gcc/
* hash-traits.h (string_hash, nofree_string_hash): New classes. * genmatch.c (capture_id_map_hasher): Use nofree_string_hash. * passes.c (pass_registry_hasher): Likewise. * config/alpha/alpha.c (string_traits): Likewise. * config/i386/winnt.c (i386_find_on_wrapper_list): Likewise. * config/m32c/m32c.c (pragma_traits): Likewise. * config/mep/mep.c (pragma_traits): Likewise. gcc/java/ * jcf-io.c (memoized_class_lookups): Use nofree_string_hash. (find_class): Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@224971 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/config/i386')
-rw-r--r--gcc/config/i386/winnt.c27
1 files changed, 2 insertions, 25 deletions
diff --git a/gcc/config/i386/winnt.c b/gcc/config/i386/winnt.c
index 47ea87a3113..a30215bcd4b 100644
--- a/gcc/config/i386/winnt.c
+++ b/gcc/config/i386/winnt.c
@@ -707,29 +707,6 @@ i386_pe_record_stub (const char *name)
#ifdef CXX_WRAP_SPEC_LIST
-/* Hashtable helpers. */
-
-struct wrapped_symbol_hasher : nofree_ptr_hash <const char>
-{
- static inline hashval_t hash (const char *);
- static inline bool equal (const char *, const char *);
- static inline void remove (const char *);
-};
-
-inline hashval_t
-wrapped_symbol_hasher::hash (const char *v)
-{
- return htab_hash_string (v);
-}
-
-/* Hash table equality helper function. */
-
-inline bool
-wrapped_symbol_hasher::equal (const char *x, const char *y)
-{
- return !strcmp (x, y);
-}
-
/* Search for a function named TARGET in the list of library wrappers
we are using, returning a pointer to it if found or NULL if not.
This function might be called on quite a few symbols, and we only
@@ -741,7 +718,7 @@ static const char *
i386_find_on_wrapper_list (const char *target)
{
static char first_time = 1;
- static hash_table<wrapped_symbol_hasher> *wrappers;
+ static hash_table<nofree_string_hash> *wrappers;
if (first_time)
{
@@ -754,7 +731,7 @@ i386_find_on_wrapper_list (const char *target)
char *bufptr;
/* Breaks up the char array into separated strings
strings and enter them into the hash table. */
- wrappers = new hash_table<wrapped_symbol_hasher> (8);
+ wrappers = new hash_table<nofree_string_hash> (8);
for (bufptr = wrapper_list_buffer; *bufptr; ++bufptr)
{
char *found = NULL;