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

            Bug ID: 119581
           Summary: Failure to use vector vandn instruction on RISC-V
           Product: gcc
           Version: unknown
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: target
          Assignee: unassigned at gcc dot gnu.org
          Reporter: law at gcc dot gnu.org
  Target Milestone: ---

#include <stdbool.h>

void andn(int *a, int mask) {
    for (int i = 0; i < 256; i++)
        a[i] &= ~mask;
}

Should compile down into a vandn.  Support for this was recently added to LLVM
and reported to me privately as a missed optimization bug in GCC.


https://godbolt.org/z/zzvK3q635

Reply via email to