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

Subversion Repositories openrisc_2011-10-31

[/] [openrisc/] [tags/] [gnu-src/] [gcc-4.5.1/] [gcc-4.5.1-or32-1.0rc1/] [gcc/] [testsuite/] [gfortran.fortran-torture/] [execute/] [test_slice.f90] - Diff between revs 303 and 338

Only display areas with differences | Details | Blame | View Log

Rev 303 Rev 338
! Program to test handling of reduced rank array sections.  This uncovered
! Program to test handling of reduced rank array sections.  This uncovered
! bugs in simplify_shape and the scalarization of array sections.
! bugs in simplify_shape and the scalarization of array sections.
program test_slice
program test_slice
  implicit none
  implicit none
  real (kind = 8), dimension(2, 2, 2) :: x
  real (kind = 8), dimension(2, 2, 2) :: x
  real (kind = 8) :: min, max
  real (kind = 8) :: min, max
  x = 1.0
  x = 1.0
  if (minval(x(1, 1:2, 1:1)) .ne. 1.0) call abort ()
  if (minval(x(1, 1:2, 1:1)) .ne. 1.0) call abort ()
  if (maxval(x(1, 1:2, 1:1)) .ne. 1.0) call abort ()
  if (maxval(x(1, 1:2, 1:1)) .ne. 1.0) call abort ()
  if (any (shape(x(1, 1:2, 1:1)) .ne. (/2, 1/))) call abort ()
  if (any (shape(x(1, 1:2, 1:1)) .ne. (/2, 1/))) call abort ()
  if (any (shape(x(1, 1:2, 1)) .ne. (/2/))) call abort ()
  if (any (shape(x(1, 1:2, 1)) .ne. (/2/))) call abort ()
  if (any (shape(x(1:1, 1:2, 1:1)) .ne. (/1, 2, 1/))) call abort ()
  if (any (shape(x(1:1, 1:2, 1:1)) .ne. (/1, 2, 1/))) call abort ()
end program test_slice
end program test_slice
 
 

powered by: WebSVN 2.1.0

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