llvm.org GIT mirror llvm / 18a1f6e
[X86][AVX1] Account for cost of extract/insert of 256-bit shifts git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@303023 91177308-0d34-0410-b5e6-96231b3b80d8 Simon Pilgrim 3 years ago
4 changed file(s) with 101 addition(s) and 101 deletion(s). Raw diff Collapse all Expand all
588588 return LT.first * Entry->Cost;
589589
590590 static const CostTblEntry SSE41CostTable[] = {
591 { ISD::SHL, MVT::v16i8, 11 }, // pblendvb sequence.
592 { ISD::SHL, MVT::v32i8, 2*11 }, // pblendvb sequence.
593 { ISD::SHL, MVT::v8i16, 14 }, // pblendvb sequence.
594 { ISD::SHL, MVT::v16i16, 2*14 }, // pblendvb sequence.
595 { ISD::SHL, MVT::v4i32, 4 }, // pslld/paddd/cvttps2dq/pmulld
596 { ISD::SHL, MVT::v8i32, 2*4 }, // pslld/paddd/cvttps2dq/pmulld
597
598 { ISD::SRL, MVT::v16i8, 12 }, // pblendvb sequence.
599 { ISD::SRL, MVT::v32i8, 2*12 }, // pblendvb sequence.
600 { ISD::SRL, MVT::v8i16, 14 }, // pblendvb sequence.
601 { ISD::SRL, MVT::v16i16, 2*14 }, // pblendvb sequence.
602 { ISD::SRL, MVT::v4i32, 11 }, // Shift each lane + blend.
603 { ISD::SRL, MVT::v8i32, 2*11 }, // Shift each lane + blend.
604
605 { ISD::SRA, MVT::v16i8, 24 }, // pblendvb sequence.
606 { ISD::SRA, MVT::v32i8, 2*24 }, // pblendvb sequence.
607 { ISD::SRA, MVT::v8i16, 14 }, // pblendvb sequence.
608 { ISD::SRA, MVT::v16i16, 2*14 }, // pblendvb sequence.
609 { ISD::SRA, MVT::v4i32, 12 }, // Shift each lane + blend.
610 { ISD::SRA, MVT::v8i32, 2*12 }, // Shift each lane + blend.
611
612 { ISD::MUL, MVT::v4i32, 1 } // pmulld
591 { ISD::SHL, MVT::v16i8, 11 }, // pblendvb sequence.
592 { ISD::SHL, MVT::v32i8, 2*11+2 }, // pblendvb sequence + split.
593 { ISD::SHL, MVT::v8i16, 14 }, // pblendvb sequence.
594 { ISD::SHL, MVT::v16i16, 2*14+2 }, // pblendvb sequence + split.
595 { ISD::SHL, MVT::v4i32, 4 }, // pslld/paddd/cvttps2dq/pmulld
596 { ISD::SHL, MVT::v8i32, 2*4+2 }, // pslld/paddd/cvttps2dq/pmulld + split
597
598 { ISD::SRL, MVT::v16i8, 12 }, // pblendvb sequence.
599 { ISD::SRL, MVT::v32i8, 2*12+2 }, // pblendvb sequence + split.
600 { ISD::SRL, MVT::v8i16, 14 }, // pblendvb sequence.
601 { ISD::SRL, MVT::v16i16, 2*14+2 }, // pblendvb sequence + split.
602 { ISD::SRL, MVT::v4i32, 11 }, // Shift each lane + blend.
603 { ISD::SRL, MVT::v8i32, 2*11+2 }, // Shift each lane + blend + split.
604
605 { ISD::SRA, MVT::v16i8, 24 }, // pblendvb sequence.
606 { ISD::SRA, MVT::v32i8, 2*24+2 }, // pblendvb sequence + split.
607 { ISD::SRA, MVT::v8i16, 14 }, // pblendvb sequence.
608 { ISD::SRA, MVT::v16i16, 2*14+2 }, // pblendvb sequence + split.
609 { ISD::SRA, MVT::v4i32, 12 }, // Shift each lane + blend.
610 { ISD::SRA, MVT::v8i32, 2*12+2 }, // Shift each lane + blend + split.
611
612 { ISD::MUL, MVT::v4i32, 1 } // pmulld
613613 };
614614
615615 if (ST->hasSSE41())
619619 static const CostTblEntry SSE2CostTable[] = {
620620 // We don't correctly identify costs of casts because they are marked as
621621 // custom.
622 { ISD::SHL, MVT::v16i8, 26 }, // cmpgtb sequence.
623 { ISD::SHL, MVT::v8i16, 32 }, // cmpgtb sequence.
624 { ISD::SHL, MVT::v4i32, 2*5 }, // We optimized this using mul.
625 { ISD::SHL, MVT::v2i64, 4 }, // splat+shuffle sequence.
626 { ISD::SHL, MVT::v4i64, 2*4 }, // splat+shuffle sequence.
627
628 { ISD::SRL, MVT::v16i8, 26 }, // cmpgtb sequence.
629 { ISD::SRL, MVT::v8i16, 32 }, // cmpgtb sequence.
630 { ISD::SRL, MVT::v4i32, 16 }, // Shift each lane + blend.
631 { ISD::SRL, MVT::v2i64, 4 }, // splat+shuffle sequence.
632 { ISD::SRL, MVT::v4i64, 2*4 }, // splat+shuffle sequence.
633
634 { ISD::SRA, MVT::v16i8, 54 }, // unpacked cmpgtb sequence.
635 { ISD::SRA, MVT::v8i16, 32 }, // cmpgtb sequence.
636 { ISD::SRA, MVT::v4i32, 16 }, // Shift each lane + blend.
637 { ISD::SRA, MVT::v2i64, 12 }, // srl/xor/sub sequence.
638 { ISD::SRA, MVT::v4i64, 2*12 }, // srl/xor/sub sequence.
639
640 { ISD::MUL, MVT::v16i8, 12 }, // extend/pmullw/trunc sequence.
641 { ISD::MUL, MVT::v8i16, 1 }, // pmullw
642 { ISD::MUL, MVT::v4i32, 6 }, // 3*pmuludq/4*shuffle
643 { ISD::MUL, MVT::v2i64, 8 }, // 3*pmuludq/3*shift/2*add
644
645 { ISD::FDIV, MVT::f32, 23 }, // Pentium IV from http://www.agner.org/
646 { ISD::FDIV, MVT::v4f32, 39 }, // Pentium IV from http://www.agner.org/
647 { ISD::FDIV, MVT::f64, 38 }, // Pentium IV from http://www.agner.org/
648 { ISD::FDIV, MVT::v2f64, 69 }, // Pentium IV from http://www.agner.org/
622 { ISD::SHL, MVT::v16i8, 26 }, // cmpgtb sequence.
623 { ISD::SHL, MVT::v8i16, 32 }, // cmpgtb sequence.
624 { ISD::SHL, MVT::v4i32, 2*5 }, // We optimized this using mul.
625 { ISD::SHL, MVT::v2i64, 4 }, // splat+shuffle sequence.
626 { ISD::SHL, MVT::v4i64, 2*4+2 }, // splat+shuffle sequence + split.
627
628 { ISD::SRL, MVT::v16i8, 26 }, // cmpgtb sequence.
629 { ISD::SRL, MVT::v8i16, 32 }, // cmpgtb sequence.
630 { ISD::SRL, MVT::v4i32, 16 }, // Shift each lane + blend.
631 { ISD::SRL, MVT::v2i64, 4 }, // splat+shuffle sequence.
632 { ISD::SRL, MVT::v4i64, 2*4+2 }, // splat+shuffle sequence + split.
633
634 { ISD::SRA, MVT::v16i8, 54 }, // unpacked cmpgtb sequence.
635 { ISD::SRA, MVT::v8i16, 32 }, // cmpgtb sequence.
636 { ISD::SRA, MVT::v4i32, 16 }, // Shift each lane + blend.
637 { ISD::SRA, MVT::v2i64, 12 }, // srl/xor/sub sequence.
638 { ISD::SRA, MVT::v4i64, 2*12+2 }, // srl/xor/sub sequence+split.
639
640 { ISD::MUL, MVT::v16i8, 12 }, // extend/pmullw/trunc sequence.
641 { ISD::MUL, MVT::v8i16, 1 }, // pmullw
642 { ISD::MUL, MVT::v4i32, 6 }, // 3*pmuludq/4*shuffle
643 { ISD::MUL, MVT::v2i64, 8 }, // 3*pmuludq/3*shift/2*add
644
645 { ISD::FDIV, MVT::f32, 23 }, // Pentium IV from http://www.agner.org/
646 { ISD::FDIV, MVT::v4f32, 39 }, // Pentium IV from http://www.agner.org/
647 { ISD::FDIV, MVT::f64, 38 }, // Pentium IV from http://www.agner.org/
648 { ISD::FDIV, MVT::v2f64, 69 }, // Pentium IV from http://www.agner.org/
649649
650650 // It is not a good idea to vectorize division. We have to scalarize it and
651651 // in the process we will often end up having to spilling regular
3232 ; CHECK: 'Cost Model Analysis' for function 'var_shift_v4i64':
3333 ; SSE2: Found an estimated cost of 24 for instruction: %shift
3434 ; SSE41: Found an estimated cost of 24 for instruction: %shift
35 ; AVX: Found an estimated cost of 24 for instruction: %shift
35 ; AVX: Found an estimated cost of 26 for instruction: %shift
3636 ; AVX2: Found an estimated cost of 4 for instruction: %shift
3737 ; AVX512: Found an estimated cost of 1 for instruction: %shift
3838 ; XOP: Found an estimated cost of 6 for instruction: %shift
4444 ; CHECK: 'Cost Model Analysis' for function 'var_shift_v8i64':
4545 ; SSE2: Found an estimated cost of 48 for instruction: %shift
4646 ; SSE41: Found an estimated cost of 48 for instruction: %shift
47 ; AVX: Found an estimated cost of 48 for instruction: %shift
47 ; AVX: Found an estimated cost of 52 for instruction: %shift
4848 ; AVX2: Found an estimated cost of 8 for instruction: %shift
4949 ; AVX512: Found an estimated cost of 1 for instruction: %shift
5050 ; XOP: Found an estimated cost of 12 for instruction: %shift
6969 ; CHECK: 'Cost Model Analysis' for function 'var_shift_v8i32':
7070 ; SSE2: Found an estimated cost of 32 for instruction: %shift
7171 ; SSE41: Found an estimated cost of 24 for instruction: %shift
72 ; AVX: Found an estimated cost of 24 for instruction: %shift
72 ; AVX: Found an estimated cost of 26 for instruction: %shift
7373 ; AVX2: Found an estimated cost of 1 for instruction: %shift
7474 ; AVX512: Found an estimated cost of 1 for instruction: %shift
7575 ; XOPAVX: Found an estimated cost of 6 for instruction: %shift
8282 ; CHECK: 'Cost Model Analysis' for function 'var_shift_v16i32':
8383 ; SSE2: Found an estimated cost of 64 for instruction: %shift
8484 ; SSE41: Found an estimated cost of 48 for instruction: %shift
85 ; AVX: Found an estimated cost of 48 for instruction: %shift
85 ; AVX: Found an estimated cost of 52 for instruction: %shift
8686 ; AVX2: Found an estimated cost of 2 for instruction: %shift
8787 ; AVX512: Found an estimated cost of 1 for instruction: %shift
8888 ; XOPAVX: Found an estimated cost of 12 for instruction: %shift
108108 ; CHECK: 'Cost Model Analysis' for function 'var_shift_v16i16':
109109 ; SSE2: Found an estimated cost of 64 for instruction: %shift
110110 ; SSE41: Found an estimated cost of 28 for instruction: %shift
111 ; AVX: Found an estimated cost of 28 for instruction: %shift
111 ; AVX: Found an estimated cost of 30 for instruction: %shift
112112 ; AVX2: Found an estimated cost of 10 for instruction: %shift
113113 ; AVX512F: Found an estimated cost of 10 for instruction: %shift
114114 ; AVX512BW: Found an estimated cost of 1 for instruction: %shift
121121 ; CHECK: 'Cost Model Analysis' for function 'var_shift_v32i16':
122122 ; SSE2: Found an estimated cost of 128 for instruction: %shift
123123 ; SSE41: Found an estimated cost of 56 for instruction: %shift
124 ; AVX: Found an estimated cost of 56 for instruction: %shift
124 ; AVX: Found an estimated cost of 60 for instruction: %shift
125125 ; AVX2: Found an estimated cost of 20 for instruction: %shift
126126 ; AVX512F: Found an estimated cost of 20 for instruction: %shift
127127 ; AVX512BW: Found an estimated cost of 1 for instruction: %shift
146146 ; CHECK: 'Cost Model Analysis' for function 'var_shift_v32i8':
147147 ; SSE2: Found an estimated cost of 108 for instruction: %shift
148148 ; SSE41: Found an estimated cost of 48 for instruction: %shift
149 ; AVX: Found an estimated cost of 48 for instruction: %shift
149 ; AVX: Found an estimated cost of 50 for instruction: %shift
150150 ; AVX2: Found an estimated cost of 24 for instruction: %shift
151151 ; AVX512F: Found an estimated cost of 24 for instruction: %shift
152152 ; AVX512BW: Found an estimated cost of 24 for instruction: %shift
159159 ; CHECK: 'Cost Model Analysis' for function 'var_shift_v64i8':
160160 ; SSE2: Found an estimated cost of 216 for instruction: %shift
161161 ; SSE41: Found an estimated cost of 96 for instruction: %shift
162 ; AVX: Found an estimated cost of 96 for instruction: %shift
162 ; AVX: Found an estimated cost of 100 for instruction: %shift
163163 ; AVX2: Found an estimated cost of 48 for instruction: %shift
164164 ; AVX512F: Found an estimated cost of 48 for instruction: %shift
165165 ; AVX512BW: Found an estimated cost of 24 for instruction: %shift
321321 ; CHECK: 'Cost Model Analysis' for function 'splatvar_shift_v32i8':
322322 ; SSE2: Found an estimated cost of 108 for instruction: %shift
323323 ; SSE41: Found an estimated cost of 48 for instruction: %shift
324 ; AVX: Found an estimated cost of 48 for instruction: %shift
324 ; AVX: Found an estimated cost of 50 for instruction: %shift
325325 ; AVX2: Found an estimated cost of 24 for instruction: %shift
326326 ; AVX512: Found an estimated cost of 24 for instruction: %shift
327327 ; XOP: Found an estimated cost of 6 for instruction: %shift
335335 ; CHECK: 'Cost Model Analysis' for function 'splatvar_shift_v64i8':
336336 ; SSE2: Found an estimated cost of 216 for instruction: %shift
337337 ; SSE41: Found an estimated cost of 96 for instruction: %shift
338 ; AVX: Found an estimated cost of 96 for instruction: %shift
338 ; AVX: Found an estimated cost of 100 for instruction: %shift
339339 ; AVX2: Found an estimated cost of 48 for instruction: %shift
340340 ; AVX512F: Found an estimated cost of 48 for instruction: %shift
341341 ; AVX512BW: Found an estimated cost of 24 for instruction: %shift
366366 ; CHECK: 'Cost Model Analysis' for function 'constant_shift_v4i64':
367367 ; SSE2: Found an estimated cost of 24 for instruction: %shift
368368 ; SSE41: Found an estimated cost of 24 for instruction: %shift
369 ; AVX: Found an estimated cost of 24 for instruction: %shift
369 ; AVX: Found an estimated cost of 26 for instruction: %shift
370370 ; AVX2: Found an estimated cost of 4 for instruction: %shift
371371 ; AVX512: Found an estimated cost of 1 for instruction: %shift
372372 ; XOP: Found an estimated cost of 6 for instruction: %shift
378378 ; CHECK: 'Cost Model Analysis' for function 'constant_shift_v8i64':
379379 ; SSE2: Found an estimated cost of 48 for instruction: %shift
380380 ; SSE41: Found an estimated cost of 48 for instruction: %shift
381 ; AVX: Found an estimated cost of 48 for instruction: %shift
381 ; AVX: Found an estimated cost of 52 for instruction: %shift
382382 ; AVX2: Found an estimated cost of 8 for instruction: %shift
383383 ; AVX512: Found an estimated cost of 1 for instruction: %shift
384384 ; XOP: Found an estimated cost of 12 for instruction: %shift
403403 ; CHECK: 'Cost Model Analysis' for function 'constant_shift_v8i32':
404404 ; SSE2: Found an estimated cost of 32 for instruction: %shift
405405 ; SSE41: Found an estimated cost of 24 for instruction: %shift
406 ; AVX: Found an estimated cost of 24 for instruction: %shift
406 ; AVX: Found an estimated cost of 26 for instruction: %shift
407407 ; AVX2: Found an estimated cost of 1 for instruction: %shift
408408 ; AVX512: Found an estimated cost of 1 for instruction: %shift
409409 ; XOPAVX: Found an estimated cost of 6 for instruction: %shift
416416 ; CHECK: 'Cost Model Analysis' for function 'constant_shift_v16i32':
417417 ; SSE2: Found an estimated cost of 64 for instruction: %shift
418418 ; SSE41: Found an estimated cost of 48 for instruction: %shift
419 ; AVX: Found an estimated cost of 48 for instruction: %shift
419 ; AVX: Found an estimated cost of 52 for instruction: %shift
420420 ; AVX2: Found an estimated cost of 2 for instruction: %shift
421421 ; AVX512: Found an estimated cost of 1 for instruction: %shift
422422 ; XOPAVX: Found an estimated cost of 12 for instruction: %shift
442442 ; CHECK: 'Cost Model Analysis' for function 'constant_shift_v16i16':
443443 ; SSE2: Found an estimated cost of 64 for instruction: %shift
444444 ; SSE41: Found an estimated cost of 28 for instruction: %shift
445 ; AVX: Found an estimated cost of 28 for instruction: %shift
445 ; AVX: Found an estimated cost of 30 for instruction: %shift
446446 ; AVX2: Found an estimated cost of 10 for instruction: %shift
447447 ; AVX512F: Found an estimated cost of 10 for instruction: %shift
448448 ; AVX512BW: Found an estimated cost of 1 for instruction: %shift
455455 ; CHECK: 'Cost Model Analysis' for function 'constant_shift_v32i16':
456456 ; SSE2: Found an estimated cost of 128 for instruction: %shift
457457 ; SSE41: Found an estimated cost of 56 for instruction: %shift
458 ; AVX: Found an estimated cost of 56 for instruction: %shift
458 ; AVX: Found an estimated cost of 60 for instruction: %shift
459459 ; AVX2: Found an estimated cost of 20 for instruction: %shift
460460 ; AVX512F: Found an estimated cost of 20 for instruction: %shift
461461 ; AVX512BW: Found an estimated cost of 1 for instruction: %shift
480480 ; CHECK: 'Cost Model Analysis' for function 'constant_shift_v32i8':
481481 ; SSE2: Found an estimated cost of 108 for instruction: %shift
482482 ; SSE41: Found an estimated cost of 48 for instruction: %shift
483 ; AVX: Found an estimated cost of 48 for instruction: %shift
483 ; AVX: Found an estimated cost of 50 for instruction: %shift
484484 ; AVX2: Found an estimated cost of 24 for instruction: %shift
485485 ; AVX512: Found an estimated cost of 24 for instruction: %shift
486486 ; XOP: Found an estimated cost of 6 for instruction: %shift
492492 ; CHECK: 'Cost Model Analysis' for function 'constant_shift_v64i8':
493493 ; SSE2: Found an estimated cost of 216 for instruction: %shift
494494 ; SSE41: Found an estimated cost of 96 for instruction: %shift
495 ; AVX: Found an estimated cost of 96 for instruction: %shift
495 ; AVX: Found an estimated cost of 100 for instruction: %shift
496496 ; AVX2: Found an estimated cost of 48 for instruction: %shift
497497 ; AVX512F: Found an estimated cost of 48 for instruction: %shift
498498 ; AVX512BW: Found an estimated cost of 24 for instruction: %shift
3333 ; CHECK: 'Cost Model Analysis' for function 'var_shift_v4i64':
3434 ; SSE2: Found an estimated cost of 8 for instruction: %shift
3535 ; SSE41: Found an estimated cost of 8 for instruction: %shift
36 ; AVX: Found an estimated cost of 8 for instruction: %shift
36 ; AVX: Found an estimated cost of 10 for instruction: %shift
3737 ; AVX2: Found an estimated cost of 1 for instruction: %shift
3838 ; AVX512: Found an estimated cost of 1 for instruction: %shift
3939 ; XOPAVX: Found an estimated cost of 6 for instruction: %shift
4646 ; CHECK: 'Cost Model Analysis' for function 'var_shift_v8i64':
4747 ; SSE2: Found an estimated cost of 16 for instruction: %shift
4848 ; SSE41: Found an estimated cost of 16 for instruction: %shift
49 ; AVX: Found an estimated cost of 16 for instruction: %shift
49 ; AVX: Found an estimated cost of 20 for instruction: %shift
5050 ; AVX2: Found an estimated cost of 2 for instruction: %shift
5151 ; AVX512: Found an estimated cost of 1 for instruction: %shift
5252 ; XOPAVX: Found an estimated cost of 12 for instruction: %shift
7272 ; CHECK: 'Cost Model Analysis' for function 'var_shift_v8i32':
7373 ; SSE2: Found an estimated cost of 32 for instruction: %shift
7474 ; SSE41: Found an estimated cost of 22 for instruction: %shift
75 ; AVX: Found an estimated cost of 22 for instruction: %shift
75 ; AVX: Found an estimated cost of 24 for instruction: %shift
7676 ; AVX2: Found an estimated cost of 1 for instruction: %shift
7777 ; AVX512: Found an estimated cost of 1 for instruction: %shift
7878 ; XOPAVX: Found an estimated cost of 6 for instruction: %shift
8585 ; CHECK: 'Cost Model Analysis' for function 'var_shift_v16i32':
8686 ; SSE2: Found an estimated cost of 64 for instruction: %shift
8787 ; SSE41: Found an estimated cost of 44 for instruction: %shift
88 ; AVX: Found an estimated cost of 44 for instruction: %shift
88 ; AVX: Found an estimated cost of 48 for instruction: %shift
8989 ; AVX2: Found an estimated cost of 2 for instruction: %shift
9090 ; AVX512: Found an estimated cost of 1 for instruction: %shift
9191 ; XOPAVX: Found an estimated cost of 12 for instruction: %shift
111111 ; CHECK: 'Cost Model Analysis' for function 'var_shift_v16i16':
112112 ; SSE2: Found an estimated cost of 64 for instruction: %shift
113113 ; SSE41: Found an estimated cost of 28 for instruction: %shift
114 ; AVX: Found an estimated cost of 28 for instruction: %shift
114 ; AVX: Found an estimated cost of 30 for instruction: %shift
115115 ; AVX2: Found an estimated cost of 10 for instruction: %shift
116116 ; AVX512F: Found an estimated cost of 10 for instruction: %shift
117117 ; AVX512BW: Found an estimated cost of 1 for instruction: %shift
124124 ; CHECK: 'Cost Model Analysis' for function 'var_shift_v32i16':
125125 ; SSE2: Found an estimated cost of 128 for instruction: %shift
126126 ; SSE41: Found an estimated cost of 56 for instruction: %shift
127 ; AVX: Found an estimated cost of 56 for instruction: %shift
127 ; AVX: Found an estimated cost of 60 for instruction: %shift
128128 ; AVX2: Found an estimated cost of 20 for instruction: %shift
129129 ; AVX512F: Found an estimated cost of 20 for instruction: %shift
130130 ; AVX512BW: Found an estimated cost of 1 for instruction: %shift
149149 ; CHECK: 'Cost Model Analysis' for function 'var_shift_v32i8':
150150 ; SSE2: Found an estimated cost of 52 for instruction: %shift
151151 ; SSE41: Found an estimated cost of 24 for instruction: %shift
152 ; AVX: Found an estimated cost of 24 for instruction: %shift
152 ; AVX: Found an estimated cost of 26 for instruction: %shift
153153 ; AVX2: Found an estimated cost of 11 for instruction: %shift
154154 ; AVX512: Found an estimated cost of 11 for instruction: %shift
155155 ; XOP: Found an estimated cost of 6 for instruction: %shift
161161 ; CHECK: 'Cost Model Analysis' for function 'var_shift_v64i8':
162162 ; SSE2: Found an estimated cost of 104 for instruction: %shift
163163 ; SSE41: Found an estimated cost of 48 for instruction: %shift
164 ; AVX: Found an estimated cost of 48 for instruction: %shift
164 ; AVX: Found an estimated cost of 52 for instruction: %shift
165165 ; AVX2: Found an estimated cost of 22 for instruction: %shift
166166 ; AVX512F: Found an estimated cost of 22 for instruction: %shift
167167 ; AVX512BW: Found an estimated cost of 11 for instruction: %shift
325325 ; CHECK: 'Cost Model Analysis' for function 'splatvar_shift_v32i8':
326326 ; SSE2: Found an estimated cost of 52 for instruction: %shift
327327 ; SSE41: Found an estimated cost of 24 for instruction: %shift
328 ; AVX: Found an estimated cost of 24 for instruction: %shift
328 ; AVX: Found an estimated cost of 26 for instruction: %shift
329329 ; AVX2: Found an estimated cost of 11 for instruction: %shift
330330 ; AVX512: Found an estimated cost of 11 for instruction: %shift
331331 ; XOP: Found an estimated cost of 6 for instruction: %shift
339339 ; CHECK: 'Cost Model Analysis' for function 'splatvar_shift_v64i8':
340340 ; SSE2: Found an estimated cost of 104 for instruction: %shift
341341 ; SSE41: Found an estimated cost of 48 for instruction: %shift
342 ; AVX: Found an estimated cost of 48 for instruction: %shift
342 ; AVX: Found an estimated cost of 52 for instruction: %shift
343343 ; AVX2: Found an estimated cost of 22 for instruction: %shift
344344 ; AVX512F: Found an estimated cost of 22 for instruction: %shift
345345 ; AVX512BW: Found an estimated cost of 11 for instruction: %shift
371371 ; CHECK: 'Cost Model Analysis' for function 'constant_shift_v4i64':
372372 ; SSE2: Found an estimated cost of 8 for instruction: %shift
373373 ; SSE41: Found an estimated cost of 8 for instruction: %shift
374 ; AVX: Found an estimated cost of 8 for instruction: %shift
374 ; AVX: Found an estimated cost of 10 for instruction: %shift
375375 ; AVX2: Found an estimated cost of 1 for instruction: %shift
376376 ; AVX512: Found an estimated cost of 1 for instruction: %shift
377377 ; XOPAVX: Found an estimated cost of 6 for instruction: %shift
384384 ; CHECK: 'Cost Model Analysis' for function 'constant_shift_v8i64':
385385 ; SSE2: Found an estimated cost of 16 for instruction: %shift
386386 ; SSE41: Found an estimated cost of 16 for instruction: %shift
387 ; AVX: Found an estimated cost of 16 for instruction: %shift
387 ; AVX: Found an estimated cost of 20 for instruction: %shift
388388 ; AVX2: Found an estimated cost of 2 for instruction: %shift
389389 ; AVX512: Found an estimated cost of 1 for instruction: %shift
390390 ; XOPAVX: Found an estimated cost of 12 for instruction: %shift
410410 ; CHECK: 'Cost Model Analysis' for function 'constant_shift_v8i32':
411411 ; SSE2: Found an estimated cost of 32 for instruction: %shift
412412 ; SSE41: Found an estimated cost of 22 for instruction: %shift
413 ; AVX: Found an estimated cost of 22 for instruction: %shift
413 ; AVX: Found an estimated cost of 24 for instruction: %shift
414414 ; AVX2: Found an estimated cost of 1 for instruction: %shift
415415 ; AVX512: Found an estimated cost of 1 for instruction: %shift
416416 ; XOPAVX: Found an estimated cost of 6 for instruction: %shift
423423 ; CHECK: 'Cost Model Analysis' for function 'constant_shift_v16i32':
424424 ; SSE2: Found an estimated cost of 64 for instruction: %shift
425425 ; SSE41: Found an estimated cost of 44 for instruction: %shift
426 ; AVX: Found an estimated cost of 44 for instruction: %shift
426 ; AVX: Found an estimated cost of 48 for instruction: %shift
427427 ; AVX2: Found an estimated cost of 2 for instruction: %shift
428428 ; AVX512: Found an estimated cost of 1 for instruction: %shift
429429 ; XOPAVX: Found an estimated cost of 12 for instruction: %shift
449449 ; CHECK: 'Cost Model Analysis' for function 'constant_shift_v16i16':
450450 ; SSE2: Found an estimated cost of 64 for instruction: %shift
451451 ; SSE41: Found an estimated cost of 28 for instruction: %shift
452 ; AVX: Found an estimated cost of 28 for instruction: %shift
452 ; AVX: Found an estimated cost of 30 for instruction: %shift
453453 ; AVX2: Found an estimated cost of 10 for instruction: %shift
454454 ; AVX512F: Found an estimated cost of 10 for instruction: %shift
455455 ; AVX512BW: Found an estimated cost of 1 for instruction: %shift
462462 ; CHECK: 'Cost Model Analysis' for function 'constant_shift_v32i16':
463463 ; SSE2: Found an estimated cost of 128 for instruction: %shift
464464 ; SSE41: Found an estimated cost of 56 for instruction: %shift
465 ; AVX: Found an estimated cost of 56 for instruction: %shift
465 ; AVX: Found an estimated cost of 60 for instruction: %shift
466466 ; AVX2: Found an estimated cost of 20 for instruction: %shift
467467 ; AVX512F: Found an estimated cost of 20 for instruction: %shift
468468 ; AVX512BW: Found an estimated cost of 1 for instruction: %shift
487487 ; CHECK: 'Cost Model Analysis' for function 'constant_shift_v32i8':
488488 ; SSE2: Found an estimated cost of 52 for instruction: %shift
489489 ; SSE41: Found an estimated cost of 24 for instruction: %shift
490 ; AVX: Found an estimated cost of 24 for instruction: %shift
490 ; AVX: Found an estimated cost of 26 for instruction: %shift
491491 ; AVX2: Found an estimated cost of 11 for instruction: %shift
492492 ; AVX512: Found an estimated cost of 11 for instruction: %shift
493493 ; XOP: Found an estimated cost of 6 for instruction: %shift
499499 ; CHECK: 'Cost Model Analysis' for function 'constant_shift_v64i8':
500500 ; SSE2: Found an estimated cost of 104 for instruction: %shift
501501 ; SSE41: Found an estimated cost of 48 for instruction: %shift
502 ; AVX: Found an estimated cost of 48 for instruction: %shift
502 ; AVX: Found an estimated cost of 52 for instruction: %shift
503503 ; AVX2: Found an estimated cost of 22 for instruction: %shift
504504 ; AVX512F: Found an estimated cost of 22 for instruction: %shift
505505 ; AVX512BW: Found an estimated cost of 11 for instruction: %shift
3434 ; CHECK: 'Cost Model Analysis' for function 'var_shift_v4i64':
3535 ; SSE2: Found an estimated cost of 8 for instruction: %shift
3636 ; SSE41: Found an estimated cost of 8 for instruction: %shift
37 ; AVX: Found an estimated cost of 8 for instruction: %shift
37 ; AVX: Found an estimated cost of 10 for instruction: %shift
3838 ; AVX2: Found an estimated cost of 1 for instruction: %shift
3939 ; AVX512: Found an estimated cost of 1 for instruction: %shift
4040 ; XOPAVX: Found an estimated cost of 4 for instruction: %shift
4747 ; CHECK: 'Cost Model Analysis' for function 'var_shift_v8i64':
4848 ; SSE2: Found an estimated cost of 16 for instruction: %shift
4949 ; SSE41: Found an estimated cost of 16 for instruction: %shift
50 ; AVX: Found an estimated cost of 16 for instruction: %shift
50 ; AVX: Found an estimated cost of 20 for instruction: %shift
5151 ; AVX2: Found an estimated cost of 2 for instruction: %shift
5252 ; AVX512: Found an estimated cost of 1 for instruction: %shift
5353 ; XOPAVX: Found an estimated cost of 8 for instruction: %shift
7373 ; CHECK: 'Cost Model Analysis' for function 'var_shift_v8i32':
7474 ; SSE2: Found an estimated cost of 20 for instruction: %shift
7575 ; SSE41: Found an estimated cost of 8 for instruction: %shift
76 ; AVX: Found an estimated cost of 8 for instruction: %shift
76 ; AVX: Found an estimated cost of 10 for instruction: %shift
7777 ; AVX2: Found an estimated cost of 1 for instruction: %shift
7878 ; AVX512: Found an estimated cost of 1 for instruction: %shift
7979 ; XOPAVX: Found an estimated cost of 4 for instruction: %shift
8686 ; CHECK: 'Cost Model Analysis' for function 'var_shift_v16i32':
8787 ; SSE2: Found an estimated cost of 40 for instruction: %shift
8888 ; SSE41: Found an estimated cost of 16 for instruction: %shift
89 ; AVX: Found an estimated cost of 16 for instruction: %shift
89 ; AVX: Found an estimated cost of 20 for instruction: %shift
9090 ; AVX2: Found an estimated cost of 2 for instruction: %shift
9191 ; AVX512: Found an estimated cost of 1 for instruction: %shift
9292 ; XOPAVX: Found an estimated cost of 8 for instruction: %shift
112112 ; CHECK: 'Cost Model Analysis' for function 'var_shift_v16i16':
113113 ; SSE2: Found an estimated cost of 64 for instruction: %shift
114114 ; SSE41: Found an estimated cost of 28 for instruction: %shift
115 ; AVX: Found an estimated cost of 28 for instruction: %shift
115 ; AVX: Found an estimated cost of 30 for instruction: %shift
116116 ; AVX2: Found an estimated cost of 10 for instruction: %shift
117117 ; AVX512F: Found an estimated cost of 10 for instruction: %shift
118118 ; AVX512BW: Found an estimated cost of 1 for instruction: %shift
125125 ; CHECK: 'Cost Model Analysis' for function 'var_shift_v32i16':
126126 ; SSE2: Found an estimated cost of 128 for instruction: %shift
127127 ; SSE41: Found an estimated cost of 56 for instruction: %shift
128 ; AVX: Found an estimated cost of 56 for instruction: %shift
128 ; AVX: Found an estimated cost of 60 for instruction: %shift
129129 ; AVX2: Found an estimated cost of 20 for instruction: %shift
130130 ; AVX512F: Found an estimated cost of 20 for instruction: %shift
131131 ; AVX512BW: Found an estimated cost of 1 for instruction: %shift
150150 ; CHECK: 'Cost Model Analysis' for function 'var_shift_v32i8':
151151 ; SSE2: Found an estimated cost of 52 for instruction: %shift
152152 ; SSE41: Found an estimated cost of 22 for instruction: %shift
153 ; AVX: Found an estimated cost of 22 for instruction: %shift
153 ; AVX: Found an estimated cost of 24 for instruction: %shift
154154 ; AVX2: Found an estimated cost of 11 for instruction: %shift
155155 ; AVX512: Found an estimated cost of 11 for instruction: %shift
156156 ; XOP: Found an estimated cost of 4 for instruction: %shift
162162 ; CHECK: 'Cost Model Analysis' for function 'var_shift_v64i8':
163163 ; SSE2: Found an estimated cost of 104 for instruction: %shift
164164 ; SSE41: Found an estimated cost of 44 for instruction: %shift
165 ; AVX: Found an estimated cost of 44 for instruction: %shift
165 ; AVX: Found an estimated cost of 48 for instruction: %shift
166166 ; AVX2: Found an estimated cost of 22 for instruction: %shift
167167 ; AVX512F: Found an estimated cost of 22 for instruction: %shift
168168 ; AVX512BW: Found an estimated cost of 11 for instruction: %shift
326326 ; CHECK: 'Cost Model Analysis' for function 'splatvar_shift_v32i8':
327327 ; SSE2: Found an estimated cost of 52 for instruction: %shift
328328 ; SSE41: Found an estimated cost of 22 for instruction: %shift
329 ; AVX: Found an estimated cost of 22 for instruction: %shift
329 ; AVX: Found an estimated cost of 24 for instruction: %shift
330330 ; AVX2: Found an estimated cost of 11 for instruction: %shift
331331 ; AVX512: Found an estimated cost of 11 for instruction: %shift
332332 ; XOP: Found an estimated cost of 4 for instruction: %shift
340340 ; CHECK: 'Cost Model Analysis' for function 'splatvar_shift_v64i8':
341341 ; SSE2: Found an estimated cost of 104 for instruction: %shift
342342 ; SSE41: Found an estimated cost of 44 for instruction: %shift
343 ; AVX: Found an estimated cost of 44 for instruction: %shift
343 ; AVX: Found an estimated cost of 48 for instruction: %shift
344344 ; AVX2: Found an estimated cost of 22 for instruction: %shift
345345 ; AVX512F: Found an estimated cost of 22 for instruction: %shift
346346 ; AVX512BW: Found an estimated cost of 11 for instruction: %shift
372372 ; CHECK: 'Cost Model Analysis' for function 'constant_shift_v4i64':
373373 ; SSE2: Found an estimated cost of 8 for instruction: %shift
374374 ; SSE41: Found an estimated cost of 8 for instruction: %shift
375 ; AVX: Found an estimated cost of 8 for instruction: %shift
375 ; AVX: Found an estimated cost of 10 for instruction: %shift
376376 ; AVX2: Found an estimated cost of 1 for instruction: %shift
377377 ; AVX512: Found an estimated cost of 1 for instruction: %shift
378378 ; XOPAVX: Found an estimated cost of 4 for instruction: %shift
385385 ; CHECK: 'Cost Model Analysis' for function 'constant_shift_v8i64':
386386 ; SSE2: Found an estimated cost of 16 for instruction: %shift
387387 ; SSE41: Found an estimated cost of 16 for instruction: %shift
388 ; AVX: Found an estimated cost of 16 for instruction: %shift
388 ; AVX: Found an estimated cost of 20 for instruction: %shift
389389 ; AVX2: Found an estimated cost of 2 for instruction: %shift
390390 ; AVX512: Found an estimated cost of 1 for instruction: %shift
391391 ; XOPAVX: Found an estimated cost of 8 for instruction: %shift
488488 ; CHECK: 'Cost Model Analysis' for function 'constant_shift_v32i8':
489489 ; SSE2: Found an estimated cost of 52 for instruction: %shift
490490 ; SSE41: Found an estimated cost of 22 for instruction: %shift
491 ; AVX: Found an estimated cost of 22 for instruction: %shift
491 ; AVX: Found an estimated cost of 24 for instruction: %shift
492492 ; AVX2: Found an estimated cost of 11 for instruction: %shift
493493 ; AVX512: Found an estimated cost of 11 for instruction: %shift
494494 ; XOP: Found an estimated cost of 4 for instruction: %shift
500500 ; CHECK: 'Cost Model Analysis' for function 'constant_shift_v64i8':
501501 ; SSE2: Found an estimated cost of 104 for instruction: %shift
502502 ; SSE41: Found an estimated cost of 44 for instruction: %shift
503 ; AVX: Found an estimated cost of 44 for instruction: %shift
503 ; AVX: Found an estimated cost of 48 for instruction: %shift
504504 ; AVX2: Found an estimated cost of 22 for instruction: %shift
505505 ; AVX512F: Found an estimated cost of 22 for instruction: %shift
506506 ; AVX512BW: Found an estimated cost of 11 for instruction: %shift
793793 ; CHECK: 'Cost Model Analysis' for function 'test8':
794794 ; SSE2: Found an estimated cost of 8 for instruction: %shl
795795 ; SSE41: Found an estimated cost of 8 for instruction: %shl
796 ; AVX: Found an estimated cost of 8 for instruction: %shl
796 ; AVX: Found an estimated cost of 10 for instruction: %shl
797797 ; AVX2: Found an estimated cost of 1 for instruction: %shl
798798 ; XOPAVX: Found an estimated cost of 4 for instruction: %shl
799799 ; XOPAVX2: Found an estimated cost of 1 for instruction: %shl
841841 ; CHECK: 'Cost Model Analysis' for function 'test11':
842842 ; SSE2: Found an estimated cost of 16 for instruction: %shl
843843 ; SSE41: Found an estimated cost of 16 for instruction: %shl
844 ; AVX: Found an estimated cost of 16 for instruction: %shl
844 ; AVX: Found an estimated cost of 20 for instruction: %shl
845845 ; AVX2: Found an estimated cost of 2 for instruction: %shl
846846 ; XOPAVX: Found an estimated cost of 8 for instruction: %shl
847847 ; XOPAVX2: Found an estimated cost of 2 for instruction: %shl