From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from nikam.ms.mff.cuni.cz (nikam.ms.mff.cuni.cz [195.113.20.16]) by sourceware.org (Postfix) with ESMTPS id 12D913858287 for ; Fri, 14 Oct 2022 17:31:32 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 12D913858287 Authentication-Results: sourceware.org; dmarc=fail (p=none dis=none) header.from=ucw.cz Authentication-Results: sourceware.org; spf=none smtp.mailfrom=kam.mff.cuni.cz Received: by nikam.ms.mff.cuni.cz (Postfix, from userid 16202) id C06F72808A9; Fri, 14 Oct 2022 19:31:30 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ucw.cz; s=gen1; t=1665768690; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=zwbmBivGYPRloY+TIKRNgNQnoW7IeXfseIvtKeKXVl8=; b=rXMHS+ezRYjbcJ2dRTtnA2KCOeFW5kgfJNSQTvbpNMlqnNpa5+Q9AO2IeJlL1FSJqTwltQ pz3mUoM1ThxydO5ccunrh1TrHWJH5Vc7CuwLCOpBaxEL5pPYY0qJW15mxvapovmJU69/Wg 2a95me3vZWi782CJz2ZzVsiGz/ZrfIw= Date: Fri, 14 Oct 2022 19:31:30 +0200 From: Jan Hubicka To: Martin Jambor Cc: GCC Patches Subject: Re: [PATCH 2/2] ipa-cp: Better representation of aggregate values in call contexts Message-ID: References: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Spam-Status: No, score=-4.7 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,RCVD_IN_MSPIKE_H3,RCVD_IN_MSPIKE_WL,SPF_HELO_NONE,SPF_NONE,TXREP autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: > > 2022-08-26 Martin Jambor > > * ipa-prop.h (ipa_agg_value): Remove type. > (ipa_agg_value_set): Likewise. > (ipa_copy_agg_values): Remove function. > (ipa_release_agg_values): Likewise. > (ipa_auto_call_arg_values) Add a forward declaration. > (ipa_call_arg_values): Likewise. > (class ipa_argagg_value_list): New constructors, added member function > value_for_index_p. > (class ipa_auto_call_arg_values): Removed the destructor and member > function safe_aggval_at. Use ipa_argagg_values for m_known_aggs. > (class ipa_call_arg_values): Removed member function safe_aggval_at. > Use ipa_argagg_values for m_known_aggs. > (ipa_get_indirect_edge_target): Removed declaration. > (ipa_find_agg_cst_for_param): Likewise. > (ipa_find_agg_cst_from_init): New declaration. > (ipa_agg_value_from_jfunc): Likewise. > (ipa_agg_value_set_from_jfunc): Removed declaration. > (ipa_push_agg_values_from_jfunc): New declaration. > * ipa-cp.cc (ipa_agg_value_from_node): Renamed to > ipa_agg_value_from_jfunc, made public. > (ipa_agg_value_set_from_jfunc): Removed. > (ipa_push_agg_values_from_jfunc): New function. > (ipa_get_indirect_edge_target_1): Removed known_aggs parameter, use > avs for this purpose too. > (ipa_get_indirect_edge_target): Removed the overload working on > ipa_auto_call_arg_values, use ipa_argagg_value_list in the remaining > one. > (devirtualization_time_bonus): Use ipa_argagg_value_list and > ipa_get_indirect_edge_target_1 instead of > ipa_get_indirect_edge_target. > (context_independent_aggregate_values): Removed function. > (gather_context_independent_values): Work on ipa_argagg_value_list. > (estimate_local_effects): Likewise, define some iterator variables > only in the construct where necessary. > (ipcp_discover_new_direct_edges): Adjust the call to > ipa_get_indirect_edge_target_1. > (push_agg_values_for_index_from_edge): Adjust the call > ipa_agg_value_from_node which has been renamed to > ipa_agg_value_from_jfunc. > * ipa-fnsummary.cc (evaluate_conditions_for_known_args): Work on > ipa_argagg_value_list. > (evaluate_properties_for_edge): Replace manual filling in aggregate > values with call to ipa_push_agg_values_from_jfunc. > (estimate_calls_size_and_time): Work on ipa_argagg_value_list. > (ipa_cached_call_context::duplicate_from): Likewise. > (ipa_cached_call_context::release): Likewise. > (ipa_call_context::equal_to): Likewise. > * ipa-prop.cc (ipa_find_agg_cst_from_init): Make public. > (ipa_find_agg_cst_for_param): Removed function. > (ipa_find_agg_cst_from_jfunc_items): New function. > (try_make_edge_direct_simple_call): Replace calls to > ipa_agg_value_set_from_jfunc and ipa_find_agg_cst_for_param with > ipa_find_agg_cst_from_init and ipa_find_agg_cst_from_jfunc_items. > (try_make_edge_direct_virtual_call): Replace calls to > ipa_agg_value_set_from_jfunc and ipa_find_agg_cst_for_param with > simple query of constant jump function and a call to > ipa_find_agg_cst_from_jfunc_items. > (ipa_auto_call_arg_values::~ipa_auto_call_arg_values): Removed. OK, thanks! Honza