Commit 34a108c8 by Aldy Hernandez Committed by Aldy Hernandez

re PR middle-end/65233 (ICE (segfault) on arm-linux-gnueabihf and aarch64-linux-gnu)

	PR middle-end/65233
	* ipa-polymorphic-call.c (walk_ssa_copies): Handle empty PHIs.

From-SVN: r221097
parent 46305737
2015-03-01 Aldy Hernandez <aldyh@redhat.com>
PR middle-end/65233
* ipa-polymorphic-call.c (walk_ssa_copies): Handle empty PHIs.
2015-02-28 Jan Hubicka <hubicka@ucw.cz> 2015-02-28 Jan Hubicka <hubicka@ucw.cz>
* ipa-icf.c: Include stor-layout.h * ipa-icf.c: Include stor-layout.h
......
...@@ -835,7 +835,10 @@ walk_ssa_copies (tree op, hash_set<tree> **global_visited = NULL) ...@@ -835,7 +835,10 @@ walk_ssa_copies (tree op, hash_set<tree> **global_visited = NULL)
{ {
gimple phi = SSA_NAME_DEF_STMT (op); gimple phi = SSA_NAME_DEF_STMT (op);
if (gimple_phi_num_args (phi) > 2) if (gimple_phi_num_args (phi) > 2
/* We can be called while cleaning up the CFG and can
have empty PHIs about to be removed. */
|| gimple_phi_num_args (phi) == 0)
goto done; goto done;
if (gimple_phi_num_args (phi) == 1) if (gimple_phi_num_args (phi) == 1)
op = gimple_phi_arg_def (phi, 0); op = gimple_phi_arg_def (phi, 0);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment