1 # NOTE: Assertions have been autogenerated by utils/update_mir_test_checks.py UTC_ARGS: --version 2
2 # RUN: llc -mtriple=x86_64-linux-gnu -mattr=+avx -run-pass=legalizer %s -o - | FileCheck %s --check-prefix=X86-64-AVX
4 # test G_STORE with vectors
7 name: test_gstore_v2s32
10 ; X86-64-AVX-LABEL: name: test_gstore_v2s32
11 ; X86-64-AVX: [[DEF:%[0-9]+]]:_(<2 x s32>) = IMPLICIT_DEF
12 ; X86-64-AVX-NEXT: [[DEF1:%[0-9]+]]:_(p0) = IMPLICIT_DEF
13 ; X86-64-AVX-NEXT: G_STORE [[DEF]](<2 x s32>), [[DEF1]](p0) :: (store (<2 x s32>) into `ptr undef`)
14 ; X86-64-AVX-NEXT: [[COPY:%[0-9]+]]:_(p0) = COPY [[DEF1]](p0)
15 ; X86-64-AVX-NEXT: RET 0, implicit [[COPY]](p0)
16 %0:_(<2 x s32>) = IMPLICIT_DEF
17 %1:_(p0) = IMPLICIT_DEF
18 G_STORE %0:_(<2 x s32>), %1:_(p0) :: (store (<2 x s32>) into `ptr undef`)
19 %2:_(p0) = COPY %1:_(p0)
20 RET 0, implicit %2:_(p0)
24 name: test_gstore_v4s8
27 ; X86-64-AVX-LABEL: name: test_gstore_v4s8
28 ; X86-64-AVX: [[DEF:%[0-9]+]]:_(<4 x s8>) = IMPLICIT_DEF
29 ; X86-64-AVX-NEXT: [[DEF1:%[0-9]+]]:_(p0) = IMPLICIT_DEF
30 ; X86-64-AVX-NEXT: G_STORE [[DEF]](<4 x s8>), [[DEF1]](p0) :: (store (<4 x s8>) into `ptr undef`)
31 ; X86-64-AVX-NEXT: [[COPY:%[0-9]+]]:_(p0) = COPY [[DEF1]](p0)
32 ; X86-64-AVX-NEXT: RET 0, implicit [[COPY]](p0)
33 %0:_(<4 x s8>) = IMPLICIT_DEF
34 %1:_(p0) = IMPLICIT_DEF
35 G_STORE %0:_(<4 x s8>), %1:_(p0) :: (store (<4 x s8>) into `ptr undef`)
36 %2:_(p0) = COPY %1:_(p0)
37 RET 0, implicit %2:_(p0)
41 name: test_gstore_v4p0
44 ; X86-64-AVX-LABEL: name: test_gstore_v4p0
45 ; X86-64-AVX: [[DEF:%[0-9]+]]:_(<4 x p0>) = IMPLICIT_DEF
46 ; X86-64-AVX-NEXT: [[DEF1:%[0-9]+]]:_(p0) = IMPLICIT_DEF
47 ; X86-64-AVX-NEXT: G_STORE [[DEF]](<4 x p0>), [[DEF1]](p0) :: (store (<4 x p0>) into `ptr undef`)
48 ; X86-64-AVX-NEXT: [[COPY:%[0-9]+]]:_(p0) = COPY [[DEF1]](p0)
49 ; X86-64-AVX-NEXT: RET 0, implicit [[COPY]](p0)
50 %0:_(<4 x p0>) = IMPLICIT_DEF
51 %1:_(p0) = IMPLICIT_DEF
52 G_STORE %0:_(<4 x p0>), %1:_(p0) :: (store (<4 x p0>) into `ptr undef`)
53 %2:_(p0) = COPY %1:_(p0)
54 RET 0, implicit %2:_(p0)
58 name: test_gstore_v2p0
61 ; X86-64-AVX-LABEL: name: test_gstore_v2p0
62 ; X86-64-AVX: [[DEF:%[0-9]+]]:_(<2 x p0>) = IMPLICIT_DEF
63 ; X86-64-AVX-NEXT: [[DEF1:%[0-9]+]]:_(p0) = IMPLICIT_DEF
64 ; X86-64-AVX-NEXT: G_STORE [[DEF]](<2 x p0>), [[DEF1]](p0) :: (store (<2 x p0>) into `ptr undef`)
65 ; X86-64-AVX-NEXT: [[COPY:%[0-9]+]]:_(p0) = COPY [[DEF1]](p0)
66 ; X86-64-AVX-NEXT: RET 0, implicit [[COPY]](p0)
67 %0:_(<2 x p0>) = IMPLICIT_DEF
68 %1:_(p0) = IMPLICIT_DEF
69 G_STORE %0:_(<2 x p0>), %1:_(p0) :: (store (<2 x p0>) into `ptr undef`)
70 %2:_(p0) = COPY %1:_(p0)
71 RET 0, implicit %2:_(p0)