2 ! { dg-options "-fno-inline" }
4 ! { dg-additional-options "-fopt-info-all-omp" }
5 ! { dg-additional-options "-foffload=-fopt-info-all-omp" }
7 ! { dg-additional-options "--param=openacc-privatization=noisy" }
8 ! { dg-additional-options "-foffload=--param=openacc-privatization=noisy" }
9 ! Prune a few: uninteresting, and potentially varying depending on GCC configuration (data types):
10 ! { dg-prune-output {note: variable 'D\.[0-9]+' declared in block isn't candidate for adjusting OpenACC privatization level: not addressable} }
12 integer, parameter :: n
= 10
14 integer, external :: fact
17 !$acc loop ! { dg-line l_loop1 }
18 ! { dg-note {variable 'i' in 'private' clause is candidate for adjusting OpenACC privatization level} {} { target *-*-* } l_loop1 }
19 ! { dg-note {variable 'i' ought to be adjusted for OpenACC privatization level: 'vector'} {} { target *-*-* } l_loop1 }
20 ! { dg-note {variable 'i' adjusted for OpenACC privatization level: 'vector'} {} { target { ! openacc_host_selected } } l_loop1 }
21 ! { dg-note {variable 'i\.[0-9]+' in 'private' clause isn't candidate for adjusting OpenACC privatization level: not addressable} {} { target *-*-* } l_loop1 }
22 ! { dg-optimized {assigned OpenACC gang vector loop parallelism} {} { target *-*-* } l_loop1 }
24 a(i
) = fact (i
) ! { dg-optimized {assigned OpenACC seq loop parallelism} }
28 if (a(i
) .ne
. fact(i
)) STOP 1
31 recursive function fact (x
) result (res
)
33 integer, intent(in
) :: x
38 res
= x
* fact (x
- 1) ! { dg-optimized {assigned OpenACC seq loop parallelism} }