brintos

brintos / llvm-project-archived public Read only

0
0
Text · 1.3 KiB · 35f521f Raw
32 lines · plain
1; NOTE: Assertions have been autogenerated by utils/update_test_checks.py2; RUN: opt < %s -passes=slp-vectorizer -S -mtriple=x86_64-unknown-linux -mattr=+avx2 -pass-remarks-output=%t | FileCheck %s3; RUN: FileCheck %s --input-file=%t --check-prefix=YAML4 5; YAML: --- !Passed6; YAML: Pass:            slp-vectorizer7; YAML: Name:            VectorizedList8; YAML: Function:        multi_uses9; YAML: Args:10; YAML:  - String:          'SLP vectorized with cost '11; YAML:  - Cost:            '-1'12; YAML:  - String:          ' and with tree size '13; YAML:  - TreeSize:        '3'14 15define float @multi_uses(<2 x float> %x, <2 x float> %y) {16; CHECK-LABEL: @multi_uses(17; CHECK-NEXT:    [[TMP1:%.*]] = shufflevector <2 x float> [[Y:%.*]], <2 x float> poison, <2 x i32> <i32 1, i32 1>18; CHECK-NEXT:    [[TMP2:%.*]] = fmul <2 x float> [[X:%.*]], [[TMP1]]19; CHECK-NEXT:    [[TMP3:%.*]] = extractelement <2 x float> [[TMP2]], i32 020; CHECK-NEXT:    [[TMP4:%.*]] = extractelement <2 x float> [[TMP2]], i32 121; CHECK-NEXT:    [[ADD:%.*]] = fadd float [[TMP3]], [[TMP4]]22; CHECK-NEXT:    ret float [[ADD]]23;24  %x0 = extractelement <2 x float> %x, i32 025  %x1 = extractelement <2 x float> %x, i32 126  %y1 = extractelement <2 x float> %y, i32 127  %x0x0 = fmul float %x0, %y128  %x1x1 = fmul float %x1, %y129  %add = fadd float %x0x0, %x1x130  ret float %add31}32