1 ; RUN: llc -mtriple=aarch64-linux-gnu -mattr=+sve2 -asm-verbose=0 < %s | FileCheck %s
7 define <vscale x 4 x i32> @histcnt_i32(<vscale x 4 x i1> %pg, <vscale x 4 x i32> %a, <vscale x 4 x i32> %b) {
8 ; CHECK-LABEL: histcnt_i32:
9 ; CHECK: histcnt z0.s, p0/z, z0.s, z1.s
11 %out = call <vscale x 4 x i32> @llvm.aarch64.sve.histcnt.nxv4i32(<vscale x 4 x i1> %pg,
12 <vscale x 4 x i32> %a,
13 <vscale x 4 x i32> %b)
14 ret <vscale x 4 x i32> %out
17 define <vscale x 2 x i64> @histcnt_i64(<vscale x 2 x i1> %pg, <vscale x 2 x i64> %a, <vscale x 2 x i64> %b) {
18 ; CHECK-LABEL: histcnt_i64:
19 ; CHECK: histcnt z0.d, p0/z, z0.d, z1.d
21 %out = call <vscale x 2 x i64> @llvm.aarch64.sve.histcnt.nxv2i64(<vscale x 2 x i1> %pg,
22 <vscale x 2 x i64> %a,
23 <vscale x 2 x i64> %b)
24 ret <vscale x 2 x i64> %out
31 define <vscale x 16 x i8> @histseg(<vscale x 16 x i8> %a, <vscale x 16 x i8> %b) {
32 ; CHECK-LABEL: histseg:
33 ; CHECK: histseg z0.b, z0.b, z1.b
35 %out = call <vscale x 16 x i8> @llvm.aarch64.sve.histseg.nxv16i8(<vscale x 16 x i8> %a,
36 <vscale x 16 x i8> %b)
37 ret <vscale x 16 x i8> %out
40 declare <vscale x 4 x i32> @llvm.aarch64.sve.histcnt.nxv4i32(<vscale x 4 x i1>, <vscale x 4 x i32>, <vscale x 4 x i32>)
41 declare <vscale x 2 x i64> @llvm.aarch64.sve.histcnt.nxv2i64(<vscale x 2 x i1>, <vscale x 2 x i64>, <vscale x 2 x i64>)
42 declare <vscale x 16 x i8> @llvm.aarch64.sve.histseg.nxv16i8(<vscale x 16 x i8>, <vscale x 16 x i8>)