diff options
author | Martin Liska <mliska@suse.cz> | 2017-02-17 15:36:08 +0100 |
---|---|---|
committer | Martin Liska <marxin@gcc.gnu.org> | 2017-02-17 14:36:08 +0000 |
commit | c6b0d21d49a2605b2c667cec37b31140133b1fd5 (patch) | |
tree | 2d644d831748550bdfe21bd8444f49d2c62f5768 /gcc/tree-ssa-loop-unswitch.c | |
parent | 830afa4b0c8f2012b91c639f18a426d18aa36af2 (diff) | |
download | gcc-c6b0d21d49a2605b2c667cec37b31140133b1fd5.zip gcc-c6b0d21d49a2605b2c667cec37b31140133b1fd5.tar.gz gcc-c6b0d21d49a2605b2c667cec37b31140133b1fd5.tar.bz2 |
Introduce ssa_defined_default_def_p function (PR tree-optimization/79529).
2017-02-17 Martin Liska <mliska@suse.cz>
PR tree-optimization/79529
* tree-ssa-loop-unswitch.c (is_maybe_undefined): Use
ssa_defined_default_def_p to handle cases which are implicitly
defined.
* tree-ssa.c (ssa_defined_default_def_p): New function.
(ssa_undefined_value_p): Use ssa_defined_default_def_p to handle cases
which are implicitly defined.
* tree-ssa.h (ssa_defined_default_def_p): Declare.
From-SVN: r245530
Diffstat (limited to 'gcc/tree-ssa-loop-unswitch.c')
-rw-r--r-- | gcc/tree-ssa-loop-unswitch.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/gcc/tree-ssa-loop-unswitch.c b/gcc/tree-ssa-loop-unswitch.c index afa04e9..1845148 100644 --- a/gcc/tree-ssa-loop-unswitch.c +++ b/gcc/tree-ssa-loop-unswitch.c @@ -134,9 +134,7 @@ is_maybe_undefined (const tree name, gimple *stmt, struct loop *loop) if (ssa_undefined_value_p (t, true)) return true; - /* A PARM_DECL will not have an SSA_NAME_DEF_STMT. Parameters - get their initial value from function entry. */ - if (SSA_NAME_VAR (t) && TREE_CODE (SSA_NAME_VAR (t)) == PARM_DECL) + if (ssa_defined_default_def_p (t)) continue; gimple *def = SSA_NAME_DEF_STMT (t); |