157 lines · plain
1; NOTE: Assertions have been autogenerated by utils/update_test_checks.py UTC_ARGS: --version 52; RUN: opt -S -passes=instcombine < %s | FileCheck %s3target triple = "aarch64-unknown-linux-gnu"4 5define void @test_prf(ptr %base){6; CHECK-LABEL: define void @test_prf(7; CHECK-SAME: ptr [[BASE:%.*]]) {8; CHECK-NEXT: ret void9;10 tail call void @llvm.aarch64.sve.prf.nxv16i1(<vscale x 16 x i1> zeroinitializer, ptr %base, i32 1)11 ret void12}13 14define void @test_prfb_gather_index(ptr %base, <vscale x 2 x i64> %indexes){15; CHECK-LABEL: define void @test_prfb_gather_index(16; CHECK-SAME: ptr [[BASE:%.*]], <vscale x 2 x i64> [[INDEXES:%.*]]) {17; CHECK-NEXT: ret void18;19 call void @llvm.aarch64.sve.prfb.gather.index.nx2vi64(<vscale x 2 x i1> zeroinitializer, ptr %base, <vscale x 2 x i64> %indexes, i32 1)20 ret void21}22 23define void @test_prfb_gather_scalar_offset(<vscale x 4 x i32> %bases){24; CHECK-LABEL: define void @test_prfb_gather_scalar_offset(25; CHECK-SAME: <vscale x 4 x i32> [[BASES:%.*]]) {26; CHECK-NEXT: ret void27;28 call void @llvm.aarch64.sve.prfb.gather.scalar.offset.nx4vi32(<vscale x 4 x i1> zeroinitializer, <vscale x 4 x i32> %bases, i64 7, i32 1)29 ret void30}31 32define void @test_prfb_gather_sxtw_index(ptr %base, <vscale x 4 x i32> %indexes){33; CHECK-LABEL: define void @test_prfb_gather_sxtw_index(34; CHECK-SAME: ptr [[BASE:%.*]], <vscale x 4 x i32> [[INDEXES:%.*]]) {35; CHECK-NEXT: ret void36;37 call void @llvm.aarch64.sve.prfb.gather.sxtw.index.nx4vi32(<vscale x 4 x i1> zeroinitializer, ptr %base, <vscale x 4 x i32> %indexes, i32 1)38 ret void39}40 41define void @test_prfb_gather_uxtw_index(ptr %base, <vscale x 4 x i32> %indexes){42; CHECK-LABEL: define void @test_prfb_gather_uxtw_index(43; CHECK-SAME: ptr [[BASE:%.*]], <vscale x 4 x i32> [[INDEXES:%.*]]) {44; CHECK-NEXT: ret void45;46 call void @llvm.aarch64.sve.prfb.gather.uxtw.index.nx4vi32(<vscale x 4 x i1> zeroinitializer, ptr %base, <vscale x 4 x i32> %indexes, i32 1)47 ret void48}49 50define void @test_prfd_gather_index(ptr %base, <vscale x 2 x i64> %indexes){51; CHECK-LABEL: define void @test_prfd_gather_index(52; CHECK-SAME: ptr [[BASE:%.*]], <vscale x 2 x i64> [[INDEXES:%.*]]) {53; CHECK-NEXT: ret void54;55 call void @llvm.aarch64.sve.prfd.gather.index.nx2vi64(<vscale x 2 x i1> zeroinitializer, ptr %base, <vscale x 2 x i64> %indexes, i32 1)56 ret void57}58 59define void @test_prfd_gather_scalar_offset(<vscale x 4 x i32> %bases){60; CHECK-LABEL: define void @test_prfd_gather_scalar_offset(61; CHECK-SAME: <vscale x 4 x i32> [[BASES:%.*]]) {62; CHECK-NEXT: ret void63;64 call void @llvm.aarch64.sve.prfd.gather.scalar.offset.nx4vi32(<vscale x 4 x i1> zeroinitializer, <vscale x 4 x i32> %bases, i64 7, i32 1)65 ret void66}67 68define void @test_prfd_gather_sxtw_index(ptr %base, <vscale x 4 x i32> %indexes){69; CHECK-LABEL: define void @test_prfd_gather_sxtw_index(70; CHECK-SAME: ptr [[BASE:%.*]], <vscale x 4 x i32> [[INDEXES:%.*]]) {71; CHECK-NEXT: ret void72;73 call void @llvm.aarch64.sve.prfd.gather.sxtw.index.nx4vi32(<vscale x 4 x i1> zeroinitializer, ptr %base, <vscale x 4 x i32> %indexes, i32 1)74 ret void75}76 77define void @test_prfd_gather_uxtw_index(ptr %base, <vscale x 4 x i32> %indexes){78; CHECK-LABEL: define void @test_prfd_gather_uxtw_index(79; CHECK-SAME: ptr [[BASE:%.*]], <vscale x 4 x i32> [[INDEXES:%.*]]) {80; CHECK-NEXT: ret void81;82 call void @llvm.aarch64.sve.prfd.gather.uxtw.index.nx4vi32(<vscale x 4 x i1> zeroinitializer, ptr %base, <vscale x 4 x i32> %indexes, i32 1)83 ret void84}85 86define void @test_prfh_gather_index(ptr %base, <vscale x 2 x i64> %indexes){87; CHECK-LABEL: define void @test_prfh_gather_index(88; CHECK-SAME: ptr [[BASE:%.*]], <vscale x 2 x i64> [[INDEXES:%.*]]) {89; CHECK-NEXT: ret void90;91 call void @llvm.aarch64.sve.prfh.gather.index.nx2vi64(<vscale x 2 x i1> zeroinitializer, ptr %base, <vscale x 2 x i64> %indexes, i32 1)92 ret void93}94 95define void @test_prfh_gather_scalar_offset(<vscale x 4 x i32> %bases){96; CHECK-LABEL: define void @test_prfh_gather_scalar_offset(97; CHECK-SAME: <vscale x 4 x i32> [[BASES:%.*]]) {98; CHECK-NEXT: ret void99;100 call void @llvm.aarch64.sve.prfh.gather.scalar.offset.nx4vi32(<vscale x 4 x i1> zeroinitializer, <vscale x 4 x i32> %bases, i64 7, i32 1)101 ret void102}103 104define void @test_prfh_gather_sxtw_index(ptr %base, <vscale x 4 x i32> %indexes){105; CHECK-LABEL: define void @test_prfh_gather_sxtw_index(106; CHECK-SAME: ptr [[BASE:%.*]], <vscale x 4 x i32> [[INDEXES:%.*]]) {107; CHECK-NEXT: ret void108;109 call void @llvm.aarch64.sve.prfh.gather.sxtw.index.nx4vi32(<vscale x 4 x i1> zeroinitializer, ptr %base, <vscale x 4 x i32> %indexes, i32 1)110 ret void111}112 113define void @test_prfh_gather_uxtw_index(ptr %base, <vscale x 4 x i32> %indexes){114; CHECK-LABEL: define void @test_prfh_gather_uxtw_index(115; CHECK-SAME: ptr [[BASE:%.*]], <vscale x 4 x i32> [[INDEXES:%.*]]) {116; CHECK-NEXT: ret void117;118 call void @llvm.aarch64.sve.prfh.gather.uxtw.index.nx4vi32(<vscale x 4 x i1> zeroinitializer, ptr %base, <vscale x 4 x i32> %indexes, i32 1)119 ret void120}121 122define void @test_prfw_gather_index(ptr %base, <vscale x 2 x i64> %indexes){123; CHECK-LABEL: define void @test_prfw_gather_index(124; CHECK-SAME: ptr [[BASE:%.*]], <vscale x 2 x i64> [[INDEXES:%.*]]) {125; CHECK-NEXT: ret void126;127 call void @llvm.aarch64.sve.prfw.gather.index.nx2vi64(<vscale x 2 x i1> zeroinitializer, ptr %base, <vscale x 2 x i64> %indexes, i32 1)128 ret void129}130 131define void @test_prfw_gather_scalar_offset(<vscale x 4 x i32> %bases){132; CHECK-LABEL: define void @test_prfw_gather_scalar_offset(133; CHECK-SAME: <vscale x 4 x i32> [[BASES:%.*]]) {134; CHECK-NEXT: ret void135;136 call void @llvm.aarch64.sve.prfw.gather.scalar.offset.nx4vi32(<vscale x 4 x i1> zeroinitializer, <vscale x 4 x i32> %bases, i64 7, i32 1)137 ret void138}139 140define void @test_prfw_gather_sxtw_index(ptr %base, <vscale x 4 x i32> %indexes){141; CHECK-LABEL: define void @test_prfw_gather_sxtw_index(142; CHECK-SAME: ptr [[BASE:%.*]], <vscale x 4 x i32> [[INDEXES:%.*]]) {143; CHECK-NEXT: ret void144;145 call void @llvm.aarch64.sve.prfw.gather.sxtw.index.nx4vi32(<vscale x 4 x i1> zeroinitializer, ptr %base, <vscale x 4 x i32> %indexes, i32 1)146 ret void147}148 149define void @test_prfw_gather_uxtw_index(ptr %base, <vscale x 4 x i32> %indexes){150; CHECK-LABEL: define void @test_prfw_gather_uxtw_index(151; CHECK-SAME: ptr [[BASE:%.*]], <vscale x 4 x i32> [[INDEXES:%.*]]) {152; CHECK-NEXT: ret void153;154 call void @llvm.aarch64.sve.prfw.gather.uxtw.index.nx4vi32(<vscale x 4 x i1> zeroinitializer, ptr %base, <vscale x 4 x i32> %indexes, i32 1)155 ret void156}157