• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1; RUN: opt %loadPolly -polly-import-jscop -polly-import-jscop-postfix=transformed -polly-codegen -S < %s | FileCheck %s
2;
3; Partial write, where "partial" is the empty set.
4; The store is never executed in this case and we do generate it in the
5; first place.
6;
7; for (int j = 0; j < n; j += 1)
8;   A[0] = 42.0
9;
10
11define void @partial_write_emptyset(i32 %n, double* noalias nonnull %A) {
12entry:
13  br label %for
14
15for:
16  %j = phi i32 [0, %entry], [%j.inc, %inc]
17  %j.cmp = icmp slt i32 %j, %n
18  br i1 %j.cmp, label %body, label %exit
19
20    body:
21      store double 42.0, double* %A
22      br label %inc
23
24inc:
25  %j.inc = add nuw nsw i32 %j, 1
26  br label %for
27
28exit:
29  br label %return
30
31return:
32  ret void
33}
34
35
36; CHECK-LABEL: polly.stmt.body:
37; CHECK-NOT:     store
38