On Tue, May 10, 2016 at 9:19 AM, Ilya Enkovich <enkovich....@gmail.com> wrote:
> Hi,
>
> Curretly CSE may modify CFG and leave invalid dominance info.  This patch
> improves track of CFG changes by CSE passes and frees dominance info if
> required.  This allows to remove corresponding workaround from STV pass.
>
> Does it look OK?
>
> Bootstrapped and regtested on x86-64-unknown-linux-gnu.
>

> diff --git a/gcc/testsuite/gcc.dg/pr70807.c b/gcc/testsuite/gcc.dg/pr70807.c
> new file mode 100644
> index 0000000..9ef2a4d
> --- /dev/null
> +++ b/gcc/testsuite/gcc.dg/pr70807.c
> @@ -0,0 +1,18 @@
> +/* PR middle-end/70807 */
> +/* { dg-do compile } */
> +/* { dg-options "-O2" } */
> +
> +typedef int INT;
> +int a, b, c, d, e, f;
> +void fn1() {
> +  INT g;
> +  if (d && a)
> +    ;
> +  else if (e && b)
> +    ;
> +  else if (!a && !b && c)
> +    ;
> +  else if (b && d || a && e)
> +    a = 0;
> +  f = g || d;
> +}

Does this test fail without the fix?

-- 
H.J.

Reply via email to