xref: /llvm-project/llvm/test/CodeGen/LoongArch/lasx/intrinsic-ld-invalid-imm.ll (revision ff9af4c43ad71eeba2cabe99609cfaa0fd54c1d0)
1; RUN: not llc --mtriple=loongarch64 --mattr=+lasx < %s 2>&1 | FileCheck %s
2
3declare <32 x i8> @llvm.loongarch.lasx.xvld(ptr, i32)
4
5define <32 x i8> @lasx_xvld_lo(ptr %p) nounwind {
6; CHECK: llvm.loongarch.lasx.xvld: argument out of range
7entry:
8  %res = call <32 x i8> @llvm.loongarch.lasx.xvld(ptr %p, i32 -2049)
9  ret <32 x i8> %res
10}
11
12define <32 x i8> @lasx_xvld_hi(ptr %p) nounwind {
13; CHECK: llvm.loongarch.lasx.xvld: argument out of range
14entry:
15  %res = call <32 x i8> @llvm.loongarch.lasx.xvld(ptr %p, i32 2048)
16  ret <32 x i8> %res
17}
18