1; RUN: opt %loadPolly -tbaa -polly-parallel -polly-parallel-force -polly-parallel-force -polly-invariant-load-hoisting=true -polly-ast -analyze < %s | FileCheck %s -check-prefix=AST 2; RUN: opt %loadPolly -tbaa -polly-parallel -polly-parallel-force -polly-parallel-force -polly-invariant-load-hoisting=true -polly-codegen -S -verify-dom-info < %s | FileCheck %s -check-prefix=IR 3 4; #define N 1024 5; float A[N]; 6; 7; void single_parallel_loop(void) { 8; for (long i = 0; i < N; i++) 9; A[i] = 1; 10; } 11 12; AST: #pragma simd 13; AST: #pragma omp parallel for 14; AST: for (int c0 = 0; c0 <= 1023; c0 += 1) 15; AST: Stmt_S(c0); 16 17; IR: @single_parallel_loop_polly_subfn 18target datalayout = "e-p:64:64:64-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-v64:64:64-v128:128:128-a0:0:64-s0:64:64-f80:128:128-n8:16:32:64" 19 20define void @single_parallel_loop(float** %A) nounwind { 21entry: 22 br label %for.i 23 24for.i: 25 %indvar = phi i64 [ %indvar.next, %for.inc], [ 0, %entry ] 26 %exitcond = icmp ne i64 %indvar, 1024 27 br i1 %exitcond, label %S, label %exit 28 29S: 30 %ptr = load float*, float** %A, !tbaa !2 31 %scevgep = getelementptr float, float* %ptr, i64 %indvar 32 %val = load float, float* %scevgep, !tbaa !6 33 %sum = fadd float %val, 1.0 34 store float %sum, float* %scevgep, !tbaa !6 35 br label %for.inc 36 37for.inc: 38 %indvar.next = add i64 %indvar, 1 39 br label %for.i 40 41exit: 42 ret void 43} 44 45!2 = !{!"float", !3, i64 0} 46!3 = !{!"omnipotent char", !4, i64 0} 47!4 = !{!"Simple C/C++ TBAA"} 48!6 = !{!"float *ptr", !3, i64 0} 49