URL
https://opencores.org/ocsvn/openrisc_2011-10-31/openrisc_2011-10-31/trunk
Only display areas with differences |
Details |
Blame |
View Log
Rev 302 |
Rev 384 |
! Test for the ISNAN intrinsic
|
! Test for the ISNAN intrinsic
|
!
|
!
|
! { dg-do run }
|
! { dg-do run }
|
! { dg-add-options ieee }
|
! { dg-add-options ieee }
|
! { dg-skip-if "NaN not supported" { spu-*-* } { "*" } { "" } }
|
! { dg-skip-if "NaN not supported" { spu-*-* } { "*" } { "" } }
|
!
|
!
|
implicit none
|
implicit none
|
real :: x
|
real :: x
|
x = -1.0
|
x = -1.0
|
x = sqrt(x)
|
x = sqrt(x)
|
if (.not. isnan(x)) call abort
|
if (.not. isnan(x)) call abort
|
x = 0.0
|
x = 0.0
|
x = x / x
|
x = x / x
|
if (.not. isnan(x)) call abort
|
if (.not. isnan(x)) call abort
|
|
|
x = 5.0
|
x = 5.0
|
if (isnan(x)) call abort
|
if (isnan(x)) call abort
|
x = huge(x)
|
x = huge(x)
|
x = 2*x
|
x = 2*x
|
if (isnan(x)) call abort
|
if (isnan(x)) call abort
|
end
|
end
|
|
|
© copyright 1999-2024
OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.