https://gcc.gnu.org/bugzilla/show_bug.cgi?id=102622

Andrew Pinski <pinskia at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
   Target Milestone|12.0                        |9.5
      Known to work|9.3.0                       |11.1.0, 4.9.2, 7.1.0, 8.5.0
      Known to fail|                            |10.3.0, 9.1.0, 9.4.0
            Summary|[12 Regression] Wrong code  |[9/10/12 Regression] Wrong
                   |with -O3 for skylake-avx512 |code with -O1 and above due
                   |and icelake-server by       |to phiopt and signed one
                   |r12-3903                    |bit integer types

--- Comment #17 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
So the reason why we didn't hit it in GCC 11 (and before) was the order of the
following was swapped in phiopt compared to what it is in match.pd now:
a ? -1 : 0 -> -a
a ? powerof2cst : 0 -> a << (log2(powerof2cst))

That is did the powerof2cst case before it did the -1 case.  I am going to test
that to see if it works here which I think it does.

In fact my new testcase fails in GCC 9.1.0-10.3.0 :).

I am going to fix this for the trunk and come up with a fix for the other
branches later on.

And yes the regression markers are a bit off right now but that is because the
bug is not latent on the 12 branch.

Reply via email to