1 ; RUN: llc -march=hexagon < %s | FileCheck %s
4 ; Check that we don't crash.
7 target triple = "hexagon"
9 @debug = external hidden unnamed_addr global i1, align 4
11 ; Function Attrs: nounwind
12 define void @foo(i1 %cond) local_unnamed_addr #0 {
16 if.end5: ; preds = %entry
17 br i1 undef, label %if.then12, label %if.end13
19 if.then12: ; preds = %if.end5
22 if.end13: ; preds = %if.end5
25 for.cond: ; preds = %if.end13
26 %or.cond288 = or i1 undef, undef
27 br i1 %cond, label %if.then44, label %if.end51
29 if.then44: ; preds = %for.cond
30 tail call void @bar() #0
33 if.end51: ; preds = %if.then44, %for.cond
34 %.b433 = load i1, ptr @debug, align 4
35 %or.cond290 = and i1 %or.cond288, %.b433
36 br i1 %or.cond290, label %if.then55, label %if.end63
38 if.then55: ; preds = %if.end51
41 if.end63: ; preds = %if.end51
45 declare void @bar() local_unnamed_addr #0
47 attributes #0 = { nounwind }