Skip to content

Commit

Permalink
tests/vector/x86: cover pshuf.b (#1143)
Browse files Browse the repository at this point in the history
  • Loading branch information
artagnon authored Dec 12, 2024
1 parent e4f7ed1 commit 323fe76
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 0 deletions.
8 changes: 8 additions & 0 deletions tests/alive-tv/vector/x86/avx2_pshuf_b-identity.srctgt.ll
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
define <32 x i8> @src() {
%call = tail call <32 x i8> @llvm.x86.avx2.pshuf.b(<32 x i8> <i8 0, i8 1, i8 2, i8 3, i8 4, i8 5, i8 6, i8 7, i8 8, i8 9, i8 10, i8 11, i8 12, i8 13, i8 14, i8 15, i8 16, i8 17, i8 18, i8 19, i8 20, i8 21, i8 22, i8 23, i8 24, i8 25, i8 26, i8 27, i8 28, i8 29, i8 poison, i8 31>, <32 x i8> <i8 0, i8 1, i8 2, i8 3, i8 4, i8 5, i8 6, i8 7, i8 8, i8 9, i8 10, i8 11, i8 12, i8 13, i8 14, i8 15, i8 0, i8 1, i8 2, i8 3, i8 4, i8 5, i8 6, i8 7, i8 8, i8 9, i8 10, i8 11, i8 12, i8 13, i8 14, i8 15>)
ret <32 x i8> %call
}

define <32 x i8> @tgt() {
ret <32 x i8> <i8 0, i8 1, i8 2, i8 3, i8 4, i8 5, i8 6, i8 7, i8 8, i8 9, i8 10, i8 11, i8 12, i8 13, i8 14, i8 15, i8 16, i8 17, i8 18, i8 19, i8 20, i8 21, i8 22, i8 23, i8 24, i8 25, i8 26, i8 27, i8 28, i8 29, i8 poison, i8 31>
}
8 changes: 8 additions & 0 deletions tests/alive-tv/vector/x86/ssse3_pshuf_b.srctgt.ll
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
define <16 x i8> @src() {
%call = tail call <16 x i8> @llvm.x86.ssse3.pshuf.b.128(<16 x i8> <i8 0, i8 1, i8 2, i8 3, i8 4, i8 5, i8 6, i8 7, i8 8, i8 9, i8 10, i8 11, i8 12, i8 13, i8 14, i8 15>, <16 x i8> <i8 16, i8 15, i8 32, i8 33, i8 34, i8 48, i8 64, i8 65, i8 128, i8 129, i8 255, i8 -1, i8 -16, i8 -33, i8 0, i8 poison>)
ret <16 x i8> %call
}

define <16 x i8> @tgt() {
ret <16 x i8> <i8 0, i8 15, i8 0, i8 1, i8 2, i8 0, i8 0, i8 1, i8 0, i8 0, i8 0, i8 0, i8 0, i8 0, i8 0, i8 poison>
}

0 comments on commit 323fe76

Please sign in to comment.