
The `opt -analyze` option only works with the legacy pass manager and might be removed in the future, as explained in llvm.org/PR53733. This patch introduced -polly-print-* passes that print what the pass would print with the `-analyze` option and replaces all uses of `-analyze` in the regression tests. There are two exceptions: `CodeGen\single_loop_param_less_equal.ll` and `CodeGen\loop_with_condition_nested.ll` use `-analyze on the `-loops` pass which is not part of Polly. Reviewed By: aeubanks Differential Revision: https://reviews.llvm.org/D120782
34 lines
1.0 KiB
LLVM
34 lines
1.0 KiB
LLVM
; RUN: opt %loadPolly -polly-print-scops -disable-output < %s | FileCheck %s
|
|
;
|
|
; void foo(float *A, float *B, float *C, long N) {
|
|
; for (long i = 0; i < N; i++)
|
|
; C[i] = A[i] + B[i];
|
|
; }
|
|
;
|
|
; CHECK: Alias Groups (2):
|
|
;
|
|
; This test case verifies that we do not create run-time checks for two
|
|
; read-only arrays.
|
|
target datalayout = "e-m:e-i64:64-f80:128-n8:16:32:64-S128"
|
|
|
|
define void @foo(float* %A, float* %B, float* %C, i64 %N) {
|
|
entry:
|
|
br label %for.body
|
|
|
|
for.body:
|
|
%indvar = phi i64 [ 0, %entry ], [ %indvar.next, %for.body ]
|
|
%arrayidx.A = getelementptr float, float* %A, i64 %indvar
|
|
%arrayidx.B = getelementptr float, float* %B, i64 %indvar
|
|
%arrayidx.C = getelementptr float, float* %C, i64 %indvar
|
|
%val.A = load float, float* %arrayidx.A
|
|
%val.B = load float, float* %arrayidx.B
|
|
%add = fadd float %val.A, %val.B
|
|
store float %add, float* %arrayidx.C
|
|
%indvar.next = add nsw i64 %indvar, 1
|
|
%exitcond = icmp ne i64 %indvar.next, %N
|
|
br i1 %exitcond, label %for.body, label %for.end
|
|
|
|
for.end:
|
|
ret void
|
|
}
|