From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 8175 invoked by alias); 24 Nov 2015 08:34:42 -0000 Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Received: (qmail 8147 invoked by uid 89); 24 Nov 2015 08:34:41 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.3 required=5.0 tests=AWL,BAYES_50,RCVD_IN_DNSWL_LOW,RP_MATCHES_RCVD,SPF_PASS autolearn=ham version=3.3.2 X-HELO: mx2.suse.de Received: from mx2.suse.de (HELO mx2.suse.de) (195.135.220.15) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (CAMELLIA256-SHA encrypted) ESMTPS; Tue, 24 Nov 2015 08:34:40 +0000 Received: from relay1.suse.de (charybdis-ext.suse.de [195.135.220.254]) by mx2.suse.de (Postfix) with ESMTP id 36836AB13; Tue, 24 Nov 2015 08:33:16 +0000 (UTC) Date: Tue, 24 Nov 2015 08:36:00 -0000 From: Richard Biener To: tbsaunde+gcc@tbsaunde.org cc: gcc-patches@gcc.gnu.org Subject: Re: [PATCH 2/2] remove val_ssa_equiv_hash_traits In-Reply-To: <1448318933-23235-2-git-send-email-tbsaunde+gcc@tbsaunde.org> Message-ID: References: <1448318933-23235-1-git-send-email-tbsaunde+gcc@tbsaunde.org> <1448318933-23235-2-git-send-email-tbsaunde+gcc@tbsaunde.org> User-Agent: Alpine 2.11 (LSU 23 2013-08-11) MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-SW-Source: 2015-11/txt/msg02835.txt.bz2 On Mon, 23 Nov 2015, tbsaunde+gcc@tbsaunde.org wrote: > From: Trevor Saunders > > Hi, > > this is pretty trivial cleanup after the previous patch, but could wait for > next stage 1 if people don't like the very small risk. > > boostrappped + regtested on x86_64-linux-gnu, ok? Ok. Thanks, RIchard. > Trev > > gcc/ChangeLog: > > 2015-11-20 Trevor Saunders > > * tree-ssa-uncprop.c (struct val_ssa_equiv_hash_traits): Remove. > (val_ssa_equiv_hash_traits::remove): Likewise. > (pass_uncprop::execute): Adjust. > --- > gcc/tree-ssa-uncprop.c | 22 ++-------------------- > 1 file changed, 2 insertions(+), 20 deletions(-) > > diff --git a/gcc/tree-ssa-uncprop.c b/gcc/tree-ssa-uncprop.c > index 23b4ca2..a60184e 100644 > --- a/gcc/tree-ssa-uncprop.c > +++ b/gcc/tree-ssa-uncprop.c > @@ -275,27 +275,10 @@ struct equiv_hash_elt > vec equivalences; > }; > > -/* Value to ssa name equivalence hashtable helpers. */ > - > -struct val_ssa_equiv_hash_traits : simple_hashmap_traits - vec > > -{ > - template static inline void remove (T &); > -}; > - > -/* Free an instance of equiv_hash_elt. */ > - > -template > -inline void > -val_ssa_equiv_hash_traits::remove (T &elt) > -{ > - elt.m_value.release (); > -} > - > /* Global hash table implementing a mapping from invariant values > to a list of SSA_NAMEs which have the same value. We might be > able to reuse tree-vn for this code. */ > -static hash_map, val_ssa_equiv_hash_traits> *val_ssa_equiv; > +static hash_map > *val_ssa_equiv; > > static void uncprop_into_successor_phis (basic_block); > > @@ -518,8 +501,7 @@ pass_uncprop::execute (function *fun) > associate_equivalences_with_edges (); > > /* Create our global data structures. */ > - val_ssa_equiv > - = new hash_map, val_ssa_equiv_hash_traits> (1024); > + val_ssa_equiv = new hash_map > (1024); > > /* We're going to do a dominator walk, so ensure that we have > dominance information. */ > -- Richard Biener SUSE LINUX GmbH, GF: Felix Imendoerffer, Jane Smithard, Graham Norton, HRB 21284 (AG Nuernberg)