[llvm] d81919d - [X86] 2012-01-12-extract-sv.ll - add AVX2 test coverage
Simon Pilgrim via llvm-commits
llvm-commits at lists.llvm.org
Mon Oct 24 09:57:32 PDT 2022
Author: Simon Pilgrim
Date: 2022-10-24T17:55:00+01:00
New Revision: d81919dd7e7797f9ac29f325d47c6386dc930277
URL: https://github.com/llvm/llvm-project/commit/d81919dd7e7797f9ac29f325d47c6386dc930277
DIFF: https://github.com/llvm/llvm-project/commit/d81919dd7e7797f9ac29f325d47c6386dc930277.diff
LOG: [X86] 2012-01-12-extract-sv.ll - add AVX2 test coverage
Added:
Modified:
llvm/test/CodeGen/X86/2012-01-12-extract-sv.ll
Removed:
################################################################################
diff --git a/llvm/test/CodeGen/X86/2012-01-12-extract-sv.ll b/llvm/test/CodeGen/X86/2012-01-12-extract-sv.ll
index 8a20974e7a5cb..94e5484b9e93c 100644
--- a/llvm/test/CodeGen/X86/2012-01-12-extract-sv.ll
+++ b/llvm/test/CodeGen/X86/2012-01-12-extract-sv.ll
@@ -1,20 +1,34 @@
; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py
-; RUN: llc < %s -mattr=+avx -mtriple=i686-pc-win32 | FileCheck %s
+; RUN: llc < %s -mattr=+avx -mtriple=i686-pc-win32 | FileCheck %s --check-prefixes=AVX1
+; RUN: llc < %s -mattr=+avx2 -mtriple=i686-pc-win32 | FileCheck %s --check-prefixes=AVX2
define void @endless_loop() {
-; CHECK-LABEL: endless_loop:
-; CHECK: # %bb.0: # %entry
-; CHECK-NEXT: vmovaps (%eax), %xmm0
-; CHECK-NEXT: vpermilps {{.*#+}} xmm1 = xmm0[0,0,0,0]
-; CHECK-NEXT: vinsertf128 $1, %xmm1, %ymm0, %ymm1
-; CHECK-NEXT: vxorps %xmm2, %xmm2, %xmm2
-; CHECK-NEXT: vblendps {{.*#+}} ymm1 = ymm2[0,1,2,3,4,5,6],ymm1[7]
-; CHECK-NEXT: vxorps %xmm2, %xmm2, %xmm2
-; CHECK-NEXT: vblendps {{.*#+}} xmm0 = xmm0[0],xmm2[1,2,3]
-; CHECK-NEXT: vmovaps %ymm0, (%eax)
-; CHECK-NEXT: vmovaps %ymm1, (%eax)
-; CHECK-NEXT: vzeroupper
-; CHECK-NEXT: retl
+; AVX1-LABEL: endless_loop:
+; AVX1: # %bb.0: # %entry
+; AVX1-NEXT: vmovaps (%eax), %xmm0
+; AVX1-NEXT: vpermilps {{.*#+}} xmm1 = xmm0[0,0,0,0]
+; AVX1-NEXT: vinsertf128 $1, %xmm1, %ymm0, %ymm1
+; AVX1-NEXT: vxorps %xmm2, %xmm2, %xmm2
+; AVX1-NEXT: vblendps {{.*#+}} ymm1 = ymm2[0,1,2,3,4,5,6],ymm1[7]
+; AVX1-NEXT: vxorps %xmm2, %xmm2, %xmm2
+; AVX1-NEXT: vblendps {{.*#+}} xmm0 = xmm0[0],xmm2[1,2,3]
+; AVX1-NEXT: vmovaps %ymm0, (%eax)
+; AVX1-NEXT: vmovaps %ymm1, (%eax)
+; AVX1-NEXT: vzeroupper
+; AVX1-NEXT: retl
+;
+; AVX2-LABEL: endless_loop:
+; AVX2: # %bb.0: # %entry
+; AVX2-NEXT: vbroadcastss (%eax), %xmm0
+; AVX2-NEXT: vxorps %xmm1, %xmm1, %xmm1
+; AVX2-NEXT: vblendps {{.*#+}} xmm1 = xmm0[0],xmm1[1,2,3]
+; AVX2-NEXT: vbroadcastsd %xmm0, %ymm0
+; AVX2-NEXT: vxorps %xmm2, %xmm2, %xmm2
+; AVX2-NEXT: vblendps {{.*#+}} ymm0 = ymm2[0,1,2,3,4,5,6],ymm0[7]
+; AVX2-NEXT: vmovaps %ymm0, (%eax)
+; AVX2-NEXT: vmovaps %ymm1, (%eax)
+; AVX2-NEXT: vzeroupper
+; AVX2-NEXT: retl
entry:
%0 = load <8 x i32>, ptr addrspace(1) undef, align 32
%1 = shufflevector <8 x i32> %0, <8 x i32> undef, <16 x i32> <i32 4, i32 4, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef, i32 undef>
More information about the llvm-commits
mailing list