Home | History | Annotate | Download | only in vect
      1 ; RUN: llc -march=hexagon < %s
      2 ; Used to fail with "Cannot select: 0x16cb7f0: v2i16 = truncate"
      3 
      4 ; ModuleID = 'bugpoint-reduced-simplified.bc'
      5 target datalayout = "e-p:32:32:32-i64:64:64-i32:32:32-i16:16:16-i1:32:32-f64:64:64-f32:32:32-a0:0-n32"
      6 target triple = "hexagon-unknown-linux-gnu"
      7 
      8 define void @Autocorr() nounwind {
      9 entry:
     10   br label %for.body
     11 
     12 for.body:                                         ; preds = %for.body, %entry
     13   br i1 undef, label %polly.loop_header43, label %for.body
     14 
     15 do.cond:                                          ; preds = %polly.loop_header
     16   unreachable
     17 
     18 do.end:                                           ; preds = %polly.loop_after45
     19   ret void
     20 
     21 polly.loop_header:                                ; preds = %polly.loop_after45, %polly.loop_body
     22   %0 = icmp sle i32 undef, 239
     23   br i1 %0, label %polly.loop_body, label %do.cond
     24 
     25 polly.loop_body:                                  ; preds = %polly.loop_header
     26   %p_25 = call i32 @llvm.hexagon.SI.to.SXTHI.asrh(i32 undef)
     27   %1 = insertelement <4 x i32> undef, i32 %p_25, i32 3
     28   %2 = trunc <4 x i32> %1 to <4 x i16>
     29   store <4 x i16> %2, <4 x i16>* undef, align 8
     30   br label %polly.loop_header
     31 
     32 polly.loop_after45:                               ; preds = %polly.loop_header43
     33   br i1 undef, label %polly.loop_header, label %do.end
     34 
     35 polly.loop_header43:                              ; preds = %polly.loop_body44, %for.body
     36   br i1 undef, label %polly.loop_body44, label %polly.loop_after45
     37 
     38 polly.loop_body44:                                ; preds = %polly.loop_header43
     39   br label %polly.loop_header43
     40 }
     41 
     42 declare i32 @llvm.hexagon.SI.to.SXTHI.asrh(i32) nounwind readnone
     43