1; RUN: opt < %s -basic-aa -slp-vectorizer -mtriple=ve-linux -S | FileCheck %s -check-prefix=VE
2; RUN: opt < %s -basic-aa -slp-vectorizer -mtriple=x86_64-pc_linux -mcpu=core-avx2 -S | FileCheck %s -check-prefix=SSE
3
4; Make sure SLP does not trigger for VE on an appealing set of combinable loads
5; and stores that vectorizes for x86 SSE.
6
7; TODO: Remove this test once VE vector isel is deemed stable.
8
9; VE-NOT: x double
10; SSE: x double
11
12define void @foo(double* noalias %A0p, double* noalias %B0p) {
13entry:
14  %A1p = getelementptr inbounds double, double* %A0p, i64 1
15  %A2p = getelementptr inbounds double, double* %A0p, i64 2
16  %A3p = getelementptr inbounds double, double* %A0p, i64 3
17  %A4p = getelementptr inbounds double, double* %A0p, i64 4
18  %A5p = getelementptr inbounds double, double* %A0p, i64 5
19  %A6p = getelementptr inbounds double, double* %A0p, i64 6
20  %A7p = getelementptr inbounds double, double* %A0p, i64 7
21  %A8p = getelementptr inbounds double, double* %A0p, i64 8
22  %A9p = getelementptr inbounds double, double* %A0p, i64 9
23  %A10p = getelementptr inbounds double, double* %A0p, i64 10
24  %A11p = getelementptr inbounds double, double* %A0p, i64 11
25  %A12p = getelementptr inbounds double, double* %A0p, i64 12
26  %A13p = getelementptr inbounds double, double* %A0p, i64 13
27  %A14p = getelementptr inbounds double, double* %A0p, i64 14
28  %A15p = getelementptr inbounds double, double* %A0p, i64 15
29  %A0 = load double, double* %A0p, align 8
30  %A1 = load double, double* %A1p, align 8
31  %A2 = load double, double* %A2p, align 8
32  %A3 = load double, double* %A3p, align 8
33  %A4 = load double, double* %A4p, align 8
34  %A5 = load double, double* %A5p, align 8
35  %A6 = load double, double* %A6p, align 8
36  %A7 = load double, double* %A7p, align 8
37  %A8 = load double, double* %A8p, align 8
38  %A9 = load double, double* %A9p, align 8
39  %A10 = load double, double* %A10p, align 8
40  %A11 = load double, double* %A11p, align 8
41  %A12 = load double, double* %A12p, align 8
42  %A13 = load double, double* %A13p, align 8
43  %A14 = load double, double* %A14p, align 8
44  %A15 = load double, double* %A15p, align 8
45  %B1p = getelementptr inbounds double, double* %B0p, i64 1
46  %B2p = getelementptr inbounds double, double* %B0p, i64 2
47  %B3p = getelementptr inbounds double, double* %B0p, i64 3
48  %B4p = getelementptr inbounds double, double* %B0p, i64 4
49  %B5p = getelementptr inbounds double, double* %B0p, i64 5
50  %B6p = getelementptr inbounds double, double* %B0p, i64 6
51  %B7p = getelementptr inbounds double, double* %B0p, i64 7
52  %B8p = getelementptr inbounds double, double* %B0p, i64 8
53  %B9p = getelementptr inbounds double, double* %B0p, i64 9
54  %B10p = getelementptr inbounds double, double* %B0p, i64 10
55  %B11p = getelementptr inbounds double, double* %B0p, i64 11
56  %B12p = getelementptr inbounds double, double* %B0p, i64 12
57  %B13p = getelementptr inbounds double, double* %B0p, i64 13
58  %B14p = getelementptr inbounds double, double* %B0p, i64 14
59  %B15p = getelementptr inbounds double, double* %B0p, i64 15
60  store double %A0, double* %B0p, align 8
61  store double %A1, double* %B1p, align 8
62  store double %A2, double* %B2p, align 8
63  store double %A3, double* %B3p, align 8
64  store double %A4, double* %B4p, align 8
65  store double %A5, double* %B5p, align 8
66  store double %A6, double* %B6p, align 8
67  store double %A7, double* %B7p, align 8
68  store double %A8, double* %B8p, align 8
69  store double %A9, double* %B9p, align 8
70  store double %A10, double* %B10p, align 8
71  store double %A11, double* %B11p, align 8
72  store double %A12, double* %B12p, align 8
73  store double %A13, double* %B13p, align 8
74  store double %A14, double* %B14p, align 8
75  store double %A15, double* %B15p, align 8
76  ret void
77}
78