• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1; RUN: opt %loadPolly -polly-detect -analyze < %s
2
3; Verify that the scop detection does not crash on inputs with unreachable
4; blocks. Earlier we crashed when detecting error blocks.
5
6target datalayout = "e-m:e-i64:64-f80:128-n8:16:32:64-S128"
7target triple = "x86_64-unknown-linux-gnu"
8
9; Function Attrs: nounwind uwtable
10define void @foo() {
11entry:
12  br label %while.cond
13
14while.cond:                                       ; preds = %for.end, %entry
15  br i1 false, label %for.end, label %while.end8
16
17while.cond1:                                      ; preds = %while.cond4
18  br i1 undef, label %while.body3, label %for.inc
19
20while.body3:                                      ; preds = %while.cond1
21  br label %while.cond4
22
23while.cond4:                                      ; preds = %while.cond4, %while.body3
24  br i1 undef, label %while.cond4, label %while.cond1
25
26for.inc:                                          ; preds = %while.cond1
27  %conv = zext i16 undef to i32
28  br label %for.end
29
30for.end:                                          ; preds = %for.inc, %while.cond
31  %conv.sink = phi i32 [ %conv, %for.inc ], [ 0, %while.cond ]
32  br label %while.cond
33
34while.end8:                                       ; preds = %while.cond
35  ret void
36}
37