[Bug target/50155] New: [4.7 Regression] AVX2 support broke -mavx

jakub at gcc dot gnu.org gcc-bugzilla@gcc.gnu.org
Mon Aug 22 16:40:00 GMT 2011


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=50155

             Bug #: 50155
           Summary: [4.7 Regression] AVX2 support broke -mavx
    Classification: Unclassified
           Product: gcc
           Version: 4.7.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: target
        AssignedTo: unassigned@gcc.gnu.org
        ReportedBy: jakub@gcc.gnu.org
                CC: hjl.tools@gmail.com, uros@gcc.gnu.org


void
foo (int x, double *a, double *b, double c)
{
  int i;

  for (i = 0; i < x; i++)
    *a++ = *b++ * i / c;
}

fails to assemble with -O3 -mavx -m64 on x86_64-linux (at least when using
binutils that don't support AVX2).
vpaddd  %ymm6, %ymm1, %ymm5
is AFAIK an AVX2 insn, not AVX, yet it is emitted by the addv8si3 pattern
(*<plusminus_insn><code>3 insn etc. was previously using VI_128 mode iterator,
but now is using VI, guess it wants to use a mode iterator similar to VI, but
which uses TARGET_AVX2 instead of TARGET_AVX guards for the 32 byte integer
modes (VI_AVX2 or VI_1248_AVX2?)).



More information about the Gcc-bugs mailing list