use non signaling version of NaN

This commit is contained in:
Franz Roters 2012-05-11 07:35:52 +00:00
parent c962452cda
commit babf2647fb
1 changed files with 3 additions and 3 deletions

View File

@ -41,9 +41,9 @@ module prec
! from http://www.hpc.unimelb.edu.au/doc/f90lrm/dfum_035.html
! copy can be found in documentation/Code/Fortran
#ifdef LEGACY_COMPILER
real(pReal), parameter, public :: DAMASK_NaN = Z'7FF0000000000001'
real(pReal), parameter, public :: DAMASK_NaN = Z'7FF8000000000000' ! quiet NaN
#else
real(pReal), parameter, public :: DAMASK_NaN = real(Z'7FF0000000000001', pReal)
real(pReal), parameter, public :: DAMASK_NaN = real(Z'7FF8000000000000', pReal)
#endif
type, public :: p_vec
@ -71,7 +71,7 @@ subroutine prec_init
write(6,'(a,i3)') ' Bytes for pReal: ',pReal
write(6,'(a,i3)') ' Bytes for pInt: ',pInt
write(6,'(a,i3)') ' Bytes for pLongInt: ',pLongInt
write(6,'(a,e10.3)') ' NaN: ',DAMASK_NAN
write(6,'(a,e10.3)') ' NaN: ',DAMASK_NaN
write(6,'(a,l3)') ' NaN /= NaN: ',DAMASK_NaN/=DAMASK_NaN
if (DAMASK_NaN == DAMASK_NaN) call quit(9000)
write(6,*)