brintos

brintos / llvm-project-archived public Read only

0
0
Text · 1.3 KiB · 5b0cefb Raw
58 lines · plain
1; RUN: opt %loadNPMPolly -polly-reschedule=0 -polly-loopfusion-greedy=1 -polly-postopts=0 '-passes=polly-custom<opt-isl>' -polly-print-opt-isl -disable-output < %s | FileCheck %s2; RUN: opt %loadNPMPolly -polly-reschedule=1 -polly-loopfusion-greedy=1 -polly-postopts=0 '-passes=polly-custom<opt-isl>' -polly-print-opt-isl -disable-output < %s | FileCheck %s3 4define void @func(i32 %n, ptr noalias nonnull %A, ptr noalias nonnull %B, i32 %k) {5entry:6  br label %for17 8 9for1:10  %j1 = phi i32 [0, %entry], [%j1.inc, %inc1]11  %j1.cmp = icmp slt i32 %j1, %n12  br i1 %j1.cmp, label %body1, label %exit113 14    body1:15      %idx1 = add i32 %j1, %k16      %arrayidx1 = getelementptr inbounds double, ptr %A, i32 %j117      store double 21.0, ptr %arrayidx118      br label %inc119 20inc1:21  %j1.inc = add nuw nsw i32 %j1, 122  br label %for123 24exit1:25  br label %middle226 27 28middle2:29  store double 52.0, ptr %A30  br label %for331 32 33for3:34  %j3 = phi i32 [0, %middle2], [%j3.inc, %inc3]35  %j3.cmp = icmp slt i32 %j3, %n36  br i1 %j3.cmp, label %body3, label %exit337 38    body3:39      %arrayidx3 = getelementptr inbounds double, ptr %B, i32 %j340      store double 84.0, ptr %arrayidx341      br label %inc342 43inc3:44  %j3.inc = add nuw nsw i32 %j3, 145  br label %for346 47exit3:48  br label %return49 50 51return:52  ret void53}54 55 56; CHECK:      Calculated schedule:57; CHECK-NEXT:   n/a58