diff options
author | Richard Biener <rguenther@suse.de> | 2016-04-22 06:59:32 +0000 |
---|---|---|
committer | Richard Biener <rguenth@gcc.gnu.org> | 2016-04-22 06:59:32 +0000 |
commit | d14311920581dff3d36aba3e3aeb53f82213ef83 (patch) | |
tree | 3dbbdf8741398302abc4ad7ab86ec8c77a39c29d /gcc/tree-ssa-phiprop.c | |
parent | b8ce3fe29de6163328de75c3f733752c2391c093 (diff) | |
download | gcc-d14311920581dff3d36aba3e3aeb53f82213ef83.zip gcc-d14311920581dff3d36aba3e3aeb53f82213ef83.tar.gz gcc-d14311920581dff3d36aba3e3aeb53f82213ef83.tar.bz2 |
re PR tree-optimization/70740 (ICE when compiling the Linux kernel (net/wireless/util.o))
2016-04-22 Richard Biener <rguenther@suse.de>
PR tree-optimization/70740
* tree-ssa-phiprop.c (propagate_with_phi): Handle inserted
VDEF.
* gcc.dg/torture/pr70740.c: New testcase.
From-SVN: r235359
Diffstat (limited to 'gcc/tree-ssa-phiprop.c')
-rw-r--r-- | gcc/tree-ssa-phiprop.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/gcc/tree-ssa-phiprop.c b/gcc/tree-ssa-phiprop.c index 97e5663..80d2fc4 100644 --- a/gcc/tree-ssa-phiprop.c +++ b/gcc/tree-ssa-phiprop.c @@ -327,13 +327,15 @@ propagate_with_phi (basic_block bb, gphi *phi, struct phiprop_d *phivn, continue; /* Check if we can move the loads. The def stmt of the virtual use - needs to be in a different basic block dominating bb. */ + needs to be in a different basic block dominating bb. When the + def is an edge-inserted one we know it dominates us. */ vuse = gimple_vuse (use_stmt); def_stmt = SSA_NAME_DEF_STMT (vuse); if (!SSA_NAME_IS_DEFAULT_DEF (vuse) && (gimple_bb (def_stmt) == bb - || !dominated_by_p (CDI_DOMINATORS, - bb, gimple_bb (def_stmt)))) + || (gimple_bb (def_stmt) + && !dominated_by_p (CDI_DOMINATORS, + bb, gimple_bb (def_stmt))))) goto next; /* Found a proper dereference with an aggregate copy. Just |