Skip to content

Commit 0400fb5

Browse files
Fixes a bug in the Blue's scaling constants of nrm2 thanks to Arm Performance Libraries!
This is the same bug fixed on #559 for la_constants.f90.
1 parent c14db3b commit 0400fb5

File tree

4 files changed

+12
-12
lines changed

4 files changed

+12
-12
lines changed

BLAS/SRC/dnrm2.f90

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -99,15 +99,15 @@ function DNRM2( n, x, incx )
9999
real(wp), parameter :: one = 1.0_wp
100100
real(wp), parameter :: maxN = huge(0.0_wp)
101101
! ..
102-
! .. Blue's ccaling constants ..
102+
! .. Blue's scaling constants ..
103103
real(wp), parameter :: tsml = real(radix(0._wp), wp)**ceiling( &
104104
(minexponent(0._wp) - 1) * 0.5_wp)
105105
real(wp), parameter :: tbig = real(radix(0._wp), wp)**floor( &
106106
(maxexponent(0._wp) - digits(0._wp) + 1) * 0.5_wp)
107107
real(wp), parameter :: ssml = real(radix(0._wp), wp)**( - floor( &
108-
(minexponent(0._wp) - 1) * 0.5_wp))
108+
(minexponent(0._wp) - digits(0._wp)) * 0.5_wp))
109109
real(wp), parameter :: sbig = real(radix(0._wp), wp)**( - ceiling( &
110-
(maxexponent(0._wp) - digits(0._wp) + 1) * 0.5_wp))
110+
(maxexponent(0._wp) + digits(0._wp) - 1) * 0.5_wp))
111111
! ..
112112
! .. Scalar Arguments ..
113113
integer :: incx, n

BLAS/SRC/dznrm2.f90

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -100,15 +100,15 @@ function DZNRM2( n, x, incx )
100100
real(wp), parameter :: one = 1.0_wp
101101
real(wp), parameter :: maxN = huge(0.0_wp)
102102
! ..
103-
! .. Blue's ccaling constants ..
103+
! .. Blue's scaling constants ..
104104
real(wp), parameter :: tsml = real(radix(0._wp), wp)**ceiling( &
105105
(minexponent(0._wp) - 1) * 0.5_wp)
106106
real(wp), parameter :: tbig = real(radix(0._wp), wp)**floor( &
107107
(maxexponent(0._wp) - digits(0._wp) + 1) * 0.5_wp)
108108
real(wp), parameter :: ssml = real(radix(0._wp), wp)**( - floor( &
109-
(minexponent(0._wp) - 1) * 0.5_wp))
109+
(minexponent(0._wp) - digits(0._wp)) * 0.5_wp))
110110
real(wp), parameter :: sbig = real(radix(0._wp), wp)**( - ceiling( &
111-
(maxexponent(0._wp) - digits(0._wp) + 1) * 0.5_wp))
111+
(maxexponent(0._wp) + digits(0._wp) - 1) * 0.5_wp))
112112
! ..
113113
! .. Scalar Arguments ..
114114
integer :: incx, n

BLAS/SRC/scnrm2.f90

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -100,15 +100,15 @@ function SCNRM2( n, x, incx )
100100
real(wp), parameter :: one = 1.0_wp
101101
real(wp), parameter :: maxN = huge(0.0_wp)
102102
! ..
103-
! .. Blue's ccaling constants ..
103+
! .. Blue's scaling constants ..
104104
real(wp), parameter :: tsml = real(radix(0._wp), wp)**ceiling( &
105105
(minexponent(0._wp) - 1) * 0.5_wp)
106106
real(wp), parameter :: tbig = real(radix(0._wp), wp)**floor( &
107107
(maxexponent(0._wp) - digits(0._wp) + 1) * 0.5_wp)
108108
real(wp), parameter :: ssml = real(radix(0._wp), wp)**( - floor( &
109-
(minexponent(0._wp) - 1) * 0.5_wp))
109+
(minexponent(0._wp) - digits(0._wp)) * 0.5_wp))
110110
real(wp), parameter :: sbig = real(radix(0._wp), wp)**( - ceiling( &
111-
(maxexponent(0._wp) - digits(0._wp) + 1) * 0.5_wp))
111+
(maxexponent(0._wp) + digits(0._wp) - 1) * 0.5_wp))
112112
! ..
113113
! .. Scalar Arguments ..
114114
integer :: incx, n

BLAS/SRC/snrm2.f90

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -99,15 +99,15 @@ function SNRM2( n, x, incx )
9999
real(wp), parameter :: one = 1.0_wp
100100
real(wp), parameter :: maxN = huge(0.0_wp)
101101
! ..
102-
! .. Blue's ccaling constants ..
102+
! .. Blue's scaling constants ..
103103
real(wp), parameter :: tsml = real(radix(0._wp), wp)**ceiling( &
104104
(minexponent(0._wp) - 1) * 0.5_wp)
105105
real(wp), parameter :: tbig = real(radix(0._wp), wp)**floor( &
106106
(maxexponent(0._wp) - digits(0._wp) + 1) * 0.5_wp)
107107
real(wp), parameter :: ssml = real(radix(0._wp), wp)**( - floor( &
108-
(minexponent(0._wp) - 1) * 0.5_wp))
108+
(minexponent(0._wp) - digits(0._wp)) * 0.5_wp))
109109
real(wp), parameter :: sbig = real(radix(0._wp), wp)**( - ceiling( &
110-
(maxexponent(0._wp) - digits(0._wp) + 1) * 0.5_wp))
110+
(maxexponent(0._wp) + digits(0._wp) - 1) * 0.5_wp))
111111
! ..
112112
! .. Scalar Arguments ..
113113
integer :: incx, n

0 commit comments

Comments
 (0)