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.2.2/] [gcc/] [testsuite/] [gfortran.dg/] [large_real_kind_form_io_2.f90] - Blame information for rev 154

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 149 jeremybenn
! { dg-do run }
2
! { dg-require-effective-target fortran_large_real }
3
! PR libfortran/24685
4
program large_real_kind_form_io_2
5
  ! This should be 10 or 16 on systems that support kind=10 or kind=16
6
  integer, parameter :: k = selected_real_kind (precision (0.0_8) + 1)
7
  real(kind=k) :: a,b(2), c
8
  character(len=180) :: tmp
9
 
10
  b(:) = huge(0.0_k)
11
  write (tmp, *) b
12
  read (tmp, *) a, c
13
  if (a /= b(1)) call abort ()
14
  if (c /= b(2)) call abort ()
15
 
16
  b(:) = -huge(0.0_k)
17
  write (tmp, *) b
18
  read (tmp, *) a, c
19
  if (a /= b(1)) call abort ()
20
  if (c /= b(2)) call abort ()
21
 
22
  b(:) = nearest(tiny(0.0_k),1.0_k)
23
  write (tmp, *) b
24
  read (tmp, *) a, c
25
  if (a /= b(1)) call abort ()
26
  if (c /= b(2)) call abort ()
27
 
28
  b(:) = nearest(-tiny(0.0_k),-1.0_k)
29
  write (tmp, *) b
30
  read (tmp, *) a, c
31
  if (a /= b(1)) call abort ()
32
  if (c /= b(2)) call abort ()
33
end program large_real_kind_form_io_2

powered by: WebSVN 2.1.0

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