1 ; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py
2 ; RUN: llc -mtriple=aarch64-linux-gnu -mattr=+sve2 -mattr=+use-experimental-zeroing-pseudos < %s | FileCheck %s
8 ; NOTE: The %unused paramter ensures z0 is free, leading to a simpler test.
9 define <vscale x 8 x i16> @flogb_f16(<vscale x 8 x i16> %unused, <vscale x 8 x i1> %pg, <vscale x 8 x half> %a) {
10 ; CHECK-LABEL: flogb_f16:
12 ; CHECK-NEXT: movprfx z0.h, p0/z, z1.h
13 ; CHECK-NEXT: flogb z0.h, p0/m, z1.h
15 %out = call <vscale x 8 x i16> @llvm.aarch64.sve.flogb.nxv8f16(<vscale x 8 x i16> zeroinitializer,
16 <vscale x 8 x i1> %pg,
17 <vscale x 8 x half> %a)
18 ret <vscale x 8 x i16> %out
21 define <vscale x 4 x i32> @flogb_f32(<vscale x 4 x i32> %unused, <vscale x 4 x i1> %pg, <vscale x 4 x float> %a) {
22 ; CHECK-LABEL: flogb_f32:
24 ; CHECK-NEXT: movprfx z0.s, p0/z, z1.s
25 ; CHECK-NEXT: flogb z0.s, p0/m, z1.s
27 %out = call <vscale x 4 x i32> @llvm.aarch64.sve.flogb.nxv4f32(<vscale x 4 x i32> zeroinitializer,
28 <vscale x 4 x i1> %pg,
29 <vscale x 4 x float> %a)
30 ret <vscale x 4 x i32> %out
33 define <vscale x 2 x i64> @flogb_f64(<vscale x 2 x i64> %unused, <vscale x 2 x i1> %pg, <vscale x 2 x double> %a) {
34 ; CHECK-LABEL: flogb_f64:
36 ; CHECK-NEXT: movprfx z0.d, p0/z, z1.d
37 ; CHECK-NEXT: flogb z0.d, p0/m, z1.d
39 %out = call <vscale x 2 x i64> @llvm.aarch64.sve.flogb.nxv2f64(<vscale x 2 x i64> zeroinitializer,
40 <vscale x 2 x i1> %pg,
41 <vscale x 2 x double> %a)
42 ret <vscale x 2 x i64> %out
45 declare <vscale x 8 x i16> @llvm.aarch64.sve.flogb.nxv8f16(<vscale x 8 x i16>, <vscale x 8 x i1>, <vscale x 8 x half>)
46 declare <vscale x 4 x i32> @llvm.aarch64.sve.flogb.nxv4f32(<vscale x 4 x i32>, <vscale x 4 x i1>, <vscale x 4 x float>)
47 declare <vscale x 2 x i64> @llvm.aarch64.sve.flogb.nxv2f64(<vscale x 2 x i64>, <vscale x 2 x i1>, <vscale x 2 x double>)