2016-05-11 15:45 GMT+03:00 H.J. Lu <hjl.to...@gmail.com>: > On Wed, May 11, 2016 at 2:26 AM, Ilya Enkovich <enkovich....@gmail.com> wrote: >> 2016-05-10 21:13 GMT+03:00 H.J. Lu <hjl.to...@gmail.com>: >>> 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? >> >> Yes, I creduced it from a libgcc build fail caused by the trigger >> patch from the tracker. >> > > This test only uses int, which is 32-bit. How does it trigger > STV?
I don't fix any bug in STV. This test should trigger CSE. Thanks, Ilya > > -- > H.J.