On Tue, Oct 15, 2024 at 4:07 AM Andrew Pinski <quic_apin...@quicinc.com> wrote:
>
> This FIXME:
>    FIXME: Aggressive mode before PRE doesn't work currently because
>           the dominance info is not invalidated after DCE1.
>
> Has not been true since at least r0-104723-g5ac60b564faa85 which
> added a call to calculate_dominance_info. Plus we run agressive mode
> before PRE since r0-89162-g11b08ee9118d10 too. And since 
> r0-95499-gb5b8b0ac643d31,
> dominance information was required even for non-agressive mode.
>
> Also we have been verifying dominance information is correct and not needing 
> to invalidate
> since ssa branch was merged so this comment has been out of date even before 
> it was merged in.

OK.

> gcc/ChangeLog:
>
>         * tree-ssa-dce.cc (perform_tree_ssa_dce): Remove FIXME note.
>
> Signed-off-by: Andrew Pinski <quic_apin...@quicinc.com>
> ---
>  gcc/tree-ssa-dce.cc | 8 +-------
>  1 file changed, 1 insertion(+), 7 deletions(-)
>
> diff --git a/gcc/tree-ssa-dce.cc b/gcc/tree-ssa-dce.cc
> index 3075459e25f..015c17984e1 100644
> --- a/gcc/tree-ssa-dce.cc
> +++ b/gcc/tree-ssa-dce.cc
> @@ -1965,13 +1965,7 @@ make_forwarders_with_degenerate_phis (function *fn)
>     In conservative mode, we ignore control dependence and simply declare
>     all but the most trivially dead branches necessary.  This mode is fast.
>     In aggressive mode, control dependences are taken into account, which
> -   results in more dead code elimination, but at the cost of some time.
> -
> -   FIXME: Aggressive mode before PRE doesn't work currently because
> -         the dominance info is not invalidated after DCE1.  This is
> -         not an issue right now because we only run aggressive DCE
> -         as the last tree SSA pass, but keep this in mind when you
> -         start experimenting with pass ordering.  */
> +   results in more dead code elimination, but at the cost of some time.  */
>
>  static unsigned int
>  perform_tree_ssa_dce (bool aggressive)
> --
> 2.43.0
>

Reply via email to