From: Jan Hubicka Date: Wed, 21 Apr 2010 14:41:50 +0000 (+0200) Subject: * ipa-prop.c (ipa_edge_removal_hook): Check for bounds. X-Git-Tag: releases/gcc-4.6.0~7736 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=dd6d1ad715541f538a82090a8480412dde0169db;p=thirdparty%2Fgcc.git * ipa-prop.c (ipa_edge_removal_hook): Check for bounds. From-SVN: r158610 --- diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 13ac23956aaa..277e34873aa3 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,7 @@ +2010-04-21 Jan Hubicka + + * ipa-prop.c (ipa_edge_removal_hook): Check for bounds. + 2010-04-21 Jan Hubicka * varpool.c (decide_is_variable_needed): Variable is always needed diff --git a/gcc/ipa-prop.c b/gcc/ipa-prop.c index ec9f63d89a7b..af00175124d0 100644 --- a/gcc/ipa-prop.c +++ b/gcc/ipa-prop.c @@ -1260,6 +1260,10 @@ ipa_edge_removal_hook (struct cgraph_edge *cs, void *data ATTRIBUTE_UNUSED) static void ipa_node_removal_hook (struct cgraph_node *node, void *data ATTRIBUTE_UNUSED) { + /* During IPA-CP updating we can be called on not-yet analyze clones. */ + if (VEC_length (ipa_node_params_t, ipa_node_params_vector) + <= (unsigned)node->uid) + return; ipa_free_node_params_substructures (IPA_NODE_REF (node)); }