1a5f12623SSimon Moll; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py 2a5f12623SSimon Moll; RUN: llc < %s -mtriple=ve-unknown-unknown -mattr=+vpu | FileCheck %s 3a5f12623SSimon Moll 4*b006b60dSNikita Popovdeclare <256 x double> @llvm.masked.gather.v256f64.v256p0(<256 x ptr> %0, i32 immarg %1, <256 x i1> %2, <256 x double> %3) #0 5a5f12623SSimon Moll 6a5f12623SSimon Moll; Function Attrs: nounwind 7*b006b60dSNikita Popovdefine fastcc <256 x double> @vec_mgather_v256f64(<256 x ptr> %P, <256 x i1> %M) { 8a5f12623SSimon Moll; CHECK-LABEL: vec_mgather_v256f64: 9a5f12623SSimon Moll; CHECK: # %bb.0: 10a5f12623SSimon Moll; CHECK-NEXT: lea %s0, 256 11a5f12623SSimon Moll; CHECK-NEXT: lvl %s0 12a5f12623SSimon Moll; CHECK-NEXT: vgt %v0, %v0, 0, 0 13a5f12623SSimon Moll; CHECK-NEXT: b.l.t (, %s10) 14*b006b60dSNikita Popov %r = call <256 x double> @llvm.masked.gather.v256f64.v256p0(<256 x ptr> %P, i32 4, <256 x i1> %M, <256 x double> undef) 15a5f12623SSimon Moll ret <256 x double> %r 16a5f12623SSimon Moll} 17a5f12623SSimon Moll 18a5f12623SSimon Moll; Function Attrs: nounwind 19*b006b60dSNikita Popovdefine fastcc <256 x double> @vec_mgather_pt_v256f64(<256 x ptr> %P, <256 x double> %PT, <256 x i1> %M) { 20a5f12623SSimon Moll; CHECK-LABEL: vec_mgather_pt_v256f64: 21a5f12623SSimon Moll; CHECK: # %bb.0: 22a5f12623SSimon Moll; CHECK-NEXT: lea %s0, 256 23a5f12623SSimon Moll; CHECK-NEXT: lvl %s0 24a5f12623SSimon Moll; CHECK-NEXT: vgt %v2, %v0, 0, 0 25a5f12623SSimon Moll; CHECK-NEXT: lea %s16, 256 26a5f12623SSimon Moll; CHECK-NEXT: lvl %s16 27a5f12623SSimon Moll; CHECK-NEXT: vor %v0, (0)1, %v1 28a5f12623SSimon Moll; CHECK-NEXT: lvl %s0 29a5f12623SSimon Moll; CHECK-NEXT: vmrg %v0, %v1, %v2, %vm0 30a5f12623SSimon Moll; CHECK-NEXT: b.l.t (, %s10) 31*b006b60dSNikita Popov %r = call <256 x double> @llvm.masked.gather.v256f64.v256p0(<256 x ptr> %P, i32 4, <256 x i1> %M, <256 x double> %PT) 32a5f12623SSimon Moll ret <256 x double> %r 33a5f12623SSimon Moll} 34a5f12623SSimon Moll 35a5f12623SSimon Moll 36*b006b60dSNikita Popovdeclare <256 x float> @llvm.masked.gather.v256f32.v256p0(<256 x ptr> %0, i32 immarg %1, <256 x i1> %2, <256 x float> %3) #0 37a5f12623SSimon Moll 38a5f12623SSimon Moll; Function Attrs: nounwind 39*b006b60dSNikita Popovdefine fastcc <256 x float> @vec_mgather_v256f32(<256 x ptr> %P, <256 x i1> %M) { 40a5f12623SSimon Moll; CHECK-LABEL: vec_mgather_v256f32: 41a5f12623SSimon Moll; CHECK: # %bb.0: 42a5f12623SSimon Moll; CHECK-NEXT: lea %s0, 256 43a5f12623SSimon Moll; CHECK-NEXT: lvl %s0 44a5f12623SSimon Moll; CHECK-NEXT: vgtu %v0, %v0, 0, 0 45a5f12623SSimon Moll; CHECK-NEXT: b.l.t (, %s10) 46*b006b60dSNikita Popov %r = call <256 x float> @llvm.masked.gather.v256f32.v256p0(<256 x ptr> %P, i32 4, <256 x i1> %M, <256 x float> undef) 47a5f12623SSimon Moll ret <256 x float> %r 48a5f12623SSimon Moll} 49a5f12623SSimon Moll 50a5f12623SSimon Moll; Function Attrs: nounwind 51*b006b60dSNikita Popovdefine fastcc <256 x float> @vec_mgather_pt_v256f32(<256 x ptr> %P, <256 x float> %PT, <256 x i1> %M) { 52a5f12623SSimon Moll; CHECK-LABEL: vec_mgather_pt_v256f32: 53a5f12623SSimon Moll; CHECK: # %bb.0: 54a5f12623SSimon Moll; CHECK-NEXT: lea %s0, 256 55a5f12623SSimon Moll; CHECK-NEXT: lvl %s0 56a5f12623SSimon Moll; CHECK-NEXT: vgtu %v2, %v0, 0, 0 57a5f12623SSimon Moll; CHECK-NEXT: lea %s16, 256 58a5f12623SSimon Moll; CHECK-NEXT: lvl %s16 59a5f12623SSimon Moll; CHECK-NEXT: vor %v0, (0)1, %v1 60a5f12623SSimon Moll; CHECK-NEXT: lvl %s0 61a5f12623SSimon Moll; CHECK-NEXT: vmrg %v0, %v1, %v2, %vm0 62a5f12623SSimon Moll; CHECK-NEXT: b.l.t (, %s10) 63*b006b60dSNikita Popov %r = call <256 x float> @llvm.masked.gather.v256f32.v256p0(<256 x ptr> %P, i32 4, <256 x i1> %M, <256 x float> %PT) 64a5f12623SSimon Moll ret <256 x float> %r 65a5f12623SSimon Moll} 66a5f12623SSimon Moll 67a5f12623SSimon Moll 68*b006b60dSNikita Popovdeclare <256 x i32> @llvm.masked.gather.v256i32.v256p0(<256 x ptr> %0, i32 immarg %1, <256 x i1> %2, <256 x i32> %3) #0 69a5f12623SSimon Moll 70a5f12623SSimon Moll; Function Attrs: nounwind 71*b006b60dSNikita Popovdefine fastcc <256 x i32> @vec_mgather_v256i32(<256 x ptr> %P, <256 x i1> %M) { 72a5f12623SSimon Moll; CHECK-LABEL: vec_mgather_v256i32: 73a5f12623SSimon Moll; CHECK: # %bb.0: 74a5f12623SSimon Moll; CHECK-NEXT: lea %s0, 256 75a5f12623SSimon Moll; CHECK-NEXT: lvl %s0 76a5f12623SSimon Moll; CHECK-NEXT: vgtl.zx %v0, %v0, 0, 0 77a5f12623SSimon Moll; CHECK-NEXT: b.l.t (, %s10) 78*b006b60dSNikita Popov %r = call <256 x i32> @llvm.masked.gather.v256i32.v256p0(<256 x ptr> %P, i32 4, <256 x i1> %M, <256 x i32> undef) 79a5f12623SSimon Moll ret <256 x i32> %r 80a5f12623SSimon Moll} 81a5f12623SSimon Moll 82a5f12623SSimon Moll; Function Attrs: nounwind 83*b006b60dSNikita Popovdefine fastcc <256 x i32> @vec_mgather_pt_v256i32(<256 x ptr> %P, <256 x i32> %PT, <256 x i1> %M) { 84a5f12623SSimon Moll; CHECK-LABEL: vec_mgather_pt_v256i32: 85a5f12623SSimon Moll; CHECK: # %bb.0: 86a5f12623SSimon Moll; CHECK-NEXT: lea %s0, 256 87a5f12623SSimon Moll; CHECK-NEXT: lvl %s0 88a5f12623SSimon Moll; CHECK-NEXT: vgtl.zx %v2, %v0, 0, 0 89a5f12623SSimon Moll; CHECK-NEXT: lea %s16, 256 90a5f12623SSimon Moll; CHECK-NEXT: lvl %s16 91a5f12623SSimon Moll; CHECK-NEXT: vor %v0, (0)1, %v1 92a5f12623SSimon Moll; CHECK-NEXT: lvl %s0 93a5f12623SSimon Moll; CHECK-NEXT: vmrg %v0, %v1, %v2, %vm0 94a5f12623SSimon Moll; CHECK-NEXT: b.l.t (, %s10) 95*b006b60dSNikita Popov %r = call <256 x i32> @llvm.masked.gather.v256i32.v256p0(<256 x ptr> %P, i32 4, <256 x i1> %M, <256 x i32> %PT) 96a5f12623SSimon Moll ret <256 x i32> %r 97a5f12623SSimon Moll} 98a5f12623SSimon Moll 99a5f12623SSimon Mollattributes #0 = { argmemonly nounwind readonly willreturn } 100