brintos

brintos / llvm-project-archived public Read only

0
0
Text · 1.7 KiB · a36769d Raw
38 lines · plain
1; NOTE: Assertions have been autogenerated by utils/update_test_checks.py2; RUN: opt -S -mtriple=x86_64-pc-linux-gnu -mcpu=generic -passes=slp-vectorizer -pass-remarks-output=%t < %s | FileCheck %s3; RUN: FileCheck --input-file=%t --check-prefix=YAML %s4 5; YAML-LABEL: --- !Passed6; YAML-NEXT:  Pass:            slp-vectorizer7; YAML-NEXT:  Name:            VectorizedList8; YAML-NEXT:  Function:        build_vec_v2i649; YAML-NEXT:  Args:10; YAML-NEXT:    - String:          'SLP vectorized with cost '11; YAML-NEXT:    - Cost:            '-10'12; YAML-NEXT:    - String:          ' and with tree size '13; YAML-NEXT:    - TreeSize:        '8'14 15define <2 x i64> @build_vec_v2i64(<2 x i64> %v0, <2 x i64> %v1) {16; CHECK-LABEL: @build_vec_v2i64(17; CHECK-NEXT:    [[TMP1:%.*]] = add <2 x i64> [[V0:%.*]], [[V1:%.*]]18; CHECK-NEXT:    [[TMP2:%.*]] = sub <2 x i64> [[V0]], [[V1]]19; CHECK-NEXT:    [[TMP3:%.*]] = shufflevector <2 x i64> [[TMP1]], <2 x i64> [[TMP2]], <2 x i32> <i32 1, i32 2>20; CHECK-NEXT:    [[TMP4:%.*]] = shufflevector <2 x i64> [[TMP1]], <2 x i64> [[TMP2]], <2 x i32> <i32 0, i32 3>21; CHECK-NEXT:    [[TMP5:%.*]] = add <2 x i64> [[TMP4]], [[TMP3]]22; CHECK-NEXT:    ret <2 x i64> [[TMP5]]23;24  %v0.0 = extractelement <2 x i64> %v0, i32 025  %v0.1 = extractelement <2 x i64> %v0, i32 126  %v1.0 = extractelement <2 x i64> %v1, i32 027  %v1.1 = extractelement <2 x i64> %v1, i32 128  %tmp0.0 = add i64 %v0.0, %v1.029  %tmp0.1 = add i64 %v0.1, %v1.130  %tmp1.0 = sub i64 %v0.0, %v1.031  %tmp1.1 = sub i64 %v0.1, %v1.132  %tmp2.0 = add i64 %tmp0.0, %tmp0.133  %tmp2.1 = add i64 %tmp1.0, %tmp1.134  %tmp3.0 = insertelement <2 x i64> undef, i64 %tmp2.0, i32 035  %tmp3.1 = insertelement <2 x i64> %tmp3.0, i64 %tmp2.1, i32 136  ret <2 x i64> %tmp3.137}38