On Thu, 17 Feb 2022, Jan Hubicka wrote:
> > +/* Returns whether the control parents of BB are preserved. */
> > +
> > +static bool
> > +control_parents_preserved_p (basic_block bb)
> > +{
> > + /* If we marked the control parents from BB they are preserved. */
> > + if (bitmap_bit_p (visited_c
> +/* Returns whether the control parents of BB are preserved. */
> +
> +static bool
> +control_parents_preserved_p (basic_block bb)
> +{
> + /* If we marked the control parents from BB they are preserved. */
> + if (bitmap_bit_p (visited_control_parents, bb->index))
> +return true;
> +
> +
CD-DCE does not consider CLOBBERs as necessary in the attempt
to not prevent DCE of SSA defs it uses. A side-effect of that
is that it also removes all its control dependences if they are
not made necessary by other means. When we later try to preserve
as many CLOBBERs as possible we have to make
On Thu, 17 Feb 2022, Richard Biener wrote:
> On Tue, 15 Feb 2022, Jan Hubicka wrote:
>
> > > @@ -1272,7 +1275,7 @@ maybe_optimize_arith_overflow (gimple_stmt_iterator
> > > *gsi,
> > > contributes nothing to the program, and can be deleted. */
> > >
> > > static bool
> > > -eliminate_unn
On Tue, 15 Feb 2022, Jan Hubicka wrote:
> > @@ -1272,7 +1275,7 @@ maybe_optimize_arith_overflow (gimple_stmt_iterator
> > *gsi,
> > contributes nothing to the program, and can be deleted. */
> >
> > static bool
> > -eliminate_unnecessary_stmts (void)
> > +eliminate_unnecessary_stmts (bool
> @@ -1272,7 +1275,7 @@ maybe_optimize_arith_overflow (gimple_stmt_iterator
> *gsi,
> contributes nothing to the program, and can be deleted. */
>
> static bool
> -eliminate_unnecessary_stmts (void)
> +eliminate_unnecessary_stmts (bool aggressive)
> {
>bool something_changed = false;
CD-DCE does not consider CLOBBERs as necessary in the attempt
to not prevent DCE of SSA defs it uses. A side-effect of that
is that it also removes all its control dependences if they are
not made necessary by other means. When we later try to preserve
as many CLOBBERs as possible we have to make