llvm-project/llvm/test/CodeGen/LoongArch/lsx/intrinsic-bitseli.ll
chenli f3aa441631 [LoongArch] Add LSX intrinsic testcases
Depends on D155829

Reviewed By: SixWeining

Differential Revision: https://reviews.llvm.org/D155834
2023-08-19 17:10:46 +08:00

15 lines
549 B
LLVM

; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py
; RUN: llc --mtriple=loongarch64 --mattr=+lsx < %s | FileCheck %s
declare <16 x i8> @llvm.loongarch.lsx.vbitseli.b(<16 x i8>, <16 x i8>, i32)
define <16 x i8> @lsx_vbitseli_b(<16 x i8> %va, <16 x i8> %vb) nounwind {
; CHECK-LABEL: lsx_vbitseli_b:
; CHECK: # %bb.0: # %entry
; CHECK-NEXT: vbitseli.b $vr0, $vr1, 255
; CHECK-NEXT: ret
entry:
%res = call <16 x i8> @llvm.loongarch.lsx.vbitseli.b(<16 x i8> %va, <16 x i8> %vb, i32 255)
ret <16 x i8> %res
}