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

            Bug ID: 115518
           Summary: aarch64: Poor codegen for arm_neon_sve_bridge.h
           Product: gcc
           Version: 15.0
            Status: UNCONFIRMED
          Keywords: aarch64-sve
          Severity: normal
          Priority: P3
         Component: target
          Assignee: unassigned at gcc dot gnu.org
          Reporter: rsandifo at gcc dot gnu.org
  Target Milestone: ---
            Target: aarch64*-*-*

With PR115464 fixed, the following testcase:

#include <arm_neon.h>
#include <arm_sve.h>
#include <arm_neon_sve_bridge.h>

svuint16_t
convolve4_4_x (uint16x8x2_t permute_tbl, svuint16_t a)
{
    return svset_neonq_u16 (a, permute_tbl.val[1]);
}

generates:

        mov     v0.16b, v1.16b
        ptrue   p3.h, vl8
        sel     z0.h, p3, z0.h, z2.h
        ret

The move is redundant: we should be able to use z1.h as input to the sel
instead.

Reply via email to