From e0702244b8e0fa5555e20b5554545bab9d06927f Mon Sep 17 00:00:00 2001 From: Richard Sandiford Date: Thu, 25 Jun 2015 17:16:44 +0000 Subject: gengtype-parse.c (require_template_declaration): Allow '+' in template parameters. gcc/ * gengtype-parse.c (require_template_declaration): Allow '+' in template parameters. Consolidate cases. * hash-traits.h (int_hash): New class. * alias.c (alias_set_hash): New structure. (alias_set_traits): Use it. * symbol-summary.h (function_summary::map_hash): New class. (function_summary::summary_hashmap_traits): Use it. * tree-inline.h (dependence_hash): New class. (dependence_hasher): Use it. * tree-ssa-reassoc.c (oecount_hasher): Use int_hash. * value-prof.c (profile_id_hash): New class. (profile_id_traits): Use it. From-SVN: r224973 --- gcc/value-prof.c | 15 ++------------- 1 file changed, 2 insertions(+), 13 deletions(-) (limited to 'gcc/value-prof.c') diff --git a/gcc/value-prof.c b/gcc/value-prof.c index 74f5375..a84b8da 100644 --- a/gcc/value-prof.c +++ b/gcc/value-prof.c @@ -1248,19 +1248,8 @@ gimple_mod_subtract_transform (gimple_stmt_iterator *si) return true; } -struct profile_id_traits : default_hashmap_traits -{ - template - static bool - is_deleted (T &e) - { - return e.m_key == UINT_MAX; - } - - template static bool is_empty (T &e) { return e.m_key == 0; } - template static void mark_deleted (T &e) { e.m_key = UINT_MAX; } - template static void mark_empty (T &e) { e.m_key = 0; } -}; +typedef int_hash profile_id_hash; +typedef simple_hashmap_traits profile_id_traits; static hash_map * cgraph_node_map = 0; -- cgit v1.1