diff options
Diffstat (limited to 'polly/test/CodeGen/split_edges.ll')
-rw-r--r-- | polly/test/CodeGen/split_edges.ll | 39 |
1 files changed, 39 insertions, 0 deletions
diff --git a/polly/test/CodeGen/split_edges.ll b/polly/test/CodeGen/split_edges.ll new file mode 100644 index 00000000000..be44e113a7a --- /dev/null +++ b/polly/test/CodeGen/split_edges.ll @@ -0,0 +1,39 @@ +; RUN: opt %loadPolly -polly-codegen -verify-region-info -verify-dom-info -S %s | FileCheck %s +target datalayout = "e-p:64:64:64-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-v64:64:64-v128:128:128-a0:0:64-s0:64:64-f80:128:128-n8:16:32:64" +target triple = "x86_64-pc-linux-gnu" + +define void @loop_with_condition() nounwind { +bb0: + call void @llvm.memory.barrier(i1 true, i1 true, i1 true, i1 true, i1 false) + br label %bb1 + +bb1: + br i1 true, label %bb2, label %bb3 + +bb2: + %ind1 = phi i32 [0, %bb1], [ %inc1, %bb2] + %inc1 = add i32 %ind1, 1 + %cond1 = icmp eq i32 %ind1, 32 + br i1 %cond1, label %bb4, label %bb2 + +bb3: + %ind2 = phi i32 [0, %bb1], [ %inc2, %bb3] + %inc2 = add i32 %ind2, 1 + br i1 true, label %bb4, label %bb3 + +bb4: + br label %bb5 + +bb5: + call void @llvm.memory.barrier(i1 true, i1 true, i1 true, i1 true, i1 false) + ret void + +} + +declare void @llvm.memory.barrier(i1, i1, i1, i1, i1) nounwind + + +; CHECK: polly.enterScop +; CHECK: polly.finalMerge +; CHECK: polly.enterScop +; CHECK: polly.finalMerge |