From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 16439 invoked by alias); 31 Aug 2013 19:52:23 -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 16428 invoked by uid 89); 31 Aug 2013 19:52:23 -0000 Received: from mail-we0-f180.google.com (HELO mail-we0-f180.google.com) (74.125.82.180) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES128-SHA encrypted) ESMTPS; Sat, 31 Aug 2013 19:52:23 +0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-4.4 required=5.0 tests=ALL_TRUSTED,BAYES_00,FREEMAIL_FROM,KHOP_THREADED autolearn=ham version=3.3.2 X-HELO: mail-we0-f180.google.com Received: by mail-we0-f180.google.com with SMTP id q58so2642793wes.11 for ; Sat, 31 Aug 2013 12:52:19 -0700 (PDT) X-Received: by 10.180.229.103 with SMTP id sp7mr2615848wic.2.1377978739380; Sat, 31 Aug 2013 12:52:19 -0700 (PDT) Received: from [90.152.237.237] (090152237237.atmpu0036.highway.a1.net. [90.152.237.237]) by mx.google.com with ESMTPSA id u8sm6611665wiz.2.1969.12.31.16.00.00 (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Sat, 31 Aug 2013 12:52:18 -0700 (PDT) From: "Bernhard Reutner-Fischer" To: Richard Biener , Jan Hubicka , Date: Sat, 31 Aug 2013 20:15:00 -0000 Message-ID: <140d5f29327.2760.0f39ed3bcad52ef2c88c90062b7714dc@gmail.com> In-Reply-To: <301dcb70-d7b5-4ad1-89fe-a20d5a78fba7@email.android.com> References: <20130831162022.GB22772@kam.mff.cuni.cz> <301dcb70-d7b5-4ad1-89fe-a20d5a78fba7@email.android.com> User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:9.0) Gecko/20111222 Thunderbird/9.0.1 AquaMail/1.2.4.0 (build: 2100294) Subject: Re: Remove hash from remember_with_vars MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii"; format=flowed Content-Transfer-Encoding: 8bit X-IsSubscribed: yes X-SW-Source: 2013-08/txt/msg01970.txt.bz2 On 31 August 2013 19:15:46 Richard Biener wrote: > Jan Hubicka wrote: > >Hi, > >remember_with_vars walks trees that are read from file (now unique) > >and looks for fields that can contain pointers to vars or functions and > >if so, it records them to global hashtable for later fixup. > >This is quite wasteful, because the hash is querried many times. > >We can simply walk all fields in a tree and record the tree once > >afterwards, > >moreover since streaming knows when tree is newly constructed, we don't > >need > >hash. > > > >Vectors do not allow deletable elements, but I think it makes no > >difference: > >the trees are all used from decl states. > > Heh, indeed a cleanup possibility I missed. > > Ok. s/Trun/Turn/g ? Thanks > Thanks, > Richard. > > > * lot.c (tree_with_vars): Turn into vector. > > (MAYBE_REMEMBER_WITH_VARS): Change to... > > (CHECK_VAR): ... this one. > > (CHECK_NO_VAR): New macro. > > (maybe_remember_with_vars_typed): Trun to ... > > (mentions_vars_p_typed): ... this one. > > (maybe_remember_with_vars_common): Trun to ... > > (mentions_vars_p_comon): ... this one. > > (maybe_remember_with_vars_decl_minimal): Trun to ... > > (mentions_vars_p_decl_minmal): ... this one. > > (maybe_remember_with_vars_decl_common): Trun to ... > > (mentions_vars_p_decl_common): ... this one. > > (maybe_remember_with_vars_decl_with_vis): Trun to ... > > (mentions_vars_p_decl_with_vis): ... this one. > > (maybe_remember_with_vars_decl_non_common): Trun to ... > > (mentions_vars_p_decl_non_common): ... this one. > > (maybe_remember_with_vars_function): Trun to ... > > (mentions_vars_p_function): ... this one. > > (maybe_remember_with_vars_field_decl): Trun to ... > > (mentions_vars_p_field_decl): ... this one. > > (maybe_remember_with_vars_type): Trun to ... > > (mentions_vars_p_type): ... this one. > > (maybe_remember_with_vars_binfo): Trun to ... > > (mentions_vars_p_binfo): ... this one. > > (maybe_remember_with_vars_constructor): Trun to ... > > (mentions_vars_p_constructor): ... this one. > > (maybe_remember_with_vars_expr): Trun to ... > > (mentions_vars_p_expr): ... this one. > > (maybe_remember_with_vars): Trun to ... > > (mentions_vars_p): ... this one. > > (lto_read_decls): Update. > > (LTO_SET_PREVAIL): Do not call function for internal decls. > > (lto_fixup_prevailing_decls): Update to match mentions_vars_p; > > check that something was updated. > > (lto_fixup_state): Do not care about internal decls. > > (lto_fixup_decls): Update. > > (read_cgraph_and_symbols): Update. Sent with AquaMail for Android http://www.aqua-mail.com