OpenCores
URL https://opencores.org/ocsvn/openrisc_2011-10-31/openrisc_2011-10-31/trunk

Subversion Repositories openrisc_2011-10-31

[/] [openrisc/] [trunk/] [gnu-src/] [gcc-4.5.1/] [gcc/] [testsuite/] [gfortran.dg/] [gomp/] [omp_do1.f90] - Blame information for rev 484

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 302 jeremybenn
! { dg-do compile }
2
! { dg-options "-fopenmp -std=gnu" }
3
subroutine foo
4
  integer :: i, j
5
  integer, dimension (30) :: a
6
  double precision :: d
7
  i = 0
8
!$omp do private (i)
9
  do 100 ! { dg-error "cannot be a DO WHILE or DO without loop control" }
10
    if (i .gt. 0) exit ! { dg-error "EXIT statement" }
11
100 i = i + 1
12
  i = 0
13
!$omp do private (i)
14
  do ! { dg-error "cannot be a DO WHILE or DO without loop control" }
15
    if (i .gt. 0) exit ! { dg-error "EXIT statement" }
16
    i = i + 1
17
  end do
18
  i = 0
19
!$omp do private (i)
20
  do 200 while (i .lt. 4) ! { dg-error "cannot be a DO WHILE or DO without loop control" }
21
200 i = i + 1
22
!$omp do private (i)
23
  do while (i .lt. 8) ! { dg-error "cannot be a DO WHILE or DO without loop control" }
24
    i = i + 1
25
  end do
26
!$omp do
27
  do 300 d = 1, 30, 6 ! { dg-warning "Deleted feature: Loop variable" }
28
    i = d
29
300 a(i) = 1
30
!$omp do
31
  do d = 1, 30, 5 ! { dg-warning "Deleted feature: Loop variable" }
32
    i = d
33
    a(i) = 2
34
  end do
35
!$omp do
36
  do i = 1, 30
37
    if (i .eq. 16) exit ! { dg-error "EXIT statement" }
38
  end do
39
!$omp do
40
outer: do i = 1, 30
41
    do j = 5, 10
42
      if (i .eq. 6 .and. j .eq. 7) exit outer ! { dg-error "EXIT statement" }
43
    end do
44
  end do outer
45
last: do i = 1, 30
46
!$omp parallel
47
    if (i .eq. 21) exit last ! { dg-error "leaving OpenMP structured block" }
48
!$omp end parallel
49
  end do last
50
!$omp parallel do shared (i)
51
  do i = 1, 30, 2 ! { dg-error "iteration variable present on clause" }
52
    a(i) = 5
53
  end do
54
!$omp end parallel do
55
end subroutine
56
! { dg-error "iteration variable must be of type integer" "" { target *-*-* } 27 }
57
! { dg-error "iteration variable must be of type integer" "" { target *-*-* } 31 }

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.