llvm-project
28 строк · 757.0 Байт
1; RUN: opt %loadNPMPolly '-passes=print<polly-detect>' -disable-output < %s 2>&1 | FileCheck %s
2
3
4; CHECK-NOT: Valid Region
5target datalayout = "e-m:o-i64:64-f80:128-n8:16:32:64-S128"
6
7define void @blam(ptr %A, ptr %B) {
8bb:
9%tmp1 = alloca i64
10%tmp2 = shl i64 2, undef
11%tmp3 = shl i64 2, undef
12%tmp4 = mul nsw i64 %tmp2, %tmp3
13br label %loop
14
15loop:
16%indvar = phi i64 [ %indvar.next, %loop ], [ 0, %bb ]
17%gep = getelementptr inbounds i64, ptr %tmp1, i64 %indvar
18%tmp12 = load i64, ptr %gep
19%tmp13 = mul nsw i64 %tmp12, %tmp4
20%ptr = getelementptr inbounds float, ptr %B, i64 %tmp13
21%val = load float, ptr %ptr
22store float %val, ptr %A
23%indvar.next = add nsw i64 %indvar, 1
24br i1 false, label %loop, label %bb21
25
26bb21:
27ret void
28}
29