• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py
2; RUN: llc -march=mips64el -mcpu=mips64r6 -mattr=+msa,+fp64 < %s | FileCheck %s
3
4; Test that simply checks if it will finish when value 255 (-1) appears as
5; immediate in 'nori.b' instruction.
6
7; mips.nori.b %dst, %a, imm
8; mips.nori.b %dst, %a, -1
9; %dst = not (or %a, -1)
10; %dst = xor (or %a, -1), -1
11; %dst = xor -1, -1
12; %dst = 0
13
14define <16 x i8> @foo(<16 x i8> %a) {
15; CHECK-LABEL: foo:
16; CHECK:       # %bb.0: # %bb2
17; CHECK-NEXT:    ldi.b $w0, 0
18; CHECK-NEXT:    copy_s.d $2, $w0[0]
19; CHECK-NEXT:    jr $ra
20; CHECK-NEXT:    copy_s.d $3, $w0[1]
21bb2:
22  %0 = tail call <16 x i8> @llvm.mips.nori.b(<16 x i8> %a, i32 255)
23  ret <16 x i8> %0
24}
25
26declare <16 x i8> @llvm.mips.nori.b(<16 x i8>, i32)
27