llvm/llvm/test/Transforms/SLPVectorizer/NVPTX/buildvector-scalarized.ll

; NOTE: Assertions have been autogenerated by utils/update_test_checks.py UTC_ARGS: --version 2
; RUN: opt -passes=slp-vectorizer -S -mtriple=nvptx64-unknown-unknown < %s | FileCheck %s

define <2 x float> @baz() {
; CHECK-LABEL: define <2 x float> @baz() {
; CHECK-NEXT:  bb:
; CHECK-NEXT:    [[EXTRACTELEMENT:%.*]] = extractelement <2 x float> zeroinitializer, i64 0
; CHECK-NEXT:    [[FCMP:%.*]] = fcmp uno float [[EXTRACTELEMENT]], 0.000000e+00
; CHECK-NEXT:    [[FCMP1:%.*]] = fcmp uno float 0.000000e+00, 0.000000e+00
; CHECK-NEXT:    [[OR:%.*]] = or i1 [[FCMP]], [[FCMP1]]
; CHECK-NEXT:    [[FCMP2:%.*]] = fcmp oeq float 0.000000e+00, 0.000000e+00
; CHECK-NEXT:    [[OR3:%.*]] = or i1 [[FCMP2]], [[OR]]
; CHECK-NEXT:    [[FCMP4:%.*]] = fcmp oeq float 0.000000e+00, 0.000000e+00
; CHECK-NEXT:    [[OR5:%.*]] = or i1 [[FCMP4]], [[OR3]]
; CHECK-NEXT:    br i1 [[OR5]], label [[BB6:%.*]], label [[BB7:%.*]]
; CHECK:       bb6:
; CHECK-NEXT:    ret <2 x float> zeroinitializer
; CHECK:       bb7:
; CHECK-NEXT:    ret <2 x float> zeroinitializer
;
bb:
  %extractelement = extractelement <2 x float> zeroinitializer, i64 0
  %fcmp = fcmp uno float %extractelement, 0.000000e+00
  %fcmp1 = fcmp uno float 0.000000e+00, 0.000000e+00
  %or = or i1 %fcmp, %fcmp1
  %fcmp2 = fcmp oeq float 0.000000e+00, 0.000000e+00
  %or3 = or i1 %fcmp2, %or
  %fcmp4 = fcmp oeq float 0.000000e+00, 0.000000e+00
  %or5 = or i1 %fcmp4, %or3
  br i1 %or5, label %bb6, label %bb7

bb6:                                              ; preds = %bb
  ret <2 x float> zeroinitializer

bb7:                                              ; preds = %bb
  ret <2 x float> zeroinitializer
}