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.