1ab979876SSimon Pilgrim; NOTE: Assertions have been autogenerated by utils/update_analyze_test_checks.py
2*4455c5cdSSimon Pilgrim; RUN: opt < %s -mtriple=x86_64-apple-macosx10.8.0 -passes="print<cost-model>" 2>&1 -disable-output -mattr=+sse2 | FileCheck %s --check-prefixes=SSE,SSE2
3*4455c5cdSSimon Pilgrim; RUN: opt < %s -mtriple=x86_64-apple-macosx10.8.0 -passes="print<cost-model>" 2>&1 -disable-output -mattr=+sse3 | FileCheck %s --check-prefixes=SSE,SSE3
4*4455c5cdSSimon Pilgrim; RUN: opt < %s -mtriple=x86_64-apple-macosx10.8.0 -passes="print<cost-model>" 2>&1 -disable-output -mattr=+ssse3 | FileCheck %s --check-prefixes=SSE,SSSE3
5*4455c5cdSSimon Pilgrim; RUN: opt < %s -mtriple=x86_64-apple-macosx10.8.0 -passes="print<cost-model>" 2>&1 -disable-output -mattr=+sse4.1 | FileCheck %s --check-prefixes=SSE,SSE4
6*4455c5cdSSimon Pilgrim; RUN: opt < %s -mtriple=x86_64-apple-macosx10.8.0 -passes="print<cost-model>" 2>&1 -disable-output -mattr=+sse4.2 | FileCheck %s --check-prefixes=SSE,SSE4
7*4455c5cdSSimon Pilgrim; RUN: opt < %s -mtriple=x86_64-apple-macosx10.8.0 -passes="print<cost-model>" 2>&1 -disable-output -mattr=+avx | FileCheck %s --check-prefixes=AVX
8*4455c5cdSSimon Pilgrim; RUN: opt < %s -mtriple=x86_64-apple-macosx10.8.0 -passes="print<cost-model>" 2>&1 -disable-output -mattr=+avx2 | FileCheck %s --check-prefixes=AVX
9*4455c5cdSSimon Pilgrim; RUN: opt < %s -mtriple=x86_64-apple-macosx10.8.0 -passes="print<cost-model>" 2>&1 -disable-output -mattr=+avx512f | FileCheck %s --check-prefixes=AVX512,AVX512F
10*4455c5cdSSimon Pilgrim; RUN: opt < %s -mtriple=x86_64-apple-macosx10.8.0 -passes="print<cost-model>" 2>&1 -disable-output -mattr=+avx512f,+avx512bw | FileCheck %s --check-prefixes=AVX512,AVX512BW
11ab979876SSimon Pilgrim;
12*4455c5cdSSimon Pilgrim; RUN: opt < %s -mtriple=x86_64-apple-macosx10.8.0 -passes="print<cost-model>" 2>&1 -disable-output -mcpu=slm | FileCheck %s --check-prefixes=SSE,SLM
13*4455c5cdSSimon Pilgrim; RUN: opt < %s -mtriple=x86_64-apple-macosx10.8.0 -passes="print<cost-model>" 2>&1 -disable-output -mcpu=goldmont | FileCheck %s --check-prefixes=SSE,GLM
14*4455c5cdSSimon Pilgrim; RUN: opt < %s -mtriple=x86_64-apple-macosx10.8.0 -passes="print<cost-model>" 2>&1 -disable-output -mcpu=btver2 | FileCheck %s --check-prefixes=AVX
15ab979876SSimon Pilgrim
16ab979876SSimon Pilgrimdefine i32 @insert_double(i32 %arg) {
17ab979876SSimon Pilgrim; SSE-LABEL: 'insert_double'
185db826e4SSimon Pilgrim; SSE-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v2f64_a = insertelement <2 x double> undef, double undef, i32 %arg
19ab979876SSimon Pilgrim; SSE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %v2f64_0 = insertelement <2 x double> undef, double undef, i32 0
20ab979876SSimon Pilgrim; SSE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v2f64_1 = insertelement <2 x double> undef, double undef, i32 1
215db826e4SSimon Pilgrim; SSE-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %v4f64_a = insertelement <4 x double> undef, double undef, i32 %arg
22ab979876SSimon Pilgrim; SSE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %v4f64_0 = insertelement <4 x double> undef, double undef, i32 0
23ab979876SSimon Pilgrim; SSE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v4f64_3 = insertelement <4 x double> undef, double undef, i32 3
245db826e4SSimon Pilgrim; SSE-NEXT:  Cost Model: Found an estimated cost of 9 for instruction: %v8f64_a = insertelement <8 x double> undef, double undef, i32 %arg
25ab979876SSimon Pilgrim; SSE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %v8f64_0 = insertelement <8 x double> undef, double undef, i32 0
26ab979876SSimon Pilgrim; SSE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8f64_3 = insertelement <8 x double> undef, double undef, i32 3
27ab979876SSimon Pilgrim; SSE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %v8f64_4 = insertelement <8 x double> undef, double undef, i32 4
28ab979876SSimon Pilgrim; SSE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8f64_7 = insertelement <8 x double> undef, double undef, i32 7
29ab979876SSimon Pilgrim; SSE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret i32 undef
30ab979876SSimon Pilgrim;
31ab979876SSimon Pilgrim; AVX-LABEL: 'insert_double'
325db826e4SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v2f64_a = insertelement <2 x double> undef, double undef, i32 %arg
33ab979876SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %v2f64_0 = insertelement <2 x double> undef, double undef, i32 0
34ab979876SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v2f64_1 = insertelement <2 x double> undef, double undef, i32 1
355db826e4SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v4f64_a = insertelement <4 x double> undef, double undef, i32 %arg
36ab979876SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %v4f64_0 = insertelement <4 x double> undef, double undef, i32 0
37168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v4f64_3 = insertelement <4 x double> undef, double undef, i32 3
385db826e4SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %v8f64_a = insertelement <8 x double> undef, double undef, i32 %arg
39ab979876SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %v8f64_0 = insertelement <8 x double> undef, double undef, i32 0
40168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v8f64_3 = insertelement <8 x double> undef, double undef, i32 3
41ab979876SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %v8f64_4 = insertelement <8 x double> undef, double undef, i32 4
42168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v8f64_7 = insertelement <8 x double> undef, double undef, i32 7
43ab979876SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret i32 undef
44ab979876SSimon Pilgrim;
45ab979876SSimon Pilgrim; AVX512-LABEL: 'insert_double'
465db826e4SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v2f64_a = insertelement <2 x double> undef, double undef, i32 %arg
47ab979876SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %v2f64_0 = insertelement <2 x double> undef, double undef, i32 0
48ab979876SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v2f64_1 = insertelement <2 x double> undef, double undef, i32 1
495db826e4SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v4f64_a = insertelement <4 x double> undef, double undef, i32 %arg
50ab979876SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %v4f64_0 = insertelement <4 x double> undef, double undef, i32 0
51168a44a7SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v4f64_3 = insertelement <4 x double> undef, double undef, i32 3
525db826e4SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v8f64_a = insertelement <8 x double> undef, double undef, i32 %arg
53ab979876SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %v8f64_0 = insertelement <8 x double> undef, double undef, i32 0
54168a44a7SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v8f64_3 = insertelement <8 x double> undef, double undef, i32 3
55168a44a7SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %v8f64_4 = insertelement <8 x double> undef, double undef, i32 4
56168a44a7SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v8f64_7 = insertelement <8 x double> undef, double undef, i32 7
57ab979876SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret i32 undef
58ab979876SSimon Pilgrim;
59d7ac2553SSimon Pilgrim  %v2f64_a = insertelement <2 x double> undef, double undef, i32 %arg
60ab979876SSimon Pilgrim  %v2f64_0 = insertelement <2 x double> undef, double undef, i32 0
61ab979876SSimon Pilgrim  %v2f64_1 = insertelement <2 x double> undef, double undef, i32 1
62ab979876SSimon Pilgrim
63d7ac2553SSimon Pilgrim  %v4f64_a = insertelement <4 x double> undef, double undef, i32 %arg
64ab979876SSimon Pilgrim  %v4f64_0 = insertelement <4 x double> undef, double undef, i32 0
65ab979876SSimon Pilgrim  %v4f64_3 = insertelement <4 x double> undef, double undef, i32 3
66ab979876SSimon Pilgrim
67d7ac2553SSimon Pilgrim  %v8f64_a = insertelement <8 x double> undef, double undef, i32 %arg
68ab979876SSimon Pilgrim  %v8f64_0 = insertelement <8 x double> undef, double undef, i32 0
69ab979876SSimon Pilgrim  %v8f64_3 = insertelement <8 x double> undef, double undef, i32 3
70ab979876SSimon Pilgrim  %v8f64_4 = insertelement <8 x double> undef, double undef, i32 4
71ab979876SSimon Pilgrim  %v8f64_7 = insertelement <8 x double> undef, double undef, i32 7
72ab979876SSimon Pilgrim
73ab979876SSimon Pilgrim  ret i32 undef
74ab979876SSimon Pilgrim}
75ab979876SSimon Pilgrim
76ab979876SSimon Pilgrimdefine i32 @insert_float(i32 %arg) {
77168a44a7SSimon Pilgrim; SSE2-LABEL: 'insert_float'
785db826e4SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v2f32_a = insertelement <2 x float> undef, float undef, i32 %arg
79168a44a7SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %v2f32_0 = insertelement <2 x float> undef, float undef, i32 0
80168a44a7SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %v2f32_1 = insertelement <2 x float> undef, float undef, i32 1
815db826e4SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v4f32_a = insertelement <4 x float> undef, float undef, i32 %arg
82168a44a7SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %v4f32_0 = insertelement <4 x float> undef, float undef, i32 0
83168a44a7SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %v4f32_3 = insertelement <4 x float> undef, float undef, i32 3
845db826e4SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %v8f32_a = insertelement <8 x float> undef, float undef, i32 %arg
85168a44a7SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %v8f32_0 = insertelement <8 x float> undef, float undef, i32 0
86168a44a7SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %v8f32_3 = insertelement <8 x float> undef, float undef, i32 3
87168a44a7SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %v8f32_4 = insertelement <8 x float> undef, float undef, i32 4
88168a44a7SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %v8f32_7 = insertelement <8 x float> undef, float undef, i32 7
895db826e4SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 9 for instruction: %v16f32_a = insertelement <16 x float> undef, float undef, i32 %arg
90168a44a7SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %v16f32_0 = insertelement <16 x float> undef, float undef, i32 0
91168a44a7SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %v16f32_3 = insertelement <16 x float> undef, float undef, i32 3
92168a44a7SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %v16f32_8 = insertelement <16 x float> undef, float undef, i32 8
93168a44a7SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %v16f32_15 = insertelement <16 x float> undef, float undef, i32 15
94168a44a7SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret i32 undef
95168a44a7SSimon Pilgrim;
96168a44a7SSimon Pilgrim; SSE3-LABEL: 'insert_float'
975db826e4SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v2f32_a = insertelement <2 x float> undef, float undef, i32 %arg
98168a44a7SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %v2f32_0 = insertelement <2 x float> undef, float undef, i32 0
99168a44a7SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %v2f32_1 = insertelement <2 x float> undef, float undef, i32 1
1005db826e4SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v4f32_a = insertelement <4 x float> undef, float undef, i32 %arg
101168a44a7SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %v4f32_0 = insertelement <4 x float> undef, float undef, i32 0
102168a44a7SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %v4f32_3 = insertelement <4 x float> undef, float undef, i32 3
1035db826e4SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %v8f32_a = insertelement <8 x float> undef, float undef, i32 %arg
104168a44a7SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %v8f32_0 = insertelement <8 x float> undef, float undef, i32 0
105168a44a7SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %v8f32_3 = insertelement <8 x float> undef, float undef, i32 3
106168a44a7SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %v8f32_4 = insertelement <8 x float> undef, float undef, i32 4
107168a44a7SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %v8f32_7 = insertelement <8 x float> undef, float undef, i32 7
1085db826e4SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 9 for instruction: %v16f32_a = insertelement <16 x float> undef, float undef, i32 %arg
109168a44a7SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %v16f32_0 = insertelement <16 x float> undef, float undef, i32 0
110168a44a7SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %v16f32_3 = insertelement <16 x float> undef, float undef, i32 3
111168a44a7SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %v16f32_8 = insertelement <16 x float> undef, float undef, i32 8
112168a44a7SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %v16f32_15 = insertelement <16 x float> undef, float undef, i32 15
113168a44a7SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret i32 undef
114168a44a7SSimon Pilgrim;
115168a44a7SSimon Pilgrim; SSSE3-LABEL: 'insert_float'
1165db826e4SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v2f32_a = insertelement <2 x float> undef, float undef, i32 %arg
117168a44a7SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %v2f32_0 = insertelement <2 x float> undef, float undef, i32 0
118168a44a7SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %v2f32_1 = insertelement <2 x float> undef, float undef, i32 1
1195db826e4SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v4f32_a = insertelement <4 x float> undef, float undef, i32 %arg
120168a44a7SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %v4f32_0 = insertelement <4 x float> undef, float undef, i32 0
121168a44a7SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %v4f32_3 = insertelement <4 x float> undef, float undef, i32 3
1225db826e4SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %v8f32_a = insertelement <8 x float> undef, float undef, i32 %arg
123168a44a7SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %v8f32_0 = insertelement <8 x float> undef, float undef, i32 0
124168a44a7SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %v8f32_3 = insertelement <8 x float> undef, float undef, i32 3
125168a44a7SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %v8f32_4 = insertelement <8 x float> undef, float undef, i32 4
126168a44a7SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %v8f32_7 = insertelement <8 x float> undef, float undef, i32 7
1275db826e4SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 9 for instruction: %v16f32_a = insertelement <16 x float> undef, float undef, i32 %arg
128168a44a7SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %v16f32_0 = insertelement <16 x float> undef, float undef, i32 0
129168a44a7SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %v16f32_3 = insertelement <16 x float> undef, float undef, i32 3
130168a44a7SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %v16f32_8 = insertelement <16 x float> undef, float undef, i32 8
131168a44a7SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %v16f32_15 = insertelement <16 x float> undef, float undef, i32 15
132168a44a7SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret i32 undef
133168a44a7SSimon Pilgrim;
134168a44a7SSimon Pilgrim; SSE4-LABEL: 'insert_float'
1355db826e4SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v2f32_a = insertelement <2 x float> undef, float undef, i32 %arg
136168a44a7SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %v2f32_0 = insertelement <2 x float> undef, float undef, i32 0
137168a44a7SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v2f32_1 = insertelement <2 x float> undef, float undef, i32 1
1385db826e4SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v4f32_a = insertelement <4 x float> undef, float undef, i32 %arg
139168a44a7SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %v4f32_0 = insertelement <4 x float> undef, float undef, i32 0
140168a44a7SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v4f32_3 = insertelement <4 x float> undef, float undef, i32 3
1415db826e4SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %v8f32_a = insertelement <8 x float> undef, float undef, i32 %arg
142168a44a7SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %v8f32_0 = insertelement <8 x float> undef, float undef, i32 0
143168a44a7SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8f32_3 = insertelement <8 x float> undef, float undef, i32 3
144168a44a7SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %v8f32_4 = insertelement <8 x float> undef, float undef, i32 4
145168a44a7SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8f32_7 = insertelement <8 x float> undef, float undef, i32 7
1465db826e4SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 9 for instruction: %v16f32_a = insertelement <16 x float> undef, float undef, i32 %arg
147168a44a7SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %v16f32_0 = insertelement <16 x float> undef, float undef, i32 0
148168a44a7SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16f32_3 = insertelement <16 x float> undef, float undef, i32 3
149168a44a7SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %v16f32_8 = insertelement <16 x float> undef, float undef, i32 8
150168a44a7SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16f32_15 = insertelement <16 x float> undef, float undef, i32 15
151168a44a7SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret i32 undef
152ab979876SSimon Pilgrim;
153ab979876SSimon Pilgrim; AVX-LABEL: 'insert_float'
1545db826e4SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v2f32_a = insertelement <2 x float> undef, float undef, i32 %arg
155ab979876SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %v2f32_0 = insertelement <2 x float> undef, float undef, i32 0
156ab979876SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v2f32_1 = insertelement <2 x float> undef, float undef, i32 1
1575db826e4SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v4f32_a = insertelement <4 x float> undef, float undef, i32 %arg
158ab979876SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %v4f32_0 = insertelement <4 x float> undef, float undef, i32 0
159ab979876SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v4f32_3 = insertelement <4 x float> undef, float undef, i32 3
1605db826e4SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v8f32_a = insertelement <8 x float> undef, float undef, i32 %arg
161ab979876SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %v8f32_0 = insertelement <8 x float> undef, float undef, i32 0
162ab979876SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8f32_3 = insertelement <8 x float> undef, float undef, i32 3
163168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %v8f32_4 = insertelement <8 x float> undef, float undef, i32 4
164168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v8f32_7 = insertelement <8 x float> undef, float undef, i32 7
1655db826e4SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %v16f32_a = insertelement <16 x float> undef, float undef, i32 %arg
166ab979876SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %v16f32_0 = insertelement <16 x float> undef, float undef, i32 0
167ab979876SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16f32_3 = insertelement <16 x float> undef, float undef, i32 3
168ab979876SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %v16f32_8 = insertelement <16 x float> undef, float undef, i32 8
169168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v16f32_15 = insertelement <16 x float> undef, float undef, i32 15
170ab979876SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret i32 undef
171ab979876SSimon Pilgrim;
172ab979876SSimon Pilgrim; AVX512-LABEL: 'insert_float'
1735db826e4SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v2f32_a = insertelement <2 x float> undef, float undef, i32 %arg
174ab979876SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %v2f32_0 = insertelement <2 x float> undef, float undef, i32 0
175ab979876SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v2f32_1 = insertelement <2 x float> undef, float undef, i32 1
1765db826e4SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v4f32_a = insertelement <4 x float> undef, float undef, i32 %arg
177ab979876SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %v4f32_0 = insertelement <4 x float> undef, float undef, i32 0
178ab979876SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v4f32_3 = insertelement <4 x float> undef, float undef, i32 3
1795db826e4SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v8f32_a = insertelement <8 x float> undef, float undef, i32 %arg
180ab979876SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %v8f32_0 = insertelement <8 x float> undef, float undef, i32 0
181ab979876SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8f32_3 = insertelement <8 x float> undef, float undef, i32 3
182168a44a7SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %v8f32_4 = insertelement <8 x float> undef, float undef, i32 4
183168a44a7SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v8f32_7 = insertelement <8 x float> undef, float undef, i32 7
1845db826e4SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v16f32_a = insertelement <16 x float> undef, float undef, i32 %arg
185ab979876SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %v16f32_0 = insertelement <16 x float> undef, float undef, i32 0
186ab979876SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16f32_3 = insertelement <16 x float> undef, float undef, i32 3
187168a44a7SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %v16f32_8 = insertelement <16 x float> undef, float undef, i32 8
188168a44a7SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v16f32_15 = insertelement <16 x float> undef, float undef, i32 15
189ab979876SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret i32 undef
190ab979876SSimon Pilgrim;
191168a44a7SSimon Pilgrim; SLM-LABEL: 'insert_float'
1925db826e4SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v2f32_a = insertelement <2 x float> undef, float undef, i32 %arg
193168a44a7SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %v2f32_0 = insertelement <2 x float> undef, float undef, i32 0
194168a44a7SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v2f32_1 = insertelement <2 x float> undef, float undef, i32 1
1955db826e4SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v4f32_a = insertelement <4 x float> undef, float undef, i32 %arg
196168a44a7SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %v4f32_0 = insertelement <4 x float> undef, float undef, i32 0
197168a44a7SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v4f32_3 = insertelement <4 x float> undef, float undef, i32 3
1985db826e4SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %v8f32_a = insertelement <8 x float> undef, float undef, i32 %arg
199168a44a7SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %v8f32_0 = insertelement <8 x float> undef, float undef, i32 0
200168a44a7SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8f32_3 = insertelement <8 x float> undef, float undef, i32 3
201168a44a7SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %v8f32_4 = insertelement <8 x float> undef, float undef, i32 4
202168a44a7SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8f32_7 = insertelement <8 x float> undef, float undef, i32 7
2035db826e4SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 9 for instruction: %v16f32_a = insertelement <16 x float> undef, float undef, i32 %arg
204168a44a7SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %v16f32_0 = insertelement <16 x float> undef, float undef, i32 0
205168a44a7SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16f32_3 = insertelement <16 x float> undef, float undef, i32 3
206168a44a7SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %v16f32_8 = insertelement <16 x float> undef, float undef, i32 8
207168a44a7SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16f32_15 = insertelement <16 x float> undef, float undef, i32 15
208168a44a7SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret i32 undef
209168a44a7SSimon Pilgrim;
210168a44a7SSimon Pilgrim; GLM-LABEL: 'insert_float'
2115db826e4SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v2f32_a = insertelement <2 x float> undef, float undef, i32 %arg
212168a44a7SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %v2f32_0 = insertelement <2 x float> undef, float undef, i32 0
213168a44a7SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v2f32_1 = insertelement <2 x float> undef, float undef, i32 1
2145db826e4SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v4f32_a = insertelement <4 x float> undef, float undef, i32 %arg
215168a44a7SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %v4f32_0 = insertelement <4 x float> undef, float undef, i32 0
216168a44a7SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v4f32_3 = insertelement <4 x float> undef, float undef, i32 3
2175db826e4SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %v8f32_a = insertelement <8 x float> undef, float undef, i32 %arg
218168a44a7SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %v8f32_0 = insertelement <8 x float> undef, float undef, i32 0
219168a44a7SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8f32_3 = insertelement <8 x float> undef, float undef, i32 3
220168a44a7SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %v8f32_4 = insertelement <8 x float> undef, float undef, i32 4
221168a44a7SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8f32_7 = insertelement <8 x float> undef, float undef, i32 7
2225db826e4SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 9 for instruction: %v16f32_a = insertelement <16 x float> undef, float undef, i32 %arg
223168a44a7SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %v16f32_0 = insertelement <16 x float> undef, float undef, i32 0
224168a44a7SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16f32_3 = insertelement <16 x float> undef, float undef, i32 3
225168a44a7SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: %v16f32_8 = insertelement <16 x float> undef, float undef, i32 8
226168a44a7SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16f32_15 = insertelement <16 x float> undef, float undef, i32 15
227168a44a7SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret i32 undef
228168a44a7SSimon Pilgrim;
229d7ac2553SSimon Pilgrim  %v2f32_a = insertelement <2 x float> undef, float undef, i32 %arg
230ab979876SSimon Pilgrim  %v2f32_0 = insertelement <2 x float> undef, float undef, i32 0
231ab979876SSimon Pilgrim  %v2f32_1 = insertelement <2 x float> undef, float undef, i32 1
232ab979876SSimon Pilgrim
233d7ac2553SSimon Pilgrim  %v4f32_a = insertelement <4 x float> undef, float undef, i32 %arg
234ab979876SSimon Pilgrim  %v4f32_0 = insertelement <4 x float> undef, float undef, i32 0
235ab979876SSimon Pilgrim  %v4f32_3 = insertelement <4 x float> undef, float undef, i32 3
236ab979876SSimon Pilgrim
237d7ac2553SSimon Pilgrim  %v8f32_a = insertelement <8 x float> undef, float undef, i32 %arg
238ab979876SSimon Pilgrim  %v8f32_0 = insertelement <8 x float> undef, float undef, i32 0
239ab979876SSimon Pilgrim  %v8f32_3 = insertelement <8 x float> undef, float undef, i32 3
240ab979876SSimon Pilgrim  %v8f32_4 = insertelement <8 x float> undef, float undef, i32 4
241ab979876SSimon Pilgrim  %v8f32_7 = insertelement <8 x float> undef, float undef, i32 7
242ab979876SSimon Pilgrim
243d7ac2553SSimon Pilgrim  %v16f32_a  = insertelement <16 x float> undef, float undef, i32 %arg
244ab979876SSimon Pilgrim  %v16f32_0  = insertelement <16 x float> undef, float undef, i32 0
245ab979876SSimon Pilgrim  %v16f32_3  = insertelement <16 x float> undef, float undef, i32 3
246ab979876SSimon Pilgrim  %v16f32_8  = insertelement <16 x float> undef, float undef, i32 8
247ab979876SSimon Pilgrim  %v16f32_15 = insertelement <16 x float> undef, float undef, i32 15
248ab979876SSimon Pilgrim
249ab979876SSimon Pilgrim  ret i32 undef
250ab979876SSimon Pilgrim}
251ab979876SSimon Pilgrim
252ab979876SSimon Pilgrimdefine i32 @insert_i64(i32 %arg) {
253168a44a7SSimon Pilgrim; SSE2-LABEL: 'insert_i64'
2545db826e4SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v2i64_a = insertelement <2 x i64> undef, i64 undef, i32 %arg
255168a44a7SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %v2i64_0 = insertelement <2 x i64> undef, i64 undef, i32 0
256168a44a7SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %v2i64_1 = insertelement <2 x i64> undef, i64 undef, i32 1
2575db826e4SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %v4i64_a = insertelement <4 x i64> undef, i64 undef, i32 %arg
258168a44a7SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %v4i64_0 = insertelement <4 x i64> undef, i64 undef, i32 0
259168a44a7SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %v4i64_3 = insertelement <4 x i64> undef, i64 undef, i32 3
2605db826e4SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 9 for instruction: %v8i64_a = insertelement <8 x i64> undef, i64 undef, i32 %arg
261168a44a7SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %v8i64_0 = insertelement <8 x i64> undef, i64 undef, i32 0
262168a44a7SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %v8i64_3 = insertelement <8 x i64> undef, i64 undef, i32 3
263168a44a7SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %v8i64_4 = insertelement <8 x i64> undef, i64 undef, i32 4
264168a44a7SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %v8i64_7 = insertelement <8 x i64> undef, i64 undef, i32 7
265168a44a7SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret i32 undef
266168a44a7SSimon Pilgrim;
267168a44a7SSimon Pilgrim; SSE3-LABEL: 'insert_i64'
2685db826e4SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v2i64_a = insertelement <2 x i64> undef, i64 undef, i32 %arg
269168a44a7SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %v2i64_0 = insertelement <2 x i64> undef, i64 undef, i32 0
270168a44a7SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %v2i64_1 = insertelement <2 x i64> undef, i64 undef, i32 1
2715db826e4SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %v4i64_a = insertelement <4 x i64> undef, i64 undef, i32 %arg
272168a44a7SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %v4i64_0 = insertelement <4 x i64> undef, i64 undef, i32 0
273168a44a7SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %v4i64_3 = insertelement <4 x i64> undef, i64 undef, i32 3
2745db826e4SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 9 for instruction: %v8i64_a = insertelement <8 x i64> undef, i64 undef, i32 %arg
275168a44a7SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %v8i64_0 = insertelement <8 x i64> undef, i64 undef, i32 0
276168a44a7SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %v8i64_3 = insertelement <8 x i64> undef, i64 undef, i32 3
277168a44a7SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %v8i64_4 = insertelement <8 x i64> undef, i64 undef, i32 4
278168a44a7SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %v8i64_7 = insertelement <8 x i64> undef, i64 undef, i32 7
279168a44a7SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret i32 undef
280168a44a7SSimon Pilgrim;
281168a44a7SSimon Pilgrim; SSSE3-LABEL: 'insert_i64'
2825db826e4SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v2i64_a = insertelement <2 x i64> undef, i64 undef, i32 %arg
283168a44a7SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %v2i64_0 = insertelement <2 x i64> undef, i64 undef, i32 0
284168a44a7SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %v2i64_1 = insertelement <2 x i64> undef, i64 undef, i32 1
2855db826e4SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %v4i64_a = insertelement <4 x i64> undef, i64 undef, i32 %arg
286168a44a7SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %v4i64_0 = insertelement <4 x i64> undef, i64 undef, i32 0
287168a44a7SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %v4i64_3 = insertelement <4 x i64> undef, i64 undef, i32 3
2885db826e4SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 9 for instruction: %v8i64_a = insertelement <8 x i64> undef, i64 undef, i32 %arg
289168a44a7SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %v8i64_0 = insertelement <8 x i64> undef, i64 undef, i32 0
290168a44a7SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %v8i64_3 = insertelement <8 x i64> undef, i64 undef, i32 3
291168a44a7SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %v8i64_4 = insertelement <8 x i64> undef, i64 undef, i32 4
292168a44a7SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %v8i64_7 = insertelement <8 x i64> undef, i64 undef, i32 7
293168a44a7SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret i32 undef
294168a44a7SSimon Pilgrim;
295168a44a7SSimon Pilgrim; SSE4-LABEL: 'insert_i64'
2965db826e4SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v2i64_a = insertelement <2 x i64> undef, i64 undef, i32 %arg
297168a44a7SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v2i64_0 = insertelement <2 x i64> undef, i64 undef, i32 0
298168a44a7SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v2i64_1 = insertelement <2 x i64> undef, i64 undef, i32 1
2995db826e4SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %v4i64_a = insertelement <4 x i64> undef, i64 undef, i32 %arg
300168a44a7SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v4i64_0 = insertelement <4 x i64> undef, i64 undef, i32 0
301168a44a7SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v4i64_3 = insertelement <4 x i64> undef, i64 undef, i32 3
3025db826e4SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 9 for instruction: %v8i64_a = insertelement <8 x i64> undef, i64 undef, i32 %arg
303168a44a7SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i64_0 = insertelement <8 x i64> undef, i64 undef, i32 0
304168a44a7SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i64_3 = insertelement <8 x i64> undef, i64 undef, i32 3
305168a44a7SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i64_4 = insertelement <8 x i64> undef, i64 undef, i32 4
306168a44a7SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i64_7 = insertelement <8 x i64> undef, i64 undef, i32 7
307168a44a7SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret i32 undef
308168a44a7SSimon Pilgrim;
309168a44a7SSimon Pilgrim; AVX-LABEL: 'insert_i64'
3105db826e4SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v2i64_a = insertelement <2 x i64> undef, i64 undef, i32 %arg
311168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v2i64_0 = insertelement <2 x i64> undef, i64 undef, i32 0
312168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v2i64_1 = insertelement <2 x i64> undef, i64 undef, i32 1
3135db826e4SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v4i64_a = insertelement <4 x i64> undef, i64 undef, i32 %arg
314168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v4i64_0 = insertelement <4 x i64> undef, i64 undef, i32 0
315168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v4i64_3 = insertelement <4 x i64> undef, i64 undef, i32 3
3165db826e4SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %v8i64_a = insertelement <8 x i64> undef, i64 undef, i32 %arg
317168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i64_0 = insertelement <8 x i64> undef, i64 undef, i32 0
318168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v8i64_3 = insertelement <8 x i64> undef, i64 undef, i32 3
319168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i64_4 = insertelement <8 x i64> undef, i64 undef, i32 4
320168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v8i64_7 = insertelement <8 x i64> undef, i64 undef, i32 7
321168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret i32 undef
322168a44a7SSimon Pilgrim;
323168a44a7SSimon Pilgrim; AVX512-LABEL: 'insert_i64'
3245db826e4SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v2i64_a = insertelement <2 x i64> undef, i64 undef, i32 %arg
325168a44a7SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v2i64_0 = insertelement <2 x i64> undef, i64 undef, i32 0
326168a44a7SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v2i64_1 = insertelement <2 x i64> undef, i64 undef, i32 1
3275db826e4SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v4i64_a = insertelement <4 x i64> undef, i64 undef, i32 %arg
328168a44a7SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v4i64_0 = insertelement <4 x i64> undef, i64 undef, i32 0
329168a44a7SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v4i64_3 = insertelement <4 x i64> undef, i64 undef, i32 3
3305db826e4SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v8i64_a = insertelement <8 x i64> undef, i64 undef, i32 %arg
331168a44a7SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i64_0 = insertelement <8 x i64> undef, i64 undef, i32 0
332168a44a7SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v8i64_3 = insertelement <8 x i64> undef, i64 undef, i32 3
333168a44a7SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v8i64_4 = insertelement <8 x i64> undef, i64 undef, i32 4
334168a44a7SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v8i64_7 = insertelement <8 x i64> undef, i64 undef, i32 7
335168a44a7SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret i32 undef
336168a44a7SSimon Pilgrim;
337168a44a7SSimon Pilgrim; SLM-LABEL: 'insert_i64'
3385db826e4SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v2i64_a = insertelement <2 x i64> undef, i64 undef, i32 %arg
339168a44a7SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v2i64_0 = insertelement <2 x i64> undef, i64 undef, i32 0
340168a44a7SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v2i64_1 = insertelement <2 x i64> undef, i64 undef, i32 1
3415db826e4SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %v4i64_a = insertelement <4 x i64> undef, i64 undef, i32 %arg
342168a44a7SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v4i64_0 = insertelement <4 x i64> undef, i64 undef, i32 0
343168a44a7SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v4i64_3 = insertelement <4 x i64> undef, i64 undef, i32 3
3445db826e4SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 9 for instruction: %v8i64_a = insertelement <8 x i64> undef, i64 undef, i32 %arg
345168a44a7SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i64_0 = insertelement <8 x i64> undef, i64 undef, i32 0
346168a44a7SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i64_3 = insertelement <8 x i64> undef, i64 undef, i32 3
347168a44a7SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i64_4 = insertelement <8 x i64> undef, i64 undef, i32 4
348168a44a7SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i64_7 = insertelement <8 x i64> undef, i64 undef, i32 7
349168a44a7SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret i32 undef
350168a44a7SSimon Pilgrim;
351168a44a7SSimon Pilgrim; GLM-LABEL: 'insert_i64'
3525db826e4SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v2i64_a = insertelement <2 x i64> undef, i64 undef, i32 %arg
353168a44a7SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v2i64_0 = insertelement <2 x i64> undef, i64 undef, i32 0
354168a44a7SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v2i64_1 = insertelement <2 x i64> undef, i64 undef, i32 1
3555db826e4SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %v4i64_a = insertelement <4 x i64> undef, i64 undef, i32 %arg
356168a44a7SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v4i64_0 = insertelement <4 x i64> undef, i64 undef, i32 0
357168a44a7SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v4i64_3 = insertelement <4 x i64> undef, i64 undef, i32 3
3585db826e4SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 9 for instruction: %v8i64_a = insertelement <8 x i64> undef, i64 undef, i32 %arg
359168a44a7SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i64_0 = insertelement <8 x i64> undef, i64 undef, i32 0
360168a44a7SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i64_3 = insertelement <8 x i64> undef, i64 undef, i32 3
361168a44a7SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i64_4 = insertelement <8 x i64> undef, i64 undef, i32 4
362168a44a7SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i64_7 = insertelement <8 x i64> undef, i64 undef, i32 7
363168a44a7SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret i32 undef
364ab979876SSimon Pilgrim;
365d7ac2553SSimon Pilgrim  %v2i64_a = insertelement <2 x i64> undef, i64 undef, i32 %arg
366ab979876SSimon Pilgrim  %v2i64_0 = insertelement <2 x i64> undef, i64 undef, i32 0
367ab979876SSimon Pilgrim  %v2i64_1 = insertelement <2 x i64> undef, i64 undef, i32 1
368ab979876SSimon Pilgrim
369d7ac2553SSimon Pilgrim  %v4i64_a = insertelement <4 x i64> undef, i64 undef, i32 %arg
370ab979876SSimon Pilgrim  %v4i64_0 = insertelement <4 x i64> undef, i64 undef, i32 0
371ab979876SSimon Pilgrim  %v4i64_3 = insertelement <4 x i64> undef, i64 undef, i32 3
372ab979876SSimon Pilgrim
373d7ac2553SSimon Pilgrim  %v8i64_a = insertelement <8 x i64> undef, i64 undef, i32 %arg
374ab979876SSimon Pilgrim  %v8i64_0 = insertelement <8 x i64> undef, i64 undef, i32 0
375ab979876SSimon Pilgrim  %v8i64_3 = insertelement <8 x i64> undef, i64 undef, i32 3
376ab979876SSimon Pilgrim  %v8i64_4 = insertelement <8 x i64> undef, i64 undef, i32 4
377ab979876SSimon Pilgrim  %v8i64_7 = insertelement <8 x i64> undef, i64 undef, i32 7
378ab979876SSimon Pilgrim
379ab979876SSimon Pilgrim  ret i32 undef
380ab979876SSimon Pilgrim}
381ab979876SSimon Pilgrim
382ab979876SSimon Pilgrimdefine i32 @insert_i32(i32 %arg) {
383168a44a7SSimon Pilgrim; SSE2-LABEL: 'insert_i32'
3845db826e4SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v2i32_a = insertelement <2 x i32> undef, i32 undef, i32 %arg
385168a44a7SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v2i32_0 = insertelement <2 x i32> undef, i32 undef, i32 0
386168a44a7SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v2i32_1 = insertelement <2 x i32> undef, i32 undef, i32 1
3875db826e4SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v4i32_a = insertelement <4 x i32> undef, i32 undef, i32 %arg
388168a44a7SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v4i32_0 = insertelement <4 x i32> undef, i32 undef, i32 0
389168a44a7SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v4i32_3 = insertelement <4 x i32> undef, i32 undef, i32 3
3905db826e4SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %v8i32_a = insertelement <8 x i32> undef, i32 undef, i32 %arg
391168a44a7SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v8i32_0 = insertelement <8 x i32> undef, i32 undef, i32 0
392168a44a7SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v8i32_3 = insertelement <8 x i32> undef, i32 undef, i32 3
393168a44a7SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v8i32_4 = insertelement <8 x i32> undef, i32 undef, i32 4
394168a44a7SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v8i32_7 = insertelement <8 x i32> undef, i32 undef, i32 7
3955db826e4SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 9 for instruction: %v16i32_a = insertelement <16 x i32> undef, i32 undef, i32 %arg
396168a44a7SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v16i32_0 = insertelement <16 x i32> undef, i32 undef, i32 0
397168a44a7SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v16i32_3 = insertelement <16 x i32> undef, i32 undef, i32 3
398168a44a7SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v16i32_8 = insertelement <16 x i32> undef, i32 undef, i32 8
399168a44a7SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v16i32_15 = insertelement <16 x i32> undef, i32 undef, i32 15
400168a44a7SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret i32 undef
401168a44a7SSimon Pilgrim;
402168a44a7SSimon Pilgrim; SSE3-LABEL: 'insert_i32'
4035db826e4SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v2i32_a = insertelement <2 x i32> undef, i32 undef, i32 %arg
404168a44a7SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v2i32_0 = insertelement <2 x i32> undef, i32 undef, i32 0
405168a44a7SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v2i32_1 = insertelement <2 x i32> undef, i32 undef, i32 1
4065db826e4SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v4i32_a = insertelement <4 x i32> undef, i32 undef, i32 %arg
407168a44a7SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v4i32_0 = insertelement <4 x i32> undef, i32 undef, i32 0
408168a44a7SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v4i32_3 = insertelement <4 x i32> undef, i32 undef, i32 3
4095db826e4SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %v8i32_a = insertelement <8 x i32> undef, i32 undef, i32 %arg
410168a44a7SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v8i32_0 = insertelement <8 x i32> undef, i32 undef, i32 0
411168a44a7SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v8i32_3 = insertelement <8 x i32> undef, i32 undef, i32 3
412168a44a7SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v8i32_4 = insertelement <8 x i32> undef, i32 undef, i32 4
413168a44a7SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v8i32_7 = insertelement <8 x i32> undef, i32 undef, i32 7
4145db826e4SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 9 for instruction: %v16i32_a = insertelement <16 x i32> undef, i32 undef, i32 %arg
415168a44a7SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v16i32_0 = insertelement <16 x i32> undef, i32 undef, i32 0
416168a44a7SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v16i32_3 = insertelement <16 x i32> undef, i32 undef, i32 3
417168a44a7SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v16i32_8 = insertelement <16 x i32> undef, i32 undef, i32 8
418168a44a7SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v16i32_15 = insertelement <16 x i32> undef, i32 undef, i32 15
419168a44a7SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret i32 undef
420168a44a7SSimon Pilgrim;
421168a44a7SSimon Pilgrim; SSSE3-LABEL: 'insert_i32'
4225db826e4SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v2i32_a = insertelement <2 x i32> undef, i32 undef, i32 %arg
423168a44a7SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v2i32_0 = insertelement <2 x i32> undef, i32 undef, i32 0
424168a44a7SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v2i32_1 = insertelement <2 x i32> undef, i32 undef, i32 1
4255db826e4SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v4i32_a = insertelement <4 x i32> undef, i32 undef, i32 %arg
426168a44a7SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v4i32_0 = insertelement <4 x i32> undef, i32 undef, i32 0
427168a44a7SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v4i32_3 = insertelement <4 x i32> undef, i32 undef, i32 3
4285db826e4SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %v8i32_a = insertelement <8 x i32> undef, i32 undef, i32 %arg
429168a44a7SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v8i32_0 = insertelement <8 x i32> undef, i32 undef, i32 0
430168a44a7SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v8i32_3 = insertelement <8 x i32> undef, i32 undef, i32 3
431168a44a7SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v8i32_4 = insertelement <8 x i32> undef, i32 undef, i32 4
432168a44a7SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v8i32_7 = insertelement <8 x i32> undef, i32 undef, i32 7
4335db826e4SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 9 for instruction: %v16i32_a = insertelement <16 x i32> undef, i32 undef, i32 %arg
434168a44a7SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v16i32_0 = insertelement <16 x i32> undef, i32 undef, i32 0
435168a44a7SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v16i32_3 = insertelement <16 x i32> undef, i32 undef, i32 3
436168a44a7SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v16i32_8 = insertelement <16 x i32> undef, i32 undef, i32 8
437168a44a7SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v16i32_15 = insertelement <16 x i32> undef, i32 undef, i32 15
438168a44a7SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret i32 undef
439168a44a7SSimon Pilgrim;
440168a44a7SSimon Pilgrim; SSE4-LABEL: 'insert_i32'
4415db826e4SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v2i32_a = insertelement <2 x i32> undef, i32 undef, i32 %arg
442168a44a7SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v2i32_0 = insertelement <2 x i32> undef, i32 undef, i32 0
443168a44a7SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v2i32_1 = insertelement <2 x i32> undef, i32 undef, i32 1
4445db826e4SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v4i32_a = insertelement <4 x i32> undef, i32 undef, i32 %arg
445168a44a7SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v4i32_0 = insertelement <4 x i32> undef, i32 undef, i32 0
446168a44a7SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v4i32_3 = insertelement <4 x i32> undef, i32 undef, i32 3
4475db826e4SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %v8i32_a = insertelement <8 x i32> undef, i32 undef, i32 %arg
448168a44a7SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i32_0 = insertelement <8 x i32> undef, i32 undef, i32 0
449168a44a7SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i32_3 = insertelement <8 x i32> undef, i32 undef, i32 3
450168a44a7SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i32_4 = insertelement <8 x i32> undef, i32 undef, i32 4
451168a44a7SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i32_7 = insertelement <8 x i32> undef, i32 undef, i32 7
4525db826e4SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 9 for instruction: %v16i32_a = insertelement <16 x i32> undef, i32 undef, i32 %arg
453168a44a7SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16i32_0 = insertelement <16 x i32> undef, i32 undef, i32 0
454168a44a7SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16i32_3 = insertelement <16 x i32> undef, i32 undef, i32 3
455168a44a7SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16i32_8 = insertelement <16 x i32> undef, i32 undef, i32 8
456168a44a7SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16i32_15 = insertelement <16 x i32> undef, i32 undef, i32 15
457168a44a7SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret i32 undef
458168a44a7SSimon Pilgrim;
459168a44a7SSimon Pilgrim; AVX-LABEL: 'insert_i32'
4605db826e4SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v2i32_a = insertelement <2 x i32> undef, i32 undef, i32 %arg
461168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v2i32_0 = insertelement <2 x i32> undef, i32 undef, i32 0
462168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v2i32_1 = insertelement <2 x i32> undef, i32 undef, i32 1
4635db826e4SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v4i32_a = insertelement <4 x i32> undef, i32 undef, i32 %arg
464168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v4i32_0 = insertelement <4 x i32> undef, i32 undef, i32 0
465168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v4i32_3 = insertelement <4 x i32> undef, i32 undef, i32 3
4665db826e4SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v8i32_a = insertelement <8 x i32> undef, i32 undef, i32 %arg
467168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i32_0 = insertelement <8 x i32> undef, i32 undef, i32 0
468168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i32_3 = insertelement <8 x i32> undef, i32 undef, i32 3
469168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v8i32_4 = insertelement <8 x i32> undef, i32 undef, i32 4
470168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v8i32_7 = insertelement <8 x i32> undef, i32 undef, i32 7
4715db826e4SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %v16i32_a = insertelement <16 x i32> undef, i32 undef, i32 %arg
472168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16i32_0 = insertelement <16 x i32> undef, i32 undef, i32 0
473168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16i32_3 = insertelement <16 x i32> undef, i32 undef, i32 3
474168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16i32_8 = insertelement <16 x i32> undef, i32 undef, i32 8
475168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v16i32_15 = insertelement <16 x i32> undef, i32 undef, i32 15
476168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret i32 undef
477168a44a7SSimon Pilgrim;
478168a44a7SSimon Pilgrim; AVX512-LABEL: 'insert_i32'
4795db826e4SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v2i32_a = insertelement <2 x i32> undef, i32 undef, i32 %arg
480168a44a7SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v2i32_0 = insertelement <2 x i32> undef, i32 undef, i32 0
481168a44a7SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v2i32_1 = insertelement <2 x i32> undef, i32 undef, i32 1
4825db826e4SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v4i32_a = insertelement <4 x i32> undef, i32 undef, i32 %arg
483168a44a7SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v4i32_0 = insertelement <4 x i32> undef, i32 undef, i32 0
484168a44a7SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v4i32_3 = insertelement <4 x i32> undef, i32 undef, i32 3
4855db826e4SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v8i32_a = insertelement <8 x i32> undef, i32 undef, i32 %arg
486168a44a7SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i32_0 = insertelement <8 x i32> undef, i32 undef, i32 0
487168a44a7SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i32_3 = insertelement <8 x i32> undef, i32 undef, i32 3
488168a44a7SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v8i32_4 = insertelement <8 x i32> undef, i32 undef, i32 4
489168a44a7SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v8i32_7 = insertelement <8 x i32> undef, i32 undef, i32 7
4905db826e4SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v16i32_a = insertelement <16 x i32> undef, i32 undef, i32 %arg
491168a44a7SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16i32_0 = insertelement <16 x i32> undef, i32 undef, i32 0
492168a44a7SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16i32_3 = insertelement <16 x i32> undef, i32 undef, i32 3
493168a44a7SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v16i32_8 = insertelement <16 x i32> undef, i32 undef, i32 8
494168a44a7SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v16i32_15 = insertelement <16 x i32> undef, i32 undef, i32 15
495168a44a7SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret i32 undef
496168a44a7SSimon Pilgrim;
497168a44a7SSimon Pilgrim; SLM-LABEL: 'insert_i32'
4985db826e4SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v2i32_a = insertelement <2 x i32> undef, i32 undef, i32 %arg
499168a44a7SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v2i32_0 = insertelement <2 x i32> undef, i32 undef, i32 0
500168a44a7SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v2i32_1 = insertelement <2 x i32> undef, i32 undef, i32 1
5015db826e4SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v4i32_a = insertelement <4 x i32> undef, i32 undef, i32 %arg
502168a44a7SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v4i32_0 = insertelement <4 x i32> undef, i32 undef, i32 0
503168a44a7SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v4i32_3 = insertelement <4 x i32> undef, i32 undef, i32 3
5045db826e4SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %v8i32_a = insertelement <8 x i32> undef, i32 undef, i32 %arg
505168a44a7SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i32_0 = insertelement <8 x i32> undef, i32 undef, i32 0
506168a44a7SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i32_3 = insertelement <8 x i32> undef, i32 undef, i32 3
507168a44a7SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i32_4 = insertelement <8 x i32> undef, i32 undef, i32 4
508168a44a7SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i32_7 = insertelement <8 x i32> undef, i32 undef, i32 7
5095db826e4SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 9 for instruction: %v16i32_a = insertelement <16 x i32> undef, i32 undef, i32 %arg
510168a44a7SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16i32_0 = insertelement <16 x i32> undef, i32 undef, i32 0
511168a44a7SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16i32_3 = insertelement <16 x i32> undef, i32 undef, i32 3
512168a44a7SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16i32_8 = insertelement <16 x i32> undef, i32 undef, i32 8
513168a44a7SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16i32_15 = insertelement <16 x i32> undef, i32 undef, i32 15
514168a44a7SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret i32 undef
515168a44a7SSimon Pilgrim;
516168a44a7SSimon Pilgrim; GLM-LABEL: 'insert_i32'
5175db826e4SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v2i32_a = insertelement <2 x i32> undef, i32 undef, i32 %arg
518168a44a7SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v2i32_0 = insertelement <2 x i32> undef, i32 undef, i32 0
519168a44a7SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v2i32_1 = insertelement <2 x i32> undef, i32 undef, i32 1
5205db826e4SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v4i32_a = insertelement <4 x i32> undef, i32 undef, i32 %arg
521168a44a7SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v4i32_0 = insertelement <4 x i32> undef, i32 undef, i32 0
522168a44a7SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v4i32_3 = insertelement <4 x i32> undef, i32 undef, i32 3
5235db826e4SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %v8i32_a = insertelement <8 x i32> undef, i32 undef, i32 %arg
524168a44a7SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i32_0 = insertelement <8 x i32> undef, i32 undef, i32 0
525168a44a7SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i32_3 = insertelement <8 x i32> undef, i32 undef, i32 3
526168a44a7SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i32_4 = insertelement <8 x i32> undef, i32 undef, i32 4
527168a44a7SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i32_7 = insertelement <8 x i32> undef, i32 undef, i32 7
5285db826e4SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 9 for instruction: %v16i32_a = insertelement <16 x i32> undef, i32 undef, i32 %arg
529168a44a7SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16i32_0 = insertelement <16 x i32> undef, i32 undef, i32 0
530168a44a7SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16i32_3 = insertelement <16 x i32> undef, i32 undef, i32 3
531168a44a7SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16i32_8 = insertelement <16 x i32> undef, i32 undef, i32 8
532168a44a7SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16i32_15 = insertelement <16 x i32> undef, i32 undef, i32 15
533168a44a7SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret i32 undef
534ab979876SSimon Pilgrim;
535d7ac2553SSimon Pilgrim  %v2i32_a = insertelement <2 x i32> undef, i32 undef, i32 %arg
536ab979876SSimon Pilgrim  %v2i32_0 = insertelement <2 x i32> undef, i32 undef, i32 0
537ab979876SSimon Pilgrim  %v2i32_1 = insertelement <2 x i32> undef, i32 undef, i32 1
538ab979876SSimon Pilgrim
539d7ac2553SSimon Pilgrim  %v4i32_a = insertelement <4 x i32> undef, i32 undef, i32 %arg
540ab979876SSimon Pilgrim  %v4i32_0 = insertelement <4 x i32> undef, i32 undef, i32 0
541ab979876SSimon Pilgrim  %v4i32_3 = insertelement <4 x i32> undef, i32 undef, i32 3
542ab979876SSimon Pilgrim
543d7ac2553SSimon Pilgrim  %v8i32_a = insertelement <8 x i32> undef, i32 undef, i32 %arg
544ab979876SSimon Pilgrim  %v8i32_0 = insertelement <8 x i32> undef, i32 undef, i32 0
545ab979876SSimon Pilgrim  %v8i32_3 = insertelement <8 x i32> undef, i32 undef, i32 3
546ab979876SSimon Pilgrim  %v8i32_4 = insertelement <8 x i32> undef, i32 undef, i32 4
547ab979876SSimon Pilgrim  %v8i32_7 = insertelement <8 x i32> undef, i32 undef, i32 7
548ab979876SSimon Pilgrim
549d7ac2553SSimon Pilgrim  %v16i32_a  = insertelement <16 x i32> undef, i32 undef, i32 %arg
550ab979876SSimon Pilgrim  %v16i32_0  = insertelement <16 x i32> undef, i32 undef, i32 0
551ab979876SSimon Pilgrim  %v16i32_3  = insertelement <16 x i32> undef, i32 undef, i32 3
552ab979876SSimon Pilgrim  %v16i32_8  = insertelement <16 x i32> undef, i32 undef, i32 8
553ab979876SSimon Pilgrim  %v16i32_15 = insertelement <16 x i32> undef, i32 undef, i32 15
554ab979876SSimon Pilgrim
555ab979876SSimon Pilgrim  ret i32 undef
556ab979876SSimon Pilgrim}
557ab979876SSimon Pilgrim
558ab979876SSimon Pilgrimdefine i32 @insert_i16(i32 %arg) {
559168a44a7SSimon Pilgrim; SSE-LABEL: 'insert_i16'
5605db826e4SSimon Pilgrim; SSE-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v2i16_a = insertelement <2 x i16> undef, i16 undef, i32 %arg
56187fd686fSSimon Pilgrim; SSE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v2i16_0 = insertelement <2 x i16> undef, i16 undef, i32 0
56287fd686fSSimon Pilgrim; SSE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v2i16_1 = insertelement <2 x i16> undef, i16 undef, i32 1
5635db826e4SSimon Pilgrim; SSE-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v4i16_a = insertelement <4 x i16> undef, i16 undef, i32 %arg
56487fd686fSSimon Pilgrim; SSE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v4i16_0 = insertelement <4 x i16> undef, i16 undef, i32 0
56587fd686fSSimon Pilgrim; SSE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v4i16_3 = insertelement <4 x i16> undef, i16 undef, i32 3
5665db826e4SSimon Pilgrim; SSE-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v8i16_a = insertelement <8 x i16> undef, i16 undef, i32 %arg
567168a44a7SSimon Pilgrim; SSE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i16_0 = insertelement <8 x i16> undef, i16 undef, i32 0
568168a44a7SSimon Pilgrim; SSE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i16_7 = insertelement <8 x i16> undef, i16 undef, i32 7
5695db826e4SSimon Pilgrim; SSE-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %v16i16_a = insertelement <16 x i16> undef, i16 undef, i32 %arg
570168a44a7SSimon Pilgrim; SSE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16i16_0 = insertelement <16 x i16> undef, i16 undef, i32 0
571168a44a7SSimon Pilgrim; SSE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16i16_7 = insertelement <16 x i16> undef, i16 undef, i32 7
572168a44a7SSimon Pilgrim; SSE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16i16_8 = insertelement <16 x i16> undef, i16 undef, i32 8
573168a44a7SSimon Pilgrim; SSE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16i16_15 = insertelement <16 x i16> undef, i16 undef, i32 15
5745db826e4SSimon Pilgrim; SSE-NEXT:  Cost Model: Found an estimated cost of 9 for instruction: %v32i16_a = insertelement <32 x i16> undef, i16 undef, i32 %arg
575168a44a7SSimon Pilgrim; SSE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i16_0 = insertelement <32 x i16> undef, i16 undef, i32 0
576168a44a7SSimon Pilgrim; SSE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i16_7 = insertelement <32 x i16> undef, i16 undef, i32 7
577168a44a7SSimon Pilgrim; SSE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i16_8 = insertelement <32 x i16> undef, i16 undef, i32 8
578168a44a7SSimon Pilgrim; SSE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i16_15 = insertelement <32 x i16> undef, i16 undef, i32 15
579168a44a7SSimon Pilgrim; SSE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i16_16 = insertelement <32 x i16> undef, i16 undef, i32 16
580168a44a7SSimon Pilgrim; SSE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i16_24 = insertelement <32 x i16> undef, i16 undef, i32 24
581168a44a7SSimon Pilgrim; SSE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i16_31 = insertelement <32 x i16> undef, i16 undef, i32 31
582168a44a7SSimon Pilgrim; SSE-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret i32 undef
583168a44a7SSimon Pilgrim;
584168a44a7SSimon Pilgrim; AVX-LABEL: 'insert_i16'
5855db826e4SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v2i16_a = insertelement <2 x i16> undef, i16 undef, i32 %arg
58687fd686fSSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v2i16_0 = insertelement <2 x i16> undef, i16 undef, i32 0
58787fd686fSSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v2i16_1 = insertelement <2 x i16> undef, i16 undef, i32 1
5885db826e4SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v4i16_a = insertelement <4 x i16> undef, i16 undef, i32 %arg
58987fd686fSSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v4i16_0 = insertelement <4 x i16> undef, i16 undef, i32 0
59087fd686fSSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v4i16_3 = insertelement <4 x i16> undef, i16 undef, i32 3
5915db826e4SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v8i16_a = insertelement <8 x i16> undef, i16 undef, i32 %arg
592168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i16_0 = insertelement <8 x i16> undef, i16 undef, i32 0
593168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i16_7 = insertelement <8 x i16> undef, i16 undef, i32 7
5945db826e4SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v16i16_a = insertelement <16 x i16> undef, i16 undef, i32 %arg
595168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16i16_0 = insertelement <16 x i16> undef, i16 undef, i32 0
596168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16i16_7 = insertelement <16 x i16> undef, i16 undef, i32 7
597168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v16i16_8 = insertelement <16 x i16> undef, i16 undef, i32 8
598168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v16i16_15 = insertelement <16 x i16> undef, i16 undef, i32 15
5995db826e4SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %v32i16_a = insertelement <32 x i16> undef, i16 undef, i32 %arg
600168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i16_0 = insertelement <32 x i16> undef, i16 undef, i32 0
601168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i16_7 = insertelement <32 x i16> undef, i16 undef, i32 7
602168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v32i16_8 = insertelement <32 x i16> undef, i16 undef, i32 8
603168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v32i16_15 = insertelement <32 x i16> undef, i16 undef, i32 15
604168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i16_16 = insertelement <32 x i16> undef, i16 undef, i32 16
605168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v32i16_24 = insertelement <32 x i16> undef, i16 undef, i32 24
606168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v32i16_31 = insertelement <32 x i16> undef, i16 undef, i32 31
607168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret i32 undef
608168a44a7SSimon Pilgrim;
6098dfb9627SCraig Topper; AVX512-LABEL: 'insert_i16'
6105db826e4SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v2i16_a = insertelement <2 x i16> undef, i16 undef, i32 %arg
6118dfb9627SCraig Topper; AVX512-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v2i16_0 = insertelement <2 x i16> undef, i16 undef, i32 0
6128dfb9627SCraig Topper; AVX512-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v2i16_1 = insertelement <2 x i16> undef, i16 undef, i32 1
6135db826e4SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v4i16_a = insertelement <4 x i16> undef, i16 undef, i32 %arg
6148dfb9627SCraig Topper; AVX512-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v4i16_0 = insertelement <4 x i16> undef, i16 undef, i32 0
6158dfb9627SCraig Topper; AVX512-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v4i16_3 = insertelement <4 x i16> undef, i16 undef, i32 3
6165db826e4SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v8i16_a = insertelement <8 x i16> undef, i16 undef, i32 %arg
6178dfb9627SCraig Topper; AVX512-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i16_0 = insertelement <8 x i16> undef, i16 undef, i32 0
6188dfb9627SCraig Topper; AVX512-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i16_7 = insertelement <8 x i16> undef, i16 undef, i32 7
6195db826e4SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v16i16_a = insertelement <16 x i16> undef, i16 undef, i32 %arg
6208dfb9627SCraig Topper; AVX512-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16i16_0 = insertelement <16 x i16> undef, i16 undef, i32 0
6218dfb9627SCraig Topper; AVX512-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16i16_7 = insertelement <16 x i16> undef, i16 undef, i32 7
6228dfb9627SCraig Topper; AVX512-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v16i16_8 = insertelement <16 x i16> undef, i16 undef, i32 8
6238dfb9627SCraig Topper; AVX512-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v16i16_15 = insertelement <16 x i16> undef, i16 undef, i32 15
6245db826e4SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v32i16_a = insertelement <32 x i16> undef, i16 undef, i32 %arg
6258dfb9627SCraig Topper; AVX512-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i16_0 = insertelement <32 x i16> undef, i16 undef, i32 0
6268dfb9627SCraig Topper; AVX512-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i16_7 = insertelement <32 x i16> undef, i16 undef, i32 7
6278dfb9627SCraig Topper; AVX512-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v32i16_8 = insertelement <32 x i16> undef, i16 undef, i32 8
6288dfb9627SCraig Topper; AVX512-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v32i16_15 = insertelement <32 x i16> undef, i16 undef, i32 15
6298dfb9627SCraig Topper; AVX512-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v32i16_16 = insertelement <32 x i16> undef, i16 undef, i32 16
6308dfb9627SCraig Topper; AVX512-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v32i16_24 = insertelement <32 x i16> undef, i16 undef, i32 24
6318dfb9627SCraig Topper; AVX512-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v32i16_31 = insertelement <32 x i16> undef, i16 undef, i32 31
6328dfb9627SCraig Topper; AVX512-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret i32 undef
633ab979876SSimon Pilgrim;
63487fd686fSSimon Pilgrim  %v2i16_a = insertelement <2 x i16> undef, i16 undef, i32 %arg
63587fd686fSSimon Pilgrim  %v2i16_0 = insertelement <2 x i16> undef, i16 undef, i32 0
63687fd686fSSimon Pilgrim  %v2i16_1 = insertelement <2 x i16> undef, i16 undef, i32 1
63787fd686fSSimon Pilgrim
63887fd686fSSimon Pilgrim  %v4i16_a = insertelement <4 x i16> undef, i16 undef, i32 %arg
63987fd686fSSimon Pilgrim  %v4i16_0 = insertelement <4 x i16> undef, i16 undef, i32 0
64087fd686fSSimon Pilgrim  %v4i16_3 = insertelement <4 x i16> undef, i16 undef, i32 3
64187fd686fSSimon Pilgrim
642d7ac2553SSimon Pilgrim  %v8i16_a = insertelement <8 x i16> undef, i16 undef, i32 %arg
643ab979876SSimon Pilgrim  %v8i16_0 = insertelement <8 x i16> undef, i16 undef, i32 0
644ab979876SSimon Pilgrim  %v8i16_7 = insertelement <8 x i16> undef, i16 undef, i32 7
645ab979876SSimon Pilgrim
646d7ac2553SSimon Pilgrim  %v16i16_a  = insertelement <16 x i16> undef, i16 undef, i32 %arg
647ab979876SSimon Pilgrim  %v16i16_0  = insertelement <16 x i16> undef, i16 undef, i32 0
648ab979876SSimon Pilgrim  %v16i16_7  = insertelement <16 x i16> undef, i16 undef, i32 7
649ab979876SSimon Pilgrim  %v16i16_8  = insertelement <16 x i16> undef, i16 undef, i32 8
650ab979876SSimon Pilgrim  %v16i16_15 = insertelement <16 x i16> undef, i16 undef, i32 15
651ab979876SSimon Pilgrim
652d7ac2553SSimon Pilgrim  %v32i16_a  = insertelement <32 x i16> undef, i16 undef, i32 %arg
653ab979876SSimon Pilgrim  %v32i16_0  = insertelement <32 x i16> undef, i16 undef, i32 0
654ab979876SSimon Pilgrim  %v32i16_7  = insertelement <32 x i16> undef, i16 undef, i32 7
655ab979876SSimon Pilgrim  %v32i16_8  = insertelement <32 x i16> undef, i16 undef, i32 8
656ab979876SSimon Pilgrim  %v32i16_15 = insertelement <32 x i16> undef, i16 undef, i32 15
657ab979876SSimon Pilgrim  %v32i16_16 = insertelement <32 x i16> undef, i16 undef, i32 16
658ab979876SSimon Pilgrim  %v32i16_24 = insertelement <32 x i16> undef, i16 undef, i32 24
659ab979876SSimon Pilgrim  %v32i16_31 = insertelement <32 x i16> undef, i16 undef, i32 31
660ab979876SSimon Pilgrim
661ab979876SSimon Pilgrim  ret i32 undef
662ab979876SSimon Pilgrim}
663ab979876SSimon Pilgrim
664ab979876SSimon Pilgrimdefine i32 @insert_i8(i32 %arg) {
665168a44a7SSimon Pilgrim; SSE2-LABEL: 'insert_i8'
6665db826e4SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v2i8_a = insertelement <2 x i8> undef, i8 undef, i32 %arg
66791bc50c0SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v2i8_0 = insertelement <2 x i8> undef, i8 undef, i32 0
66891bc50c0SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v2i8_3 = insertelement <2 x i8> undef, i8 undef, i32 1
6695db826e4SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v4i8_a = insertelement <4 x i8> undef, i8 undef, i32 %arg
67091bc50c0SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %v4i8_0 = insertelement <4 x i8> undef, i8 undef, i32 0
67191bc50c0SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %v4i8_3 = insertelement <4 x i8> undef, i8 undef, i32 3
6725db826e4SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v8i8_a = insertelement <8 x i8> undef, i8 undef, i32 %arg
67391bc50c0SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %v8i8_0 = insertelement <8 x i8> undef, i8 undef, i32 0
67491bc50c0SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %v8i8_7 = insertelement <8 x i8> undef, i8 undef, i32 7
6755db826e4SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v16i8_a = insertelement <16 x i8> undef, i8 undef, i32 %arg
676168a44a7SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v16i8_0 = insertelement <16 x i8> undef, i8 undef, i32 0
677168a44a7SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v16i8_8 = insertelement <16 x i8> undef, i8 undef, i32 8
678168a44a7SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v16i8_15 = insertelement <16 x i8> undef, i8 undef, i32 15
6795db826e4SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %v32i8_a = insertelement <32 x i8> undef, i8 undef, i32 %arg
680168a44a7SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v32i8_0 = insertelement <32 x i8> undef, i8 undef, i32 0
681168a44a7SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v32i8_7 = insertelement <32 x i8> undef, i8 undef, i32 7
682168a44a7SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v32i8_8 = insertelement <32 x i8> undef, i8 undef, i32 8
683168a44a7SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v32i8_15 = insertelement <32 x i8> undef, i8 undef, i32 15
684168a44a7SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v32i8_24 = insertelement <32 x i8> undef, i8 undef, i32 24
685168a44a7SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v32i8_31 = insertelement <32 x i8> undef, i8 undef, i32 31
6865db826e4SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 9 for instruction: %v64i8_a = insertelement <64 x i8> undef, i8 undef, i32 %arg
687168a44a7SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v64i8_0 = insertelement <64 x i8> undef, i8 undef, i32 0
688168a44a7SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v64i8_7 = insertelement <64 x i8> undef, i8 undef, i32 7
689168a44a7SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v64i8_8 = insertelement <64 x i8> undef, i8 undef, i32 8
690168a44a7SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v64i8_15 = insertelement <64 x i8> undef, i8 undef, i32 15
691168a44a7SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v64i8_24 = insertelement <64 x i8> undef, i8 undef, i32 24
692168a44a7SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v64i8_31 = insertelement <64 x i8> undef, i8 undef, i32 31
693168a44a7SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v64i8_32 = insertelement <64 x i8> undef, i8 undef, i32 32
694168a44a7SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v64i8_48 = insertelement <64 x i8> undef, i8 undef, i32 48
695168a44a7SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v64i8_63 = insertelement <64 x i8> undef, i8 undef, i32 63
696168a44a7SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret i32 undef
697168a44a7SSimon Pilgrim;
698168a44a7SSimon Pilgrim; SSE3-LABEL: 'insert_i8'
6995db826e4SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v2i8_a = insertelement <2 x i8> undef, i8 undef, i32 %arg
70091bc50c0SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v2i8_0 = insertelement <2 x i8> undef, i8 undef, i32 0
70191bc50c0SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v2i8_3 = insertelement <2 x i8> undef, i8 undef, i32 1
7025db826e4SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v4i8_a = insertelement <4 x i8> undef, i8 undef, i32 %arg
70391bc50c0SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %v4i8_0 = insertelement <4 x i8> undef, i8 undef, i32 0
70491bc50c0SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %v4i8_3 = insertelement <4 x i8> undef, i8 undef, i32 3
7055db826e4SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v8i8_a = insertelement <8 x i8> undef, i8 undef, i32 %arg
70691bc50c0SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %v8i8_0 = insertelement <8 x i8> undef, i8 undef, i32 0
70791bc50c0SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %v8i8_7 = insertelement <8 x i8> undef, i8 undef, i32 7
7085db826e4SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v16i8_a = insertelement <16 x i8> undef, i8 undef, i32 %arg
709168a44a7SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v16i8_0 = insertelement <16 x i8> undef, i8 undef, i32 0
710168a44a7SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v16i8_8 = insertelement <16 x i8> undef, i8 undef, i32 8
711168a44a7SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v16i8_15 = insertelement <16 x i8> undef, i8 undef, i32 15
7125db826e4SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %v32i8_a = insertelement <32 x i8> undef, i8 undef, i32 %arg
713168a44a7SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v32i8_0 = insertelement <32 x i8> undef, i8 undef, i32 0
714168a44a7SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v32i8_7 = insertelement <32 x i8> undef, i8 undef, i32 7
715168a44a7SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v32i8_8 = insertelement <32 x i8> undef, i8 undef, i32 8
716168a44a7SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v32i8_15 = insertelement <32 x i8> undef, i8 undef, i32 15
717168a44a7SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v32i8_24 = insertelement <32 x i8> undef, i8 undef, i32 24
718168a44a7SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v32i8_31 = insertelement <32 x i8> undef, i8 undef, i32 31
7195db826e4SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 9 for instruction: %v64i8_a = insertelement <64 x i8> undef, i8 undef, i32 %arg
720168a44a7SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v64i8_0 = insertelement <64 x i8> undef, i8 undef, i32 0
721168a44a7SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v64i8_7 = insertelement <64 x i8> undef, i8 undef, i32 7
722168a44a7SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v64i8_8 = insertelement <64 x i8> undef, i8 undef, i32 8
723168a44a7SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v64i8_15 = insertelement <64 x i8> undef, i8 undef, i32 15
724168a44a7SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v64i8_24 = insertelement <64 x i8> undef, i8 undef, i32 24
725168a44a7SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v64i8_31 = insertelement <64 x i8> undef, i8 undef, i32 31
726168a44a7SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v64i8_32 = insertelement <64 x i8> undef, i8 undef, i32 32
727168a44a7SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v64i8_48 = insertelement <64 x i8> undef, i8 undef, i32 48
728168a44a7SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v64i8_63 = insertelement <64 x i8> undef, i8 undef, i32 63
729168a44a7SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret i32 undef
730168a44a7SSimon Pilgrim;
731168a44a7SSimon Pilgrim; SSSE3-LABEL: 'insert_i8'
7325db826e4SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v2i8_a = insertelement <2 x i8> undef, i8 undef, i32 %arg
73387fd686fSSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %v2i8_0 = insertelement <2 x i8> undef, i8 undef, i32 0
73487fd686fSSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %v2i8_3 = insertelement <2 x i8> undef, i8 undef, i32 1
7355db826e4SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v4i8_a = insertelement <4 x i8> undef, i8 undef, i32 %arg
73687fd686fSSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %v4i8_0 = insertelement <4 x i8> undef, i8 undef, i32 0
73787fd686fSSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %v4i8_3 = insertelement <4 x i8> undef, i8 undef, i32 3
7385db826e4SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v8i8_a = insertelement <8 x i8> undef, i8 undef, i32 %arg
73987fd686fSSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %v8i8_0 = insertelement <8 x i8> undef, i8 undef, i32 0
74087fd686fSSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %v8i8_7 = insertelement <8 x i8> undef, i8 undef, i32 7
7415db826e4SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v16i8_a = insertelement <16 x i8> undef, i8 undef, i32 %arg
742168a44a7SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %v16i8_0 = insertelement <16 x i8> undef, i8 undef, i32 0
743168a44a7SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %v16i8_8 = insertelement <16 x i8> undef, i8 undef, i32 8
744168a44a7SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %v16i8_15 = insertelement <16 x i8> undef, i8 undef, i32 15
7455db826e4SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %v32i8_a = insertelement <32 x i8> undef, i8 undef, i32 %arg
746168a44a7SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %v32i8_0 = insertelement <32 x i8> undef, i8 undef, i32 0
747168a44a7SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %v32i8_7 = insertelement <32 x i8> undef, i8 undef, i32 7
748168a44a7SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %v32i8_8 = insertelement <32 x i8> undef, i8 undef, i32 8
749168a44a7SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %v32i8_15 = insertelement <32 x i8> undef, i8 undef, i32 15
750168a44a7SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %v32i8_24 = insertelement <32 x i8> undef, i8 undef, i32 24
751168a44a7SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %v32i8_31 = insertelement <32 x i8> undef, i8 undef, i32 31
7525db826e4SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 9 for instruction: %v64i8_a = insertelement <64 x i8> undef, i8 undef, i32 %arg
753168a44a7SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %v64i8_0 = insertelement <64 x i8> undef, i8 undef, i32 0
754168a44a7SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %v64i8_7 = insertelement <64 x i8> undef, i8 undef, i32 7
755168a44a7SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %v64i8_8 = insertelement <64 x i8> undef, i8 undef, i32 8
756168a44a7SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %v64i8_15 = insertelement <64 x i8> undef, i8 undef, i32 15
757168a44a7SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %v64i8_24 = insertelement <64 x i8> undef, i8 undef, i32 24
758168a44a7SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %v64i8_31 = insertelement <64 x i8> undef, i8 undef, i32 31
759168a44a7SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %v64i8_32 = insertelement <64 x i8> undef, i8 undef, i32 32
760168a44a7SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %v64i8_48 = insertelement <64 x i8> undef, i8 undef, i32 48
761168a44a7SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %v64i8_63 = insertelement <64 x i8> undef, i8 undef, i32 63
762168a44a7SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret i32 undef
763168a44a7SSimon Pilgrim;
764168a44a7SSimon Pilgrim; SSE4-LABEL: 'insert_i8'
7655db826e4SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v2i8_a = insertelement <2 x i8> undef, i8 undef, i32 %arg
76687fd686fSSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v2i8_0 = insertelement <2 x i8> undef, i8 undef, i32 0
76787fd686fSSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v2i8_3 = insertelement <2 x i8> undef, i8 undef, i32 1
7685db826e4SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v4i8_a = insertelement <4 x i8> undef, i8 undef, i32 %arg
76987fd686fSSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v4i8_0 = insertelement <4 x i8> undef, i8 undef, i32 0
77087fd686fSSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v4i8_3 = insertelement <4 x i8> undef, i8 undef, i32 3
7715db826e4SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v8i8_a = insertelement <8 x i8> undef, i8 undef, i32 %arg
77287fd686fSSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i8_0 = insertelement <8 x i8> undef, i8 undef, i32 0
77387fd686fSSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i8_7 = insertelement <8 x i8> undef, i8 undef, i32 7
7745db826e4SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v16i8_a = insertelement <16 x i8> undef, i8 undef, i32 %arg
775168a44a7SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16i8_0 = insertelement <16 x i8> undef, i8 undef, i32 0
776168a44a7SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16i8_8 = insertelement <16 x i8> undef, i8 undef, i32 8
777168a44a7SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16i8_15 = insertelement <16 x i8> undef, i8 undef, i32 15
7785db826e4SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %v32i8_a = insertelement <32 x i8> undef, i8 undef, i32 %arg
779168a44a7SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i8_0 = insertelement <32 x i8> undef, i8 undef, i32 0
780168a44a7SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i8_7 = insertelement <32 x i8> undef, i8 undef, i32 7
781168a44a7SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i8_8 = insertelement <32 x i8> undef, i8 undef, i32 8
782168a44a7SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i8_15 = insertelement <32 x i8> undef, i8 undef, i32 15
783168a44a7SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i8_24 = insertelement <32 x i8> undef, i8 undef, i32 24
784168a44a7SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i8_31 = insertelement <32 x i8> undef, i8 undef, i32 31
7855db826e4SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 9 for instruction: %v64i8_a = insertelement <64 x i8> undef, i8 undef, i32 %arg
786168a44a7SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i8_0 = insertelement <64 x i8> undef, i8 undef, i32 0
787168a44a7SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i8_7 = insertelement <64 x i8> undef, i8 undef, i32 7
788168a44a7SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i8_8 = insertelement <64 x i8> undef, i8 undef, i32 8
789168a44a7SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i8_15 = insertelement <64 x i8> undef, i8 undef, i32 15
790168a44a7SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i8_24 = insertelement <64 x i8> undef, i8 undef, i32 24
791168a44a7SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i8_31 = insertelement <64 x i8> undef, i8 undef, i32 31
792168a44a7SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i8_32 = insertelement <64 x i8> undef, i8 undef, i32 32
793168a44a7SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i8_48 = insertelement <64 x i8> undef, i8 undef, i32 48
794168a44a7SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i8_63 = insertelement <64 x i8> undef, i8 undef, i32 63
795168a44a7SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret i32 undef
796168a44a7SSimon Pilgrim;
797168a44a7SSimon Pilgrim; AVX-LABEL: 'insert_i8'
7985db826e4SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v2i8_a = insertelement <2 x i8> undef, i8 undef, i32 %arg
79987fd686fSSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v2i8_0 = insertelement <2 x i8> undef, i8 undef, i32 0
80087fd686fSSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v2i8_3 = insertelement <2 x i8> undef, i8 undef, i32 1
8015db826e4SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v4i8_a = insertelement <4 x i8> undef, i8 undef, i32 %arg
80287fd686fSSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v4i8_0 = insertelement <4 x i8> undef, i8 undef, i32 0
80387fd686fSSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v4i8_3 = insertelement <4 x i8> undef, i8 undef, i32 3
8045db826e4SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v8i8_a = insertelement <8 x i8> undef, i8 undef, i32 %arg
80587fd686fSSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i8_0 = insertelement <8 x i8> undef, i8 undef, i32 0
80687fd686fSSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i8_7 = insertelement <8 x i8> undef, i8 undef, i32 7
8075db826e4SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v16i8_a = insertelement <16 x i8> undef, i8 undef, i32 %arg
808168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16i8_0 = insertelement <16 x i8> undef, i8 undef, i32 0
809168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16i8_8 = insertelement <16 x i8> undef, i8 undef, i32 8
810168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16i8_15 = insertelement <16 x i8> undef, i8 undef, i32 15
8115db826e4SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v32i8_a = insertelement <32 x i8> undef, i8 undef, i32 %arg
812168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i8_0 = insertelement <32 x i8> undef, i8 undef, i32 0
813168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i8_7 = insertelement <32 x i8> undef, i8 undef, i32 7
814168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i8_8 = insertelement <32 x i8> undef, i8 undef, i32 8
815168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i8_15 = insertelement <32 x i8> undef, i8 undef, i32 15
816168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v32i8_24 = insertelement <32 x i8> undef, i8 undef, i32 24
817168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v32i8_31 = insertelement <32 x i8> undef, i8 undef, i32 31
8185db826e4SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %v64i8_a = insertelement <64 x i8> undef, i8 undef, i32 %arg
819168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i8_0 = insertelement <64 x i8> undef, i8 undef, i32 0
820168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i8_7 = insertelement <64 x i8> undef, i8 undef, i32 7
821168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i8_8 = insertelement <64 x i8> undef, i8 undef, i32 8
822168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i8_15 = insertelement <64 x i8> undef, i8 undef, i32 15
823168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v64i8_24 = insertelement <64 x i8> undef, i8 undef, i32 24
824168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v64i8_31 = insertelement <64 x i8> undef, i8 undef, i32 31
825168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i8_32 = insertelement <64 x i8> undef, i8 undef, i32 32
826168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v64i8_48 = insertelement <64 x i8> undef, i8 undef, i32 48
827168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v64i8_63 = insertelement <64 x i8> undef, i8 undef, i32 63
828168a44a7SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret i32 undef
829168a44a7SSimon Pilgrim;
8308dfb9627SCraig Topper; AVX512-LABEL: 'insert_i8'
8315db826e4SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v2i8_a = insertelement <2 x i8> undef, i8 undef, i32 %arg
8328dfb9627SCraig Topper; AVX512-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v2i8_0 = insertelement <2 x i8> undef, i8 undef, i32 0
8338dfb9627SCraig Topper; AVX512-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v2i8_3 = insertelement <2 x i8> undef, i8 undef, i32 1
8345db826e4SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v4i8_a = insertelement <4 x i8> undef, i8 undef, i32 %arg
8358dfb9627SCraig Topper; AVX512-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v4i8_0 = insertelement <4 x i8> undef, i8 undef, i32 0
8368dfb9627SCraig Topper; AVX512-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v4i8_3 = insertelement <4 x i8> undef, i8 undef, i32 3
8375db826e4SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v8i8_a = insertelement <8 x i8> undef, i8 undef, i32 %arg
8388dfb9627SCraig Topper; AVX512-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i8_0 = insertelement <8 x i8> undef, i8 undef, i32 0
8398dfb9627SCraig Topper; AVX512-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i8_7 = insertelement <8 x i8> undef, i8 undef, i32 7
8405db826e4SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v16i8_a = insertelement <16 x i8> undef, i8 undef, i32 %arg
8418dfb9627SCraig Topper; AVX512-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16i8_0 = insertelement <16 x i8> undef, i8 undef, i32 0
8428dfb9627SCraig Topper; AVX512-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16i8_8 = insertelement <16 x i8> undef, i8 undef, i32 8
8438dfb9627SCraig Topper; AVX512-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16i8_15 = insertelement <16 x i8> undef, i8 undef, i32 15
8445db826e4SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v32i8_a = insertelement <32 x i8> undef, i8 undef, i32 %arg
8458dfb9627SCraig Topper; AVX512-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i8_0 = insertelement <32 x i8> undef, i8 undef, i32 0
8468dfb9627SCraig Topper; AVX512-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i8_7 = insertelement <32 x i8> undef, i8 undef, i32 7
8478dfb9627SCraig Topper; AVX512-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i8_8 = insertelement <32 x i8> undef, i8 undef, i32 8
8488dfb9627SCraig Topper; AVX512-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i8_15 = insertelement <32 x i8> undef, i8 undef, i32 15
8498dfb9627SCraig Topper; AVX512-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v32i8_24 = insertelement <32 x i8> undef, i8 undef, i32 24
8508dfb9627SCraig Topper; AVX512-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v32i8_31 = insertelement <32 x i8> undef, i8 undef, i32 31
8515db826e4SSimon Pilgrim; AVX512-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v64i8_a = insertelement <64 x i8> undef, i8 undef, i32 %arg
8528dfb9627SCraig Topper; AVX512-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i8_0 = insertelement <64 x i8> undef, i8 undef, i32 0
8538dfb9627SCraig Topper; AVX512-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i8_7 = insertelement <64 x i8> undef, i8 undef, i32 7
8548dfb9627SCraig Topper; AVX512-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i8_8 = insertelement <64 x i8> undef, i8 undef, i32 8
8558dfb9627SCraig Topper; AVX512-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i8_15 = insertelement <64 x i8> undef, i8 undef, i32 15
8568dfb9627SCraig Topper; AVX512-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v64i8_24 = insertelement <64 x i8> undef, i8 undef, i32 24
8578dfb9627SCraig Topper; AVX512-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v64i8_31 = insertelement <64 x i8> undef, i8 undef, i32 31
8588dfb9627SCraig Topper; AVX512-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v64i8_32 = insertelement <64 x i8> undef, i8 undef, i32 32
8598dfb9627SCraig Topper; AVX512-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v64i8_48 = insertelement <64 x i8> undef, i8 undef, i32 48
8608dfb9627SCraig Topper; AVX512-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v64i8_63 = insertelement <64 x i8> undef, i8 undef, i32 63
8618dfb9627SCraig Topper; AVX512-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret i32 undef
862168a44a7SSimon Pilgrim;
863168a44a7SSimon Pilgrim; SLM-LABEL: 'insert_i8'
8645db826e4SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v2i8_a = insertelement <2 x i8> undef, i8 undef, i32 %arg
86587fd686fSSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v2i8_0 = insertelement <2 x i8> undef, i8 undef, i32 0
86687fd686fSSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v2i8_3 = insertelement <2 x i8> undef, i8 undef, i32 1
8675db826e4SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v4i8_a = insertelement <4 x i8> undef, i8 undef, i32 %arg
86887fd686fSSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v4i8_0 = insertelement <4 x i8> undef, i8 undef, i32 0
86987fd686fSSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v4i8_3 = insertelement <4 x i8> undef, i8 undef, i32 3
8705db826e4SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v8i8_a = insertelement <8 x i8> undef, i8 undef, i32 %arg
87187fd686fSSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i8_0 = insertelement <8 x i8> undef, i8 undef, i32 0
87287fd686fSSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i8_7 = insertelement <8 x i8> undef, i8 undef, i32 7
8735db826e4SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v16i8_a = insertelement <16 x i8> undef, i8 undef, i32 %arg
874168a44a7SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16i8_0 = insertelement <16 x i8> undef, i8 undef, i32 0
875168a44a7SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16i8_8 = insertelement <16 x i8> undef, i8 undef, i32 8
876168a44a7SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16i8_15 = insertelement <16 x i8> undef, i8 undef, i32 15
8775db826e4SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %v32i8_a = insertelement <32 x i8> undef, i8 undef, i32 %arg
878168a44a7SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i8_0 = insertelement <32 x i8> undef, i8 undef, i32 0
879168a44a7SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i8_7 = insertelement <32 x i8> undef, i8 undef, i32 7
880168a44a7SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i8_8 = insertelement <32 x i8> undef, i8 undef, i32 8
881168a44a7SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i8_15 = insertelement <32 x i8> undef, i8 undef, i32 15
882168a44a7SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i8_24 = insertelement <32 x i8> undef, i8 undef, i32 24
883168a44a7SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i8_31 = insertelement <32 x i8> undef, i8 undef, i32 31
8845db826e4SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 9 for instruction: %v64i8_a = insertelement <64 x i8> undef, i8 undef, i32 %arg
885168a44a7SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i8_0 = insertelement <64 x i8> undef, i8 undef, i32 0
886168a44a7SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i8_7 = insertelement <64 x i8> undef, i8 undef, i32 7
887168a44a7SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i8_8 = insertelement <64 x i8> undef, i8 undef, i32 8
888168a44a7SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i8_15 = insertelement <64 x i8> undef, i8 undef, i32 15
889168a44a7SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i8_24 = insertelement <64 x i8> undef, i8 undef, i32 24
890168a44a7SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i8_31 = insertelement <64 x i8> undef, i8 undef, i32 31
891168a44a7SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i8_32 = insertelement <64 x i8> undef, i8 undef, i32 32
892168a44a7SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i8_48 = insertelement <64 x i8> undef, i8 undef, i32 48
893168a44a7SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i8_63 = insertelement <64 x i8> undef, i8 undef, i32 63
894168a44a7SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret i32 undef
895168a44a7SSimon Pilgrim;
896168a44a7SSimon Pilgrim; GLM-LABEL: 'insert_i8'
8975db826e4SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v2i8_a = insertelement <2 x i8> undef, i8 undef, i32 %arg
89887fd686fSSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v2i8_0 = insertelement <2 x i8> undef, i8 undef, i32 0
89987fd686fSSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v2i8_3 = insertelement <2 x i8> undef, i8 undef, i32 1
9005db826e4SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v4i8_a = insertelement <4 x i8> undef, i8 undef, i32 %arg
90187fd686fSSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v4i8_0 = insertelement <4 x i8> undef, i8 undef, i32 0
90287fd686fSSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v4i8_3 = insertelement <4 x i8> undef, i8 undef, i32 3
9035db826e4SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v8i8_a = insertelement <8 x i8> undef, i8 undef, i32 %arg
90487fd686fSSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i8_0 = insertelement <8 x i8> undef, i8 undef, i32 0
90587fd686fSSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i8_7 = insertelement <8 x i8> undef, i8 undef, i32 7
9065db826e4SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v16i8_a = insertelement <16 x i8> undef, i8 undef, i32 %arg
907168a44a7SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16i8_0 = insertelement <16 x i8> undef, i8 undef, i32 0
908168a44a7SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16i8_8 = insertelement <16 x i8> undef, i8 undef, i32 8
909168a44a7SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16i8_15 = insertelement <16 x i8> undef, i8 undef, i32 15
9105db826e4SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %v32i8_a = insertelement <32 x i8> undef, i8 undef, i32 %arg
911168a44a7SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i8_0 = insertelement <32 x i8> undef, i8 undef, i32 0
912168a44a7SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i8_7 = insertelement <32 x i8> undef, i8 undef, i32 7
913168a44a7SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i8_8 = insertelement <32 x i8> undef, i8 undef, i32 8
914168a44a7SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i8_15 = insertelement <32 x i8> undef, i8 undef, i32 15
915168a44a7SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i8_24 = insertelement <32 x i8> undef, i8 undef, i32 24
916168a44a7SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i8_31 = insertelement <32 x i8> undef, i8 undef, i32 31
9175db826e4SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 9 for instruction: %v64i8_a = insertelement <64 x i8> undef, i8 undef, i32 %arg
918168a44a7SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i8_0 = insertelement <64 x i8> undef, i8 undef, i32 0
919168a44a7SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i8_7 = insertelement <64 x i8> undef, i8 undef, i32 7
920168a44a7SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i8_8 = insertelement <64 x i8> undef, i8 undef, i32 8
921168a44a7SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i8_15 = insertelement <64 x i8> undef, i8 undef, i32 15
922168a44a7SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i8_24 = insertelement <64 x i8> undef, i8 undef, i32 24
923168a44a7SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i8_31 = insertelement <64 x i8> undef, i8 undef, i32 31
924168a44a7SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i8_32 = insertelement <64 x i8> undef, i8 undef, i32 32
925168a44a7SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i8_48 = insertelement <64 x i8> undef, i8 undef, i32 48
926168a44a7SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i8_63 = insertelement <64 x i8> undef, i8 undef, i32 63
927168a44a7SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret i32 undef
928ab979876SSimon Pilgrim;
92987fd686fSSimon Pilgrim  %v2i8_a   = insertelement <2 x i8> undef, i8 undef, i32 %arg
93087fd686fSSimon Pilgrim  %v2i8_0   = insertelement <2 x i8> undef, i8 undef, i32 0
93187fd686fSSimon Pilgrim  %v2i8_3   = insertelement <2 x i8> undef, i8 undef, i32 1
93287fd686fSSimon Pilgrim
93387fd686fSSimon Pilgrim  %v4i8_a   = insertelement <4 x i8> undef, i8 undef, i32 %arg
93487fd686fSSimon Pilgrim  %v4i8_0   = insertelement <4 x i8> undef, i8 undef, i32 0
93587fd686fSSimon Pilgrim  %v4i8_3   = insertelement <4 x i8> undef, i8 undef, i32 3
93687fd686fSSimon Pilgrim
93787fd686fSSimon Pilgrim  %v8i8_a   = insertelement <8 x i8> undef, i8 undef, i32 %arg
93887fd686fSSimon Pilgrim  %v8i8_0   = insertelement <8 x i8> undef, i8 undef, i32 0
93987fd686fSSimon Pilgrim  %v8i8_7   = insertelement <8 x i8> undef, i8 undef, i32 7
94087fd686fSSimon Pilgrim
941d7ac2553SSimon Pilgrim  %v16i8_a  = insertelement <16 x i8> undef, i8 undef, i32 %arg
942ab979876SSimon Pilgrim  %v16i8_0  = insertelement <16 x i8> undef, i8 undef, i32 0
943ab979876SSimon Pilgrim  %v16i8_8  = insertelement <16 x i8> undef, i8 undef, i32 8
944ab979876SSimon Pilgrim  %v16i8_15 = insertelement <16 x i8> undef, i8 undef, i32 15
945ab979876SSimon Pilgrim
946d7ac2553SSimon Pilgrim  %v32i8_a  = insertelement <32 x i8> undef, i8 undef, i32 %arg
947ab979876SSimon Pilgrim  %v32i8_0  = insertelement <32 x i8> undef, i8 undef, i32 0
948ab979876SSimon Pilgrim  %v32i8_7  = insertelement <32 x i8> undef, i8 undef, i32 7
949ab979876SSimon Pilgrim  %v32i8_8  = insertelement <32 x i8> undef, i8 undef, i32 8
950ab979876SSimon Pilgrim  %v32i8_15 = insertelement <32 x i8> undef, i8 undef, i32 15
951ab979876SSimon Pilgrim  %v32i8_24 = insertelement <32 x i8> undef, i8 undef, i32 24
952ab979876SSimon Pilgrim  %v32i8_31 = insertelement <32 x i8> undef, i8 undef, i32 31
953ab979876SSimon Pilgrim
954d7ac2553SSimon Pilgrim  %v64i8_a  = insertelement <64 x i8> undef, i8 undef, i32 %arg
955ab979876SSimon Pilgrim  %v64i8_0  = insertelement <64 x i8> undef, i8 undef, i32 0
956ab979876SSimon Pilgrim  %v64i8_7  = insertelement <64 x i8> undef, i8 undef, i32 7
957ab979876SSimon Pilgrim  %v64i8_8  = insertelement <64 x i8> undef, i8 undef, i32 8
958ab979876SSimon Pilgrim  %v64i8_15 = insertelement <64 x i8> undef, i8 undef, i32 15
959ab979876SSimon Pilgrim  %v64i8_24 = insertelement <64 x i8> undef, i8 undef, i32 24
960ab979876SSimon Pilgrim  %v64i8_31 = insertelement <64 x i8> undef, i8 undef, i32 31
961ab979876SSimon Pilgrim  %v64i8_32 = insertelement <64 x i8> undef, i8 undef, i32 32
962ab979876SSimon Pilgrim  %v64i8_48 = insertelement <64 x i8> undef, i8 undef, i32 48
963ab979876SSimon Pilgrim  %v64i8_63 = insertelement <64 x i8> undef, i8 undef, i32 63
964ab979876SSimon Pilgrim
965ab979876SSimon Pilgrim  ret i32 undef
966ab979876SSimon Pilgrim}
967174cb7c6SSimon Pilgrim
968174cb7c6SSimon Pilgrimdefine i32 @insert_i1(i32 %arg) {
969174cb7c6SSimon Pilgrim; SSE2-LABEL: 'insert_i1'
9705db826e4SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v2i1_a = insertelement <2 x i1> undef, i1 undef, i32 %arg
971174cb7c6SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %v2i1_0 = insertelement <2 x i1> undef, i1 undef, i32 0
972174cb7c6SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %v2i1_1 = insertelement <2 x i1> undef, i1 undef, i32 1
9735db826e4SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v4i1_a = insertelement <4 x i1> undef, i1 undef, i32 %arg
974174cb7c6SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v4i1_0 = insertelement <4 x i1> undef, i1 undef, i32 0
975174cb7c6SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v4i1_2 = insertelement <4 x i1> undef, i1 undef, i32 2
9765db826e4SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v8i1_a = insertelement <8 x i1> undef, i1 undef, i32 %arg
977174cb7c6SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i1_0 = insertelement <8 x i1> undef, i1 undef, i32 0
978174cb7c6SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i1_4 = insertelement <8 x i1> undef, i1 undef, i32 4
9795db826e4SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v16i1_a = insertelement <16 x i1> undef, i1 undef, i32 %arg
980174cb7c6SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v16i1_0 = insertelement <16 x i1> undef, i1 undef, i32 0
981174cb7c6SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v16i1_8 = insertelement <16 x i1> undef, i1 undef, i32 8
982174cb7c6SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v16i1_15 = insertelement <16 x i1> undef, i1 undef, i32 15
9835db826e4SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v32i1_a = insertelement <32 x i1> undef, i1 undef, i32 %arg
984174cb7c6SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v32i1_0 = insertelement <32 x i1> undef, i1 undef, i32 0
985174cb7c6SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v32i1_7 = insertelement <32 x i1> undef, i1 undef, i32 7
986174cb7c6SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v32i1_8 = insertelement <32 x i1> undef, i1 undef, i32 8
987174cb7c6SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v32i1_15 = insertelement <32 x i1> undef, i1 undef, i32 15
988174cb7c6SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v32i1_24 = insertelement <32 x i1> undef, i1 undef, i32 24
989174cb7c6SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v32i1_31 = insertelement <32 x i1> undef, i1 undef, i32 31
9905db826e4SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v64i1_a = insertelement <64 x i1> undef, i1 undef, i32 %arg
991174cb7c6SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v64i1_0 = insertelement <64 x i1> undef, i1 undef, i32 0
992174cb7c6SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v64i1_7 = insertelement <64 x i1> undef, i1 undef, i32 7
993174cb7c6SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v64i1_8 = insertelement <64 x i1> undef, i1 undef, i32 8
994174cb7c6SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v64i1_15 = insertelement <64 x i1> undef, i1 undef, i32 15
995174cb7c6SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v64i1_24 = insertelement <64 x i1> undef, i1 undef, i32 24
996174cb7c6SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v64i1_31 = insertelement <64 x i1> undef, i1 undef, i32 31
997174cb7c6SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v64i1_32 = insertelement <64 x i1> undef, i1 undef, i32 32
998174cb7c6SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v64i1_48 = insertelement <64 x i1> undef, i1 undef, i32 48
999174cb7c6SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v64i1_63 = insertelement <64 x i1> undef, i1 undef, i32 63
1000174cb7c6SSimon Pilgrim; SSE2-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret i32 undef
1001174cb7c6SSimon Pilgrim;
1002174cb7c6SSimon Pilgrim; SSE3-LABEL: 'insert_i1'
10035db826e4SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v2i1_a = insertelement <2 x i1> undef, i1 undef, i32 %arg
1004174cb7c6SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %v2i1_0 = insertelement <2 x i1> undef, i1 undef, i32 0
1005174cb7c6SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %v2i1_1 = insertelement <2 x i1> undef, i1 undef, i32 1
10065db826e4SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v4i1_a = insertelement <4 x i1> undef, i1 undef, i32 %arg
1007174cb7c6SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v4i1_0 = insertelement <4 x i1> undef, i1 undef, i32 0
1008174cb7c6SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v4i1_2 = insertelement <4 x i1> undef, i1 undef, i32 2
10095db826e4SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v8i1_a = insertelement <8 x i1> undef, i1 undef, i32 %arg
1010174cb7c6SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i1_0 = insertelement <8 x i1> undef, i1 undef, i32 0
1011174cb7c6SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i1_4 = insertelement <8 x i1> undef, i1 undef, i32 4
10125db826e4SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v16i1_a = insertelement <16 x i1> undef, i1 undef, i32 %arg
1013174cb7c6SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v16i1_0 = insertelement <16 x i1> undef, i1 undef, i32 0
1014174cb7c6SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v16i1_8 = insertelement <16 x i1> undef, i1 undef, i32 8
1015174cb7c6SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v16i1_15 = insertelement <16 x i1> undef, i1 undef, i32 15
10165db826e4SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v32i1_a = insertelement <32 x i1> undef, i1 undef, i32 %arg
1017174cb7c6SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v32i1_0 = insertelement <32 x i1> undef, i1 undef, i32 0
1018174cb7c6SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v32i1_7 = insertelement <32 x i1> undef, i1 undef, i32 7
1019174cb7c6SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v32i1_8 = insertelement <32 x i1> undef, i1 undef, i32 8
1020174cb7c6SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v32i1_15 = insertelement <32 x i1> undef, i1 undef, i32 15
1021174cb7c6SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v32i1_24 = insertelement <32 x i1> undef, i1 undef, i32 24
1022174cb7c6SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v32i1_31 = insertelement <32 x i1> undef, i1 undef, i32 31
10235db826e4SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v64i1_a = insertelement <64 x i1> undef, i1 undef, i32 %arg
1024174cb7c6SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v64i1_0 = insertelement <64 x i1> undef, i1 undef, i32 0
1025174cb7c6SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v64i1_7 = insertelement <64 x i1> undef, i1 undef, i32 7
1026174cb7c6SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v64i1_8 = insertelement <64 x i1> undef, i1 undef, i32 8
1027174cb7c6SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v64i1_15 = insertelement <64 x i1> undef, i1 undef, i32 15
1028174cb7c6SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v64i1_24 = insertelement <64 x i1> undef, i1 undef, i32 24
1029174cb7c6SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v64i1_31 = insertelement <64 x i1> undef, i1 undef, i32 31
1030174cb7c6SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v64i1_32 = insertelement <64 x i1> undef, i1 undef, i32 32
1031174cb7c6SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v64i1_48 = insertelement <64 x i1> undef, i1 undef, i32 48
1032174cb7c6SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %v64i1_63 = insertelement <64 x i1> undef, i1 undef, i32 63
1033174cb7c6SSimon Pilgrim; SSE3-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret i32 undef
1034174cb7c6SSimon Pilgrim;
1035174cb7c6SSimon Pilgrim; SSSE3-LABEL: 'insert_i1'
10365db826e4SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v2i1_a = insertelement <2 x i1> undef, i1 undef, i32 %arg
1037174cb7c6SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %v2i1_0 = insertelement <2 x i1> undef, i1 undef, i32 0
1038174cb7c6SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %v2i1_1 = insertelement <2 x i1> undef, i1 undef, i32 1
10395db826e4SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v4i1_a = insertelement <4 x i1> undef, i1 undef, i32 %arg
1040174cb7c6SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v4i1_0 = insertelement <4 x i1> undef, i1 undef, i32 0
1041174cb7c6SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v4i1_2 = insertelement <4 x i1> undef, i1 undef, i32 2
10425db826e4SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v8i1_a = insertelement <8 x i1> undef, i1 undef, i32 %arg
1043174cb7c6SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i1_0 = insertelement <8 x i1> undef, i1 undef, i32 0
1044174cb7c6SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i1_4 = insertelement <8 x i1> undef, i1 undef, i32 4
10455db826e4SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v16i1_a = insertelement <16 x i1> undef, i1 undef, i32 %arg
1046174cb7c6SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %v16i1_0 = insertelement <16 x i1> undef, i1 undef, i32 0
1047174cb7c6SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %v16i1_8 = insertelement <16 x i1> undef, i1 undef, i32 8
1048174cb7c6SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %v16i1_15 = insertelement <16 x i1> undef, i1 undef, i32 15
10495db826e4SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v32i1_a = insertelement <32 x i1> undef, i1 undef, i32 %arg
1050174cb7c6SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %v32i1_0 = insertelement <32 x i1> undef, i1 undef, i32 0
1051174cb7c6SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %v32i1_7 = insertelement <32 x i1> undef, i1 undef, i32 7
1052174cb7c6SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %v32i1_8 = insertelement <32 x i1> undef, i1 undef, i32 8
1053174cb7c6SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %v32i1_15 = insertelement <32 x i1> undef, i1 undef, i32 15
1054174cb7c6SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %v32i1_24 = insertelement <32 x i1> undef, i1 undef, i32 24
1055174cb7c6SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %v32i1_31 = insertelement <32 x i1> undef, i1 undef, i32 31
10565db826e4SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v64i1_a = insertelement <64 x i1> undef, i1 undef, i32 %arg
1057174cb7c6SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %v64i1_0 = insertelement <64 x i1> undef, i1 undef, i32 0
1058174cb7c6SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %v64i1_7 = insertelement <64 x i1> undef, i1 undef, i32 7
1059174cb7c6SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %v64i1_8 = insertelement <64 x i1> undef, i1 undef, i32 8
1060174cb7c6SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %v64i1_15 = insertelement <64 x i1> undef, i1 undef, i32 15
1061174cb7c6SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %v64i1_24 = insertelement <64 x i1> undef, i1 undef, i32 24
1062174cb7c6SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %v64i1_31 = insertelement <64 x i1> undef, i1 undef, i32 31
1063174cb7c6SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %v64i1_32 = insertelement <64 x i1> undef, i1 undef, i32 32
1064174cb7c6SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %v64i1_48 = insertelement <64 x i1> undef, i1 undef, i32 48
1065174cb7c6SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %v64i1_63 = insertelement <64 x i1> undef, i1 undef, i32 63
1066174cb7c6SSimon Pilgrim; SSSE3-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret i32 undef
1067174cb7c6SSimon Pilgrim;
1068174cb7c6SSimon Pilgrim; SSE4-LABEL: 'insert_i1'
10695db826e4SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v2i1_a = insertelement <2 x i1> undef, i1 undef, i32 %arg
1070174cb7c6SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v2i1_0 = insertelement <2 x i1> undef, i1 undef, i32 0
1071174cb7c6SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v2i1_1 = insertelement <2 x i1> undef, i1 undef, i32 1
10725db826e4SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v4i1_a = insertelement <4 x i1> undef, i1 undef, i32 %arg
1073174cb7c6SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v4i1_0 = insertelement <4 x i1> undef, i1 undef, i32 0
1074174cb7c6SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v4i1_2 = insertelement <4 x i1> undef, i1 undef, i32 2
10755db826e4SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v8i1_a = insertelement <8 x i1> undef, i1 undef, i32 %arg
1076174cb7c6SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i1_0 = insertelement <8 x i1> undef, i1 undef, i32 0
1077174cb7c6SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i1_4 = insertelement <8 x i1> undef, i1 undef, i32 4
10785db826e4SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v16i1_a = insertelement <16 x i1> undef, i1 undef, i32 %arg
1079174cb7c6SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16i1_0 = insertelement <16 x i1> undef, i1 undef, i32 0
1080174cb7c6SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16i1_8 = insertelement <16 x i1> undef, i1 undef, i32 8
1081174cb7c6SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16i1_15 = insertelement <16 x i1> undef, i1 undef, i32 15
10825db826e4SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v32i1_a = insertelement <32 x i1> undef, i1 undef, i32 %arg
1083174cb7c6SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i1_0 = insertelement <32 x i1> undef, i1 undef, i32 0
1084174cb7c6SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i1_7 = insertelement <32 x i1> undef, i1 undef, i32 7
1085174cb7c6SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i1_8 = insertelement <32 x i1> undef, i1 undef, i32 8
1086174cb7c6SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i1_15 = insertelement <32 x i1> undef, i1 undef, i32 15
1087174cb7c6SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i1_24 = insertelement <32 x i1> undef, i1 undef, i32 24
1088174cb7c6SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i1_31 = insertelement <32 x i1> undef, i1 undef, i32 31
10895db826e4SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v64i1_a = insertelement <64 x i1> undef, i1 undef, i32 %arg
1090174cb7c6SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i1_0 = insertelement <64 x i1> undef, i1 undef, i32 0
1091174cb7c6SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i1_7 = insertelement <64 x i1> undef, i1 undef, i32 7
1092174cb7c6SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i1_8 = insertelement <64 x i1> undef, i1 undef, i32 8
1093174cb7c6SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i1_15 = insertelement <64 x i1> undef, i1 undef, i32 15
1094174cb7c6SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i1_24 = insertelement <64 x i1> undef, i1 undef, i32 24
1095174cb7c6SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i1_31 = insertelement <64 x i1> undef, i1 undef, i32 31
1096174cb7c6SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i1_32 = insertelement <64 x i1> undef, i1 undef, i32 32
1097174cb7c6SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i1_48 = insertelement <64 x i1> undef, i1 undef, i32 48
1098174cb7c6SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i1_63 = insertelement <64 x i1> undef, i1 undef, i32 63
1099174cb7c6SSimon Pilgrim; SSE4-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret i32 undef
1100174cb7c6SSimon Pilgrim;
1101174cb7c6SSimon Pilgrim; AVX-LABEL: 'insert_i1'
11025db826e4SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v2i1_a = insertelement <2 x i1> undef, i1 undef, i32 %arg
1103174cb7c6SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v2i1_0 = insertelement <2 x i1> undef, i1 undef, i32 0
1104174cb7c6SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v2i1_1 = insertelement <2 x i1> undef, i1 undef, i32 1
11055db826e4SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v4i1_a = insertelement <4 x i1> undef, i1 undef, i32 %arg
1106174cb7c6SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v4i1_0 = insertelement <4 x i1> undef, i1 undef, i32 0
1107174cb7c6SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v4i1_2 = insertelement <4 x i1> undef, i1 undef, i32 2
11085db826e4SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v8i1_a = insertelement <8 x i1> undef, i1 undef, i32 %arg
1109174cb7c6SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i1_0 = insertelement <8 x i1> undef, i1 undef, i32 0
1110174cb7c6SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i1_4 = insertelement <8 x i1> undef, i1 undef, i32 4
11115db826e4SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v16i1_a = insertelement <16 x i1> undef, i1 undef, i32 %arg
1112174cb7c6SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16i1_0 = insertelement <16 x i1> undef, i1 undef, i32 0
1113174cb7c6SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16i1_8 = insertelement <16 x i1> undef, i1 undef, i32 8
1114174cb7c6SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16i1_15 = insertelement <16 x i1> undef, i1 undef, i32 15
11155db826e4SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v32i1_a = insertelement <32 x i1> undef, i1 undef, i32 %arg
1116174cb7c6SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i1_0 = insertelement <32 x i1> undef, i1 undef, i32 0
1117174cb7c6SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i1_7 = insertelement <32 x i1> undef, i1 undef, i32 7
1118174cb7c6SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i1_8 = insertelement <32 x i1> undef, i1 undef, i32 8
1119174cb7c6SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i1_15 = insertelement <32 x i1> undef, i1 undef, i32 15
1120174cb7c6SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v32i1_24 = insertelement <32 x i1> undef, i1 undef, i32 24
1121174cb7c6SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v32i1_31 = insertelement <32 x i1> undef, i1 undef, i32 31
11225db826e4SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v64i1_a = insertelement <64 x i1> undef, i1 undef, i32 %arg
1123174cb7c6SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i1_0 = insertelement <64 x i1> undef, i1 undef, i32 0
1124174cb7c6SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i1_7 = insertelement <64 x i1> undef, i1 undef, i32 7
1125174cb7c6SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i1_8 = insertelement <64 x i1> undef, i1 undef, i32 8
1126174cb7c6SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i1_15 = insertelement <64 x i1> undef, i1 undef, i32 15
1127174cb7c6SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v64i1_24 = insertelement <64 x i1> undef, i1 undef, i32 24
1128174cb7c6SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v64i1_31 = insertelement <64 x i1> undef, i1 undef, i32 31
1129174cb7c6SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i1_32 = insertelement <64 x i1> undef, i1 undef, i32 32
1130174cb7c6SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v64i1_48 = insertelement <64 x i1> undef, i1 undef, i32 48
1131174cb7c6SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v64i1_63 = insertelement <64 x i1> undef, i1 undef, i32 63
1132174cb7c6SSimon Pilgrim; AVX-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret i32 undef
1133174cb7c6SSimon Pilgrim;
11345db826e4SSimon Pilgrim; AVX512F-LABEL: 'insert_i1'
11355db826e4SSimon Pilgrim; AVX512F-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v2i1_a = insertelement <2 x i1> undef, i1 undef, i32 %arg
11365db826e4SSimon Pilgrim; AVX512F-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v2i1_0 = insertelement <2 x i1> undef, i1 undef, i32 0
11375db826e4SSimon Pilgrim; AVX512F-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v2i1_1 = insertelement <2 x i1> undef, i1 undef, i32 1
11385db826e4SSimon Pilgrim; AVX512F-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v4i1_a = insertelement <4 x i1> undef, i1 undef, i32 %arg
11395db826e4SSimon Pilgrim; AVX512F-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v4i1_0 = insertelement <4 x i1> undef, i1 undef, i32 0
11405db826e4SSimon Pilgrim; AVX512F-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v4i1_2 = insertelement <4 x i1> undef, i1 undef, i32 2
11415db826e4SSimon Pilgrim; AVX512F-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v8i1_a = insertelement <8 x i1> undef, i1 undef, i32 %arg
11425db826e4SSimon Pilgrim; AVX512F-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i1_0 = insertelement <8 x i1> undef, i1 undef, i32 0
11435db826e4SSimon Pilgrim; AVX512F-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i1_4 = insertelement <8 x i1> undef, i1 undef, i32 4
11445db826e4SSimon Pilgrim; AVX512F-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v16i1_a = insertelement <16 x i1> undef, i1 undef, i32 %arg
11455db826e4SSimon Pilgrim; AVX512F-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16i1_0 = insertelement <16 x i1> undef, i1 undef, i32 0
11465db826e4SSimon Pilgrim; AVX512F-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16i1_8 = insertelement <16 x i1> undef, i1 undef, i32 8
11475db826e4SSimon Pilgrim; AVX512F-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16i1_15 = insertelement <16 x i1> undef, i1 undef, i32 15
11485db826e4SSimon Pilgrim; AVX512F-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %v32i1_a = insertelement <32 x i1> undef, i1 undef, i32 %arg
11495db826e4SSimon Pilgrim; AVX512F-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i1_0 = insertelement <32 x i1> undef, i1 undef, i32 0
11505db826e4SSimon Pilgrim; AVX512F-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i1_7 = insertelement <32 x i1> undef, i1 undef, i32 7
11515db826e4SSimon Pilgrim; AVX512F-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i1_8 = insertelement <32 x i1> undef, i1 undef, i32 8
11525db826e4SSimon Pilgrim; AVX512F-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i1_15 = insertelement <32 x i1> undef, i1 undef, i32 15
11535db826e4SSimon Pilgrim; AVX512F-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i1_24 = insertelement <32 x i1> undef, i1 undef, i32 24
11545db826e4SSimon Pilgrim; AVX512F-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i1_31 = insertelement <32 x i1> undef, i1 undef, i32 31
11555db826e4SSimon Pilgrim; AVX512F-NEXT:  Cost Model: Found an estimated cost of 9 for instruction: %v64i1_a = insertelement <64 x i1> undef, i1 undef, i32 %arg
11565db826e4SSimon Pilgrim; AVX512F-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i1_0 = insertelement <64 x i1> undef, i1 undef, i32 0
11575db826e4SSimon Pilgrim; AVX512F-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i1_7 = insertelement <64 x i1> undef, i1 undef, i32 7
11585db826e4SSimon Pilgrim; AVX512F-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i1_8 = insertelement <64 x i1> undef, i1 undef, i32 8
11595db826e4SSimon Pilgrim; AVX512F-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i1_15 = insertelement <64 x i1> undef, i1 undef, i32 15
11605db826e4SSimon Pilgrim; AVX512F-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i1_24 = insertelement <64 x i1> undef, i1 undef, i32 24
11615db826e4SSimon Pilgrim; AVX512F-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i1_31 = insertelement <64 x i1> undef, i1 undef, i32 31
11625db826e4SSimon Pilgrim; AVX512F-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i1_32 = insertelement <64 x i1> undef, i1 undef, i32 32
11635db826e4SSimon Pilgrim; AVX512F-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i1_48 = insertelement <64 x i1> undef, i1 undef, i32 48
11645db826e4SSimon Pilgrim; AVX512F-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i1_63 = insertelement <64 x i1> undef, i1 undef, i32 63
11655db826e4SSimon Pilgrim; AVX512F-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret i32 undef
11665db826e4SSimon Pilgrim;
11675db826e4SSimon Pilgrim; AVX512BW-LABEL: 'insert_i1'
11685db826e4SSimon Pilgrim; AVX512BW-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v2i1_a = insertelement <2 x i1> undef, i1 undef, i32 %arg
11695db826e4SSimon Pilgrim; AVX512BW-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v2i1_0 = insertelement <2 x i1> undef, i1 undef, i32 0
11705db826e4SSimon Pilgrim; AVX512BW-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v2i1_1 = insertelement <2 x i1> undef, i1 undef, i32 1
11715db826e4SSimon Pilgrim; AVX512BW-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v4i1_a = insertelement <4 x i1> undef, i1 undef, i32 %arg
11725db826e4SSimon Pilgrim; AVX512BW-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v4i1_0 = insertelement <4 x i1> undef, i1 undef, i32 0
11735db826e4SSimon Pilgrim; AVX512BW-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v4i1_2 = insertelement <4 x i1> undef, i1 undef, i32 2
11745db826e4SSimon Pilgrim; AVX512BW-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v8i1_a = insertelement <8 x i1> undef, i1 undef, i32 %arg
11755db826e4SSimon Pilgrim; AVX512BW-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i1_0 = insertelement <8 x i1> undef, i1 undef, i32 0
11765db826e4SSimon Pilgrim; AVX512BW-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i1_4 = insertelement <8 x i1> undef, i1 undef, i32 4
11775db826e4SSimon Pilgrim; AVX512BW-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v16i1_a = insertelement <16 x i1> undef, i1 undef, i32 %arg
11785db826e4SSimon Pilgrim; AVX512BW-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16i1_0 = insertelement <16 x i1> undef, i1 undef, i32 0
11795db826e4SSimon Pilgrim; AVX512BW-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16i1_8 = insertelement <16 x i1> undef, i1 undef, i32 8
11805db826e4SSimon Pilgrim; AVX512BW-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16i1_15 = insertelement <16 x i1> undef, i1 undef, i32 15
11815db826e4SSimon Pilgrim; AVX512BW-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v32i1_a = insertelement <32 x i1> undef, i1 undef, i32 %arg
11825db826e4SSimon Pilgrim; AVX512BW-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i1_0 = insertelement <32 x i1> undef, i1 undef, i32 0
11835db826e4SSimon Pilgrim; AVX512BW-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i1_7 = insertelement <32 x i1> undef, i1 undef, i32 7
11845db826e4SSimon Pilgrim; AVX512BW-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i1_8 = insertelement <32 x i1> undef, i1 undef, i32 8
11855db826e4SSimon Pilgrim; AVX512BW-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i1_15 = insertelement <32 x i1> undef, i1 undef, i32 15
11865db826e4SSimon Pilgrim; AVX512BW-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i1_24 = insertelement <32 x i1> undef, i1 undef, i32 24
11875db826e4SSimon Pilgrim; AVX512BW-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i1_31 = insertelement <32 x i1> undef, i1 undef, i32 31
11885db826e4SSimon Pilgrim; AVX512BW-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v64i1_a = insertelement <64 x i1> undef, i1 undef, i32 %arg
11895db826e4SSimon Pilgrim; AVX512BW-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i1_0 = insertelement <64 x i1> undef, i1 undef, i32 0
11905db826e4SSimon Pilgrim; AVX512BW-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i1_7 = insertelement <64 x i1> undef, i1 undef, i32 7
11915db826e4SSimon Pilgrim; AVX512BW-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i1_8 = insertelement <64 x i1> undef, i1 undef, i32 8
11925db826e4SSimon Pilgrim; AVX512BW-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i1_15 = insertelement <64 x i1> undef, i1 undef, i32 15
11935db826e4SSimon Pilgrim; AVX512BW-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i1_24 = insertelement <64 x i1> undef, i1 undef, i32 24
11945db826e4SSimon Pilgrim; AVX512BW-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i1_31 = insertelement <64 x i1> undef, i1 undef, i32 31
11955db826e4SSimon Pilgrim; AVX512BW-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i1_32 = insertelement <64 x i1> undef, i1 undef, i32 32
11965db826e4SSimon Pilgrim; AVX512BW-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i1_48 = insertelement <64 x i1> undef, i1 undef, i32 48
11975db826e4SSimon Pilgrim; AVX512BW-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i1_63 = insertelement <64 x i1> undef, i1 undef, i32 63
11985db826e4SSimon Pilgrim; AVX512BW-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret i32 undef
1199174cb7c6SSimon Pilgrim;
1200174cb7c6SSimon Pilgrim; SLM-LABEL: 'insert_i1'
12015db826e4SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v2i1_a = insertelement <2 x i1> undef, i1 undef, i32 %arg
1202174cb7c6SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v2i1_0 = insertelement <2 x i1> undef, i1 undef, i32 0
1203174cb7c6SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v2i1_1 = insertelement <2 x i1> undef, i1 undef, i32 1
12045db826e4SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v4i1_a = insertelement <4 x i1> undef, i1 undef, i32 %arg
1205174cb7c6SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v4i1_0 = insertelement <4 x i1> undef, i1 undef, i32 0
1206174cb7c6SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v4i1_2 = insertelement <4 x i1> undef, i1 undef, i32 2
12075db826e4SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v8i1_a = insertelement <8 x i1> undef, i1 undef, i32 %arg
1208174cb7c6SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i1_0 = insertelement <8 x i1> undef, i1 undef, i32 0
1209174cb7c6SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i1_4 = insertelement <8 x i1> undef, i1 undef, i32 4
12105db826e4SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v16i1_a = insertelement <16 x i1> undef, i1 undef, i32 %arg
1211174cb7c6SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16i1_0 = insertelement <16 x i1> undef, i1 undef, i32 0
1212174cb7c6SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16i1_8 = insertelement <16 x i1> undef, i1 undef, i32 8
1213174cb7c6SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16i1_15 = insertelement <16 x i1> undef, i1 undef, i32 15
12145db826e4SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v32i1_a = insertelement <32 x i1> undef, i1 undef, i32 %arg
1215174cb7c6SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i1_0 = insertelement <32 x i1> undef, i1 undef, i32 0
1216174cb7c6SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i1_7 = insertelement <32 x i1> undef, i1 undef, i32 7
1217174cb7c6SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i1_8 = insertelement <32 x i1> undef, i1 undef, i32 8
1218174cb7c6SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i1_15 = insertelement <32 x i1> undef, i1 undef, i32 15
1219174cb7c6SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i1_24 = insertelement <32 x i1> undef, i1 undef, i32 24
1220174cb7c6SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i1_31 = insertelement <32 x i1> undef, i1 undef, i32 31
12215db826e4SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v64i1_a = insertelement <64 x i1> undef, i1 undef, i32 %arg
1222174cb7c6SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i1_0 = insertelement <64 x i1> undef, i1 undef, i32 0
1223174cb7c6SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i1_7 = insertelement <64 x i1> undef, i1 undef, i32 7
1224174cb7c6SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i1_8 = insertelement <64 x i1> undef, i1 undef, i32 8
1225174cb7c6SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i1_15 = insertelement <64 x i1> undef, i1 undef, i32 15
1226174cb7c6SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i1_24 = insertelement <64 x i1> undef, i1 undef, i32 24
1227174cb7c6SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i1_31 = insertelement <64 x i1> undef, i1 undef, i32 31
1228174cb7c6SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i1_32 = insertelement <64 x i1> undef, i1 undef, i32 32
1229174cb7c6SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i1_48 = insertelement <64 x i1> undef, i1 undef, i32 48
1230174cb7c6SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i1_63 = insertelement <64 x i1> undef, i1 undef, i32 63
1231174cb7c6SSimon Pilgrim; SLM-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret i32 undef
1232174cb7c6SSimon Pilgrim;
1233174cb7c6SSimon Pilgrim; GLM-LABEL: 'insert_i1'
12345db826e4SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v2i1_a = insertelement <2 x i1> undef, i1 undef, i32 %arg
1235174cb7c6SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v2i1_0 = insertelement <2 x i1> undef, i1 undef, i32 0
1236174cb7c6SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v2i1_1 = insertelement <2 x i1> undef, i1 undef, i32 1
12375db826e4SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v4i1_a = insertelement <4 x i1> undef, i1 undef, i32 %arg
1238174cb7c6SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v4i1_0 = insertelement <4 x i1> undef, i1 undef, i32 0
1239174cb7c6SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v4i1_2 = insertelement <4 x i1> undef, i1 undef, i32 2
12405db826e4SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v8i1_a = insertelement <8 x i1> undef, i1 undef, i32 %arg
1241174cb7c6SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i1_0 = insertelement <8 x i1> undef, i1 undef, i32 0
1242174cb7c6SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v8i1_4 = insertelement <8 x i1> undef, i1 undef, i32 4
12435db826e4SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v16i1_a = insertelement <16 x i1> undef, i1 undef, i32 %arg
1244174cb7c6SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16i1_0 = insertelement <16 x i1> undef, i1 undef, i32 0
1245174cb7c6SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16i1_8 = insertelement <16 x i1> undef, i1 undef, i32 8
1246174cb7c6SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v16i1_15 = insertelement <16 x i1> undef, i1 undef, i32 15
12475db826e4SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v32i1_a = insertelement <32 x i1> undef, i1 undef, i32 %arg
1248174cb7c6SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i1_0 = insertelement <32 x i1> undef, i1 undef, i32 0
1249174cb7c6SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i1_7 = insertelement <32 x i1> undef, i1 undef, i32 7
1250174cb7c6SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i1_8 = insertelement <32 x i1> undef, i1 undef, i32 8
1251174cb7c6SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i1_15 = insertelement <32 x i1> undef, i1 undef, i32 15
1252174cb7c6SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i1_24 = insertelement <32 x i1> undef, i1 undef, i32 24
1253174cb7c6SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v32i1_31 = insertelement <32 x i1> undef, i1 undef, i32 31
12545db826e4SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %v64i1_a = insertelement <64 x i1> undef, i1 undef, i32 %arg
1255174cb7c6SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i1_0 = insertelement <64 x i1> undef, i1 undef, i32 0
1256174cb7c6SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i1_7 = insertelement <64 x i1> undef, i1 undef, i32 7
1257174cb7c6SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i1_8 = insertelement <64 x i1> undef, i1 undef, i32 8
1258174cb7c6SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i1_15 = insertelement <64 x i1> undef, i1 undef, i32 15
1259174cb7c6SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i1_24 = insertelement <64 x i1> undef, i1 undef, i32 24
1260174cb7c6SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i1_31 = insertelement <64 x i1> undef, i1 undef, i32 31
1261174cb7c6SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i1_32 = insertelement <64 x i1> undef, i1 undef, i32 32
1262174cb7c6SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i1_48 = insertelement <64 x i1> undef, i1 undef, i32 48
1263174cb7c6SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %v64i1_63 = insertelement <64 x i1> undef, i1 undef, i32 63
1264174cb7c6SSimon Pilgrim; GLM-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret i32 undef
1265174cb7c6SSimon Pilgrim;
1266174cb7c6SSimon Pilgrim  %v2i1_a  = insertelement <2 x i1> undef, i1 undef, i32 %arg
1267174cb7c6SSimon Pilgrim  %v2i1_0  = insertelement <2 x i1> undef, i1 undef, i32 0
1268174cb7c6SSimon Pilgrim  %v2i1_1  = insertelement <2 x i1> undef, i1 undef, i32 1
1269174cb7c6SSimon Pilgrim
1270174cb7c6SSimon Pilgrim  %v4i1_a  = insertelement <4 x i1> undef, i1 undef, i32 %arg
1271174cb7c6SSimon Pilgrim  %v4i1_0  = insertelement <4 x i1> undef, i1 undef, i32 0
1272174cb7c6SSimon Pilgrim  %v4i1_2  = insertelement <4 x i1> undef, i1 undef, i32 2
1273174cb7c6SSimon Pilgrim
1274174cb7c6SSimon Pilgrim  %v8i1_a  = insertelement <8 x i1> undef, i1 undef, i32 %arg
1275174cb7c6SSimon Pilgrim  %v8i1_0  = insertelement <8 x i1> undef, i1 undef, i32 0
1276174cb7c6SSimon Pilgrim  %v8i1_4  = insertelement <8 x i1> undef, i1 undef, i32 4
1277174cb7c6SSimon Pilgrim
1278174cb7c6SSimon Pilgrim  %v16i1_a  = insertelement <16 x i1> undef, i1 undef, i32 %arg
1279174cb7c6SSimon Pilgrim  %v16i1_0  = insertelement <16 x i1> undef, i1 undef, i32 0
1280174cb7c6SSimon Pilgrim  %v16i1_8  = insertelement <16 x i1> undef, i1 undef, i32 8
1281174cb7c6SSimon Pilgrim  %v16i1_15 = insertelement <16 x i1> undef, i1 undef, i32 15
1282174cb7c6SSimon Pilgrim
1283174cb7c6SSimon Pilgrim  %v32i1_a  = insertelement <32 x i1> undef, i1 undef, i32 %arg
1284174cb7c6SSimon Pilgrim  %v32i1_0  = insertelement <32 x i1> undef, i1 undef, i32 0
1285174cb7c6SSimon Pilgrim  %v32i1_7  = insertelement <32 x i1> undef, i1 undef, i32 7
1286174cb7c6SSimon Pilgrim  %v32i1_8  = insertelement <32 x i1> undef, i1 undef, i32 8
1287174cb7c6SSimon Pilgrim  %v32i1_15 = insertelement <32 x i1> undef, i1 undef, i32 15
1288174cb7c6SSimon Pilgrim  %v32i1_24 = insertelement <32 x i1> undef, i1 undef, i32 24
1289174cb7c6SSimon Pilgrim  %v32i1_31 = insertelement <32 x i1> undef, i1 undef, i32 31
1290174cb7c6SSimon Pilgrim
1291174cb7c6SSimon Pilgrim  %v64i1_a  = insertelement <64 x i1> undef, i1 undef, i32 %arg
1292174cb7c6SSimon Pilgrim  %v64i1_0  = insertelement <64 x i1> undef, i1 undef, i32 0
1293174cb7c6SSimon Pilgrim  %v64i1_7  = insertelement <64 x i1> undef, i1 undef, i32 7
1294174cb7c6SSimon Pilgrim  %v64i1_8  = insertelement <64 x i1> undef, i1 undef, i32 8
1295174cb7c6SSimon Pilgrim  %v64i1_15 = insertelement <64 x i1> undef, i1 undef, i32 15
1296174cb7c6SSimon Pilgrim  %v64i1_24 = insertelement <64 x i1> undef, i1 undef, i32 24
1297174cb7c6SSimon Pilgrim  %v64i1_31 = insertelement <64 x i1> undef, i1 undef, i32 31
1298174cb7c6SSimon Pilgrim  %v64i1_32 = insertelement <64 x i1> undef, i1 undef, i32 32
1299174cb7c6SSimon Pilgrim  %v64i1_48 = insertelement <64 x i1> undef, i1 undef, i32 48
1300174cb7c6SSimon Pilgrim  %v64i1_63 = insertelement <64 x i1> undef, i1 undef, i32 63
1301174cb7c6SSimon Pilgrim
1302174cb7c6SSimon Pilgrim  ret i32 undef
1303174cb7c6SSimon Pilgrim}
1304