1 ; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py
2 ; RUN: llc -mtriple=aarch64-linux-gnu -mattr=+sve2 < %s | FileCheck %s
5 ; STNT1H, STNT1W, STNT1D: base + 64-bit index
8 ; stnt1h { z0.d }, p0, [z0.d, x0]
11 define void @sstnt1h_index(<vscale x 2 x i64> %data, <vscale x 2 x i1> %pg, ptr %base, <vscale x 2 x i64> %offsets) {
12 ; CHECK-LABEL: sstnt1h_index:
14 ; CHECK-NEXT: lsl z1.d, z1.d, #1
15 ; CHECK-NEXT: stnt1h { z0.d }, p0, [z1.d, x0]
17 %data_trunc = trunc <vscale x 2 x i64> %data to <vscale x 2 x i16>
18 call void @llvm.aarch64.sve.stnt1.scatter.index.nxv2i16(<vscale x 2 x i16> %data_trunc,
19 <vscale x 2 x i1> %pg,
21 <vscale x 2 x i64> %offsets)
25 define void @sstnt1w_index(<vscale x 2 x i64> %data, <vscale x 2 x i1> %pg, ptr %base, <vscale x 2 x i64> %offsets) {
26 ; CHECK-LABEL: sstnt1w_index:
28 ; CHECK-NEXT: lsl z1.d, z1.d, #2
29 ; CHECK-NEXT: stnt1w { z0.d }, p0, [z1.d, x0]
31 %data_trunc = trunc <vscale x 2 x i64> %data to <vscale x 2 x i32>
32 call void @llvm.aarch64.sve.stnt1.scatter.index.nxv2i32(<vscale x 2 x i32> %data_trunc,
33 <vscale x 2 x i1> %pg,
35 <vscale x 2 x i64> %offsets)
39 define void @sstnt1d_index(<vscale x 2 x i64> %data, <vscale x 2 x i1> %pg, ptr %base, <vscale x 2 x i64> %offsets) {
40 ; CHECK-LABEL: sstnt1d_index:
42 ; CHECK-NEXT: lsl z1.d, z1.d, #3
43 ; CHECK-NEXT: stnt1d { z0.d }, p0, [z1.d, x0]
45 call void @llvm.aarch64.sve.stnt1.scatter.index.nxv2i64(<vscale x 2 x i64> %data,
46 <vscale x 2 x i1> %pg,
48 <vscale x 2 x i64> %offsets)
52 define void @sstnt1d_index_double(<vscale x 2 x double> %data, <vscale x 2 x i1> %pg, ptr %base, <vscale x 2 x i64> %offsets) {
53 ; CHECK-LABEL: sstnt1d_index_double:
55 ; CHECK-NEXT: lsl z1.d, z1.d, #3
56 ; CHECK-NEXT: stnt1d { z0.d }, p0, [z1.d, x0]
58 call void @llvm.aarch64.sve.stnt1.scatter.index.nxv2f64(<vscale x 2 x double> %data,
59 <vscale x 2 x i1> %pg,
61 <vscale x 2 x i64> %offsets)
66 declare void @llvm.aarch64.sve.stnt1.scatter.index.nxv2i16(<vscale x 2 x i16>, <vscale x 2 x i1>, ptr, <vscale x 2 x i64>)
67 declare void @llvm.aarch64.sve.stnt1.scatter.index.nxv2i32(<vscale x 2 x i32>, <vscale x 2 x i1>, ptr, <vscale x 2 x i64>)
68 declare void @llvm.aarch64.sve.stnt1.scatter.index.nxv2i64(<vscale x 2 x i64>, <vscale x 2 x i1>, ptr, <vscale x 2 x i64>)
69 declare void @llvm.aarch64.sve.stnt1.scatter.index.nxv2f64(<vscale x 2 x double>, <vscale x 2 x i1>, ptr, <vscale x 2 x i64>)