; RUN: llc -mtriple=aarch64-linux-gnu -mattr=+sve < %s 2>%t | FileCheck %s ; RUN: FileCheck --check-prefix=WARN --allow-empty %s <%t ; If this check fails please read test/CodeGen/AArch64/README for instructions on how to resolve it. ; WARN-NOT: warning ; ; BRKA ; define @brka_m_b8( %inactive, %pg, %a) { ; CHECK-LABEL: brka_m_b8: ; CHECK: brka p0.b, p1/m, p2.b ; CHECK-NEXT: ret %out = call @llvm.aarch64.sve.brka.nxv16i1( %inactive, %pg, %a) ret %out } define @brka_z_b8( %pg, %a) { ; CHECK-LABEL: brka_z_b8: ; CHECK: brka p0.b, p0/z, p1.b ; CHECK-NEXT: ret %out = call @llvm.aarch64.sve.brka.z.nxv16i1( %pg, %a) ret %out } ; ; BRKB ; define @brkb_m_b8( %inactive, %pg, %a) { ; CHECK-LABEL: brkb_m_b8: ; CHECK: brkb p0.b, p1/m, p2.b ; CHECK-NEXT: ret %out = call @llvm.aarch64.sve.brkb.nxv16i1( %inactive, %pg, %a) ret %out } define @brkb_z_b8( %pg, %a) { ; CHECK-LABEL: brkb_z_b8: ; CHECK: brkb p0.b, p0/z, p1.b ; CHECK-NEXT: ret %out = call @llvm.aarch64.sve.brkb.z.nxv16i1( %pg, %a) ret %out } ; ; BRKN ; define @brkn_b8( %pg, %a, %b) { ; CHECK-LABEL: brkn_b8: ; CHECK: brkn p2.b, p0/z, p1.b, p2.b ; CHECK-NEXT: mov p0.b, p2.b ; CHECK-NEXT: ret %out = call @llvm.aarch64.sve.brkn.z.nxv16i1( %pg, %a, %b) ret %out } ; ; BRKPA ; define @brkpa_b8( %pg, %a, %b) { ; CHECK-LABEL: brkpa_b8: ; CHECK: brkpa p0.b, p0/z, p1.b, p2.b ; CHECK-NEXT: ret %out = call @llvm.aarch64.sve.brkpa.z.nxv16i1( %pg, %a, %b) ret %out } ; ; BRKPB ; define @brkpb_b8( %pg, %a, %b) { ; CHECK-LABEL: brkpb_b8: ; CHECK: brkpb p0.b, p0/z, p1.b, p2.b ; CHECK-NEXT: ret %out = call @llvm.aarch64.sve.brkpb.z.nxv16i1( %pg, %a, %b) ret %out } ; ; PFIRST ; define @pfirst_b8( %pg, %a) { ; CHECK-LABEL: pfirst_b8: ; CHECK: pfirst p1.b, p0, p1.b ; CHECK-NEXT: mov p0.b, p1.b ; CHECK-NEXT: ret %out = call @llvm.aarch64.sve.pfirst.nxv16i1( %pg, %a) ret %out } ; ; PNEXT ; define @pnext_b8( %pg, %a) { ; CHECK-LABEL: pnext_b8: ; CHECK: pnext p1.b, p0, p1.b ; CHECK-NEXT: mov p0.b, p1.b ; CHECK-NEXT: ret %out = call @llvm.aarch64.sve.pnext.nxv16i1( %pg, %a) ret %out } define @pnext_b16( %pg, %a) { ; CHECK-LABEL: pnext_b16: ; CHECK: pnext p1.h, p0, p1.h ; CHECK-NEXT: mov p0.b, p1.b ; CHECK-NEXT: ret %out = call @llvm.aarch64.sve.pnext.nxv8i1( %pg, %a) ret %out } define @pnext_b32( %pg, %a) { ; CHECK-LABEL: pnext_b32: ; CHECK: pnext p1.s, p0, p1.s ; CHECK-NEXT: mov p0.b, p1.b ; CHECK-NEXT: ret %out = call @llvm.aarch64.sve.pnext.nxv4i1( %pg, %a) ret %out } define @pnext_b64( %pg, %a) { ; CHECK-LABEL: pnext_b64: ; CHECK: pnext p1.d, p0, p1.d ; CHECK-NEXT: mov p0.b, p1.b ; CHECK-NEXT: ret %out = call @llvm.aarch64.sve.pnext.nxv2i1( %pg, %a) ret %out } ; ; PUNPKHI ; define @punpkhi_b16( %a) { ; CHECK-LABEL: punpkhi_b16 ; CHECK: punpkhi p0.h, p0.b ; CHECK-NEXT: ret %res = call @llvm.aarch64.sve.punpkhi.nxv8i1( %a) ret %res } define @punpkhi_b8( %a) { ; CHECK-LABEL: punpkhi_b8 ; CHECK: punpkhi p0.h, p0.b ; CHECK-NEXT: ret %res = call @llvm.aarch64.sve.punpkhi.nxv4i1( %a) ret %res } define @punpkhi_b4( %a) { ; CHECK-LABEL: punpkhi_b4 ; CHECK: punpkhi p0.h, p0.b ; CHECK-NEXT: ret %res = call @llvm.aarch64.sve.punpkhi.nxv2i1( %a) ret %res } ; ; PUNPKLO ; define @punpklo_b16( %a) { ; CHECK-LABEL: punpklo_b16 ; CHECK: punpklo p0.h, p0.b ; CHECK-NEXT: ret %res = call @llvm.aarch64.sve.punpklo.nxv8i1( %a) ret %res } define @punpklo_b8( %a) { ; CHECK-LABEL: punpklo_b8 ; CHECK: punpklo p0.h, p0.b ; CHECK-NEXT: ret %res = call @llvm.aarch64.sve.punpklo.nxv4i1( %a) ret %res } define @punpklo_b4( %a) { ; CHECK-LABEL: punpklo_b4 ; CHECK: punpklo p0.h, p0.b ; CHECK-NEXT: ret %res = call @llvm.aarch64.sve.punpklo.nxv2i1( %a) ret %res } declare @llvm.aarch64.sve.brka.nxv16i1(, , ) declare @llvm.aarch64.sve.brka.z.nxv16i1(, ) declare @llvm.aarch64.sve.brkb.nxv16i1(, , ) declare @llvm.aarch64.sve.brkb.z.nxv16i1(, ) declare @llvm.aarch64.sve.brkn.z.nxv16i1(, , ) declare @llvm.aarch64.sve.brkpa.z.nxv16i1(, , ) declare @llvm.aarch64.sve.brkpb.z.nxv16i1(, , ) declare @llvm.aarch64.sve.pfirst.nxv16i1(, ) declare @llvm.aarch64.sve.pnext.nxv16i1(, ) declare @llvm.aarch64.sve.pnext.nxv8i1(, ) declare @llvm.aarch64.sve.pnext.nxv4i1(, ) declare @llvm.aarch64.sve.pnext.nxv2i1(, ) declare @llvm.aarch64.sve.punpkhi.nxv8i1() declare @llvm.aarch64.sve.punpkhi.nxv4i1() declare @llvm.aarch64.sve.punpkhi.nxv2i1() declare @llvm.aarch64.sve.punpklo.nxv8i1() declare @llvm.aarch64.sve.punpklo.nxv4i1() declare @llvm.aarch64.sve.punpklo.nxv2i1()