brintos

brintos / llvm-project-archived public Read only

0
0
Text · 4.2 KiB · 804b00d Raw
113 lines · plain
1; RUN: llc -mtriple=hexagon < %s | FileCheck %s2; REQUIRES: asserts3 4; Check for a reasonable output. This testcase used to crash.5; CHECK: .size fred6 7target triple = "hexagon"8 9define void @fred() local_unnamed_addr #0 {10entry:11  %0 = load i64, ptr undef, align 812  %shr.i465 = lshr i64 %0, 4813  %trunc = trunc i64 %shr.i465 to i1514  switch i15 %trunc, label %if.end26 [15    i15 -1, label %if.then1416    i15 0, label %if.then2117  ]18 19if.then14:                                        ; preds = %entry20  unreachable21 22if.then21:                                        ; preds = %entry23  unreachable24 25if.end26:                                         ; preds = %entry26  br label %if.end3627 28if.end36:                                         ; preds = %if.end2629  %or.i335 = or i64 undef, undef30  %shl2.i322 = or i64 undef, -922337203685477580831  br i1 undef, label %if.then44, label %lor.rhs.i32 33lor.rhs.i:                                        ; preds = %if.end3634  br label %le128.exit35 36le128.exit:                                       ; preds = %lor.rhs.i37  br i1 undef, label %if.then44, label %while.cond.preheader38 39if.then44:                                        ; preds = %le128.exit, %if.end3640  %conv42544 = phi i64 [ 0, %le128.exit ], [ 1, %if.end36 ]41  br label %while.cond.preheader42 43while.cond.preheader:                             ; preds = %if.then44, %le128.exit44  %aSig0.3.ph = phi i64 [ undef, %if.then44 ], [ %or.i335, %le128.exit ]45  %q.0.ph = phi i64 [ %conv42544, %if.then44 ], [ 0, %le128.exit ]46  br i1 undef, label %while.body.lr.ph, label %while.end47 48while.body.lr.ph:                                 ; preds = %while.cond.preheader49  %shr.i263 = lshr i64 %shl2.i322, 3250  br label %while.body51 52while.body:                                       ; preds = %exit312, %while.body.lr.ph53  %aSig0.3554 = phi i64 [ %aSig0.3.ph, %while.body.lr.ph ], [ %sub3.i205, %exit312 ]54  br label %while.body.i29755 56while.body.i297:                                  ; preds = %while.body.i297, %while.body57  %z.045.i287 = phi i64 [ %sub.i290, %while.body.i297 ], [ undef, %while.body ]58  %sub.i290 = add i64 %z.045.i287, -429496729659  %cmp3.i296 = icmp slt i64 undef, 060  br i1 %cmp3.i296, label %while.body.i297, label %while.end.i305.loopexit61 62while.end.i305.loopexit:                          ; preds = %while.body.i29763  %or14.i309 = or i64 0, %sub.i29064  br label %exit31265 66exit312:                                          ; preds = %while.end.i305.loopexit67  %cmp50 = icmp ugt i64 %or14.i309, 468  %cond = select i1 %cmp50, i64 undef, i64 069  %shr3.i.i221 = lshr i64 %cond, 3270  %mul15.i11.i243 = mul nuw i64 %shr3.i.i221, %shr.i26371  %add20.i18.i250 = add i64 0, %mul15.i11.i24372  %add26.i23.i255 = add i64 %add20.i18.i250, 073  %add3.i.i261 = add i64 %add26.i23.i255, 074  %shl4.i215 = shl i64 %add3.i.i261, 6175  %or10.i = or i64 %shl4.i215, 076  %shl2.i207 = shl i64 %aSig0.3554, 6177  %or.i209 = or i64 %shl2.i207, 078  %sub1.i202 = add i64 0, %or.i20979  %sub3.i205 = sub i64 %sub1.i202, %or10.i80  %cmp47 = icmp sgt i32 undef, 6181  br i1 %cmp47, label %while.body, label %while.end.loopexit82 83while.end.loopexit:                               ; preds = %exit31284  br label %while.end85 86while.end:                                        ; preds = %while.end.loopexit, %while.cond.preheader87  %aSig0.3.lcssa = phi i64 [ %aSig0.3.ph, %while.cond.preheader ], [ %sub3.i205, %while.end.loopexit ]88  %q.0.lcssa = phi i64 [ %q.0.ph, %while.cond.preheader ], [ %cond, %while.end.loopexit ]89  br i1 undef, label %if.then56, label %if.else7190 91if.then56:                                        ; preds = %while.end92  unreachable93 94if.else71:                                        ; preds = %while.end95  %shr8.i155 = lshr i64 %aSig0.3.lcssa, 1296  br label %do.body97 98do.body:                                          ; preds = %do.body, %if.else7199  %aSig0.5 = phi i64 [ %sub3.i151, %do.body ], [ %shr8.i155, %if.else71 ]100  %q.1 = phi i64 [ %inc, %do.body ], [ %q.0.lcssa, %if.else71 ]101  %inc = add i64 %q.1, 1102  %sub1.i148 = sub i64 %aSig0.5, 0103  %sub3.i151 = add i64 %sub1.i148, 0104  %cmp73 = icmp sgt i64 %sub3.i151, -1105  br i1 %cmp73, label %do.body, label %do.end106 107do.end:                                           ; preds = %do.body108  %and = and i64 %inc, 1109  unreachable110}111 112attributes #0 = { nounwind }113