OpenCores
URL https://opencores.org/ocsvn/openrisc/openrisc/trunk

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [gfortran.dg/] [bessel_1.f90] - Blame information for rev 801

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

Line No. Rev Author Line
1 694 jeremybenn
! { dg-do run }
2
 
3
program test
4
  implicit none
5
 
6
  interface check
7
    procedure check_r4
8
    procedure check_r8
9
  end interface check
10
 
11
  real(kind=4) :: x4
12
  real(kind=8) :: x8
13
 
14
  x8 = 1.9_8 ; x4 = 1.9_4
15
  call check(bessel_j0 (x8), bessel_j0 (1.9_8))
16
  call check(bessel_j0 (x4), bessel_j0 (1.9_4))
17
  call check(bessel_j1 (x8), bessel_j1 (1.9_8))
18
  call check(bessel_j1 (x4), bessel_j1 (1.9_4))
19
  call check(bessel_jn (3,x8), bessel_jn (3,1.9_8))
20
  call check(bessel_jn (3,x4), bessel_jn (3,1.9_4))
21
  call check(bessel_y0 (x8), bessel_y0 (1.9_8))
22
  call check(bessel_y0 (x4), bessel_y0 (1.9_4))
23
  call check(bessel_y1 (x8), bessel_y1 (1.9_8))
24
  call check(bessel_y1 (x4), bessel_y1 (1.9_4))
25
  call check(bessel_yn (3,x8), bessel_yn (3,1.9_8))
26
  call check(bessel_yn (3,x4), bessel_yn (3,1.9_4))
27
 
28
contains
29
  subroutine check_r4 (a, b)
30
    real(kind=4), intent(in) :: a, b
31
    if (abs(a - b) > 1.e-5 * abs(b)) call abort
32
  end subroutine
33
  subroutine check_r8 (a, b)
34
    real(kind=8), intent(in) :: a, b
35
    if (abs(a - b) > 1.e-7 * abs(b)) call abort
36
  end subroutine
37
end program test

powered by: WebSVN 2.1.0

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