1! { dg-additional-options "-fdump-tree-original -fdump-tree-gimple -std=f2008" }
2
3! test for tree-dump-original and spaces-commas
4
5program test
6  implicit none
7  integer :: i, j, k, m, sum
8  REAL :: a(64), b(64), c(64)
9
10  !$acc kernels
11  !$acc loop collapse(2)
12  DO i = 1,10
13    DO j = 1,10
14    ENDDO
15  ENDDO
16
17  !$acc loop independent gang (3)
18  DO i = 1,10
19    !$acc loop worker(3)
20    DO j = 1,10
21      !$acc loop vector(5)
22      DO k = 1,10
23      ENDDO
24    ENDDO
25  ENDDO
26  !$acc end kernels
27
28  sum = 0
29  !$acc parallel
30  !$acc loop private(m) reduction(+:sum)
31  DO i = 1,10
32    sum = sum + 1
33  ENDDO
34  !$acc end parallel
35
36end program test
37! { dg-final { scan-tree-dump-times "pragma acc loop" 5 "original" } }
38
39! { dg-final { scan-tree-dump-times "collapse\\(2\\)" 1 "original" } }
40! { dg-final { scan-tree-dump-times "independent" 1 "original" } }
41! { dg-final { scan-tree-dump-times "gang\\(num: 3\\)" 1 "original" } }
42! { dg-final { scan-tree-dump-times "worker\\(3\\)" 1 "original" } }
43! { dg-final { scan-tree-dump-times "vector\\(5\\)" 1 "original" } }
44
45! { dg-final { scan-tree-dump-times "private\\(m\\)" 1 "original" } }
46! { dg-final { scan-tree-dump-times "reduction\\(\\+:sum\\)" 1 "original" } }
47! { dg-final { scan-tree-dump-times "map\\(tofrom:sum \\\[len: \[0-9\]+\\\]\\)" 1 "gimple" } }
48