[Bug target/98648] New: Failure to optimize out no-op vector operation using andnot

gabravier at gmail dot com gcc-bugzilla@gcc.gnu.org
Wed Jan 13 01:02:48 GMT 2021


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

            Bug ID: 98648
           Summary: Failure to optimize out no-op vector operation using
                    andnot
           Product: gcc
           Version: 11.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: target
          Assignee: unassigned at gcc dot gnu.org
          Reporter: gabravier at gmail dot com
  Target Milestone: ---

__m128 f(__m128 val) 
{
    return _mm_andnot_ps(_mm_set_ps1(0.0f), val);
}

This can be optimized to `return val;`. This optimization is done by LLVM, but
not by GCC.


More information about the Gcc-bugs mailing list