Message ID | CAO2gOZVpKoZ3vZPAffWGBU4-d82TDLFLVMEaqgRY6hkDCUkqyg@mail.gmail.com |
---|---|
State | New |
Headers | show |
Index: gcc/ipa-prop.c =================================================================== --- gcc/ipa-prop.c (revision 193203) +++ gcc/ipa-prop.c (working copy) @@ -2870,7 +2870,8 @@ ipa_modify_call_arguments (struct cgraph_edge *cs, gcc_checking_assert (adj->offset % BITS_PER_UNIT == 0); base = gimple_call_arg (stmt, adj->base_index); - loc = EXPR_LOCATION (base); + loc = DECL_P (base) ? DECL_SOURCE_LOCATION (base) : + EXPR_LOCATION (base); if (TREE_CODE (base) != ADDR_EXPR && POINTER_TYPE_P (TREE_TYPE (base)))