annotate polly/test/CodeGen/partial_write_emptyset.ll @ 252:1f2b6ac9f198 llvm-original

LLVM16-1
author Shinji KONO <kono@ie.u-ryukyu.ac.jp>
date Fri, 18 Aug 2023 09:04:13 +0900
parents c4bab56944e8
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
236
c4bab56944e8 LLVM 16
kono
parents:
diff changeset
1 ; RUN: opt %loadPolly -polly-import-jscop -polly-import-jscop-postfix=transformed -polly-codegen -S < %s | FileCheck %s
c4bab56944e8 LLVM 16
kono
parents:
diff changeset
2 ;
c4bab56944e8 LLVM 16
kono
parents:
diff changeset
3 ; Partial write, where "partial" is the empty set.
c4bab56944e8 LLVM 16
kono
parents:
diff changeset
4 ; The store is never executed in this case and we do generate it in the
c4bab56944e8 LLVM 16
kono
parents:
diff changeset
5 ; first place.
c4bab56944e8 LLVM 16
kono
parents:
diff changeset
6 ;
c4bab56944e8 LLVM 16
kono
parents:
diff changeset
7 ; for (int j = 0; j < n; j += 1)
c4bab56944e8 LLVM 16
kono
parents:
diff changeset
8 ; A[0] = 42.0
c4bab56944e8 LLVM 16
kono
parents:
diff changeset
9 ;
c4bab56944e8 LLVM 16
kono
parents:
diff changeset
10
252
1f2b6ac9f198 LLVM16-1
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 236
diff changeset
11 define void @partial_write_emptyset(i32 %n, ptr noalias nonnull %A) {
236
c4bab56944e8 LLVM 16
kono
parents:
diff changeset
12 entry:
c4bab56944e8 LLVM 16
kono
parents:
diff changeset
13 br label %for
c4bab56944e8 LLVM 16
kono
parents:
diff changeset
14
c4bab56944e8 LLVM 16
kono
parents:
diff changeset
15 for:
c4bab56944e8 LLVM 16
kono
parents:
diff changeset
16 %j = phi i32 [0, %entry], [%j.inc, %inc]
c4bab56944e8 LLVM 16
kono
parents:
diff changeset
17 %j.cmp = icmp slt i32 %j, %n
c4bab56944e8 LLVM 16
kono
parents:
diff changeset
18 br i1 %j.cmp, label %body, label %exit
c4bab56944e8 LLVM 16
kono
parents:
diff changeset
19
c4bab56944e8 LLVM 16
kono
parents:
diff changeset
20 body:
252
1f2b6ac9f198 LLVM16-1
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 236
diff changeset
21 store double 42.0, ptr %A
236
c4bab56944e8 LLVM 16
kono
parents:
diff changeset
22 br label %inc
c4bab56944e8 LLVM 16
kono
parents:
diff changeset
23
c4bab56944e8 LLVM 16
kono
parents:
diff changeset
24 inc:
c4bab56944e8 LLVM 16
kono
parents:
diff changeset
25 %j.inc = add nuw nsw i32 %j, 1
c4bab56944e8 LLVM 16
kono
parents:
diff changeset
26 br label %for
c4bab56944e8 LLVM 16
kono
parents:
diff changeset
27
c4bab56944e8 LLVM 16
kono
parents:
diff changeset
28 exit:
c4bab56944e8 LLVM 16
kono
parents:
diff changeset
29 br label %return
c4bab56944e8 LLVM 16
kono
parents:
diff changeset
30
c4bab56944e8 LLVM 16
kono
parents:
diff changeset
31 return:
c4bab56944e8 LLVM 16
kono
parents:
diff changeset
32 ret void
c4bab56944e8 LLVM 16
kono
parents:
diff changeset
33 }
c4bab56944e8 LLVM 16
kono
parents:
diff changeset
34
c4bab56944e8 LLVM 16
kono
parents:
diff changeset
35
c4bab56944e8 LLVM 16
kono
parents:
diff changeset
36 ; CHECK-LABEL: polly.stmt.body:
c4bab56944e8 LLVM 16
kono
parents:
diff changeset
37 ; CHECK-NOT: store