2016-05-18 Martin Jambor <mjambor@suse.cz>
PR ipa/69708
* ipa-prop.c (parm_preserved_before_stmt_p): Return true for loads
from TREE_READONLY parameters.
From-SVN: r236417
+2016-05-18 Martin Jambor <mjambor@suse.cz>
+
+ PR ipa/69708
+ * ipa-prop.c (parm_preserved_before_stmt_p): Return true for loads
+ from TREE_READONLY parameters.
+
2016-05-18 Martin Jambor <mjambor@suse.cz>
PR ipa/69708
bool modified = false;
ao_ref refd;
+ tree base = get_base_address (parm_load);
+ gcc_assert (TREE_CODE (base) == PARM_DECL);
+ if (TREE_READONLY (base))
+ return true;
+
/* FIXME: FBI can be NULL if we are being called from outside
ipa_node_analysis or ipcp_transform_function, which currently happens
during inlining analysis. It would be great to extend fbi's lifetime and