summaryrefslogtreecommitdiff
path: root/gcc/ipa-prop.c
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/ipa-prop.c')
-rw-r--r--gcc/ipa-prop.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/gcc/ipa-prop.c b/gcc/ipa-prop.c
index a3ab8b3b287..82a78a3b60e 100644
--- a/gcc/ipa-prop.c
+++ b/gcc/ipa-prop.c
@@ -199,7 +199,9 @@ visit_store_addr_for_mod_analysis (gimple stmt ATTRIBUTE_UNUSED,
{
struct ipa_node_params *info = (struct ipa_node_params *) data;
- if (TREE_CODE (op) == PARM_DECL)
+ op = get_base_address (op);
+ if (op
+ && TREE_CODE (op) == PARM_DECL)
{
int index = ipa_get_param_decl_index (info, op);
gcc_assert (index >= 0);