Browse Source

make NAN handling depend on dummy2 parameter

tags/v0.3.28^2
Martin Kroeker GitHub 1 year ago
parent
commit
7284c533b5
No known key found for this signature in database GPG Key ID: B5690EEEBB952194
1 changed files with 15 additions and 3 deletions
  1. +15
    -3
      kernel/riscv64/scal.c

+ 15
- 3
kernel/riscv64/scal.c View File

@@ -43,9 +43,9 @@ int CNAME(BLASLONG n, BLASLONG dummy0, BLASLONG dummy1, FLOAT da, FLOAT *x, BLAS
if ( (n <= 0) || (inc_x <= 0))
return(0);
while(j < n)
{
if (dummy2 == 0) {
while(j < n)
{

if ( da == 0.0 )
if (isfinite(x[i]))
@@ -57,7 +57,19 @@ int CNAME(BLASLONG n, BLASLONG dummy0, BLASLONG dummy1, FLOAT da, FLOAT *x, BLAS

i += inc_x ;
j++;
}
} else {
while(j < n)
{

if ( da == 0.0 )
x[i]=0.0;
else
x[i] = da * x[i] ;

i += inc_x ;
j++;
}
}
return 0;



Loading…
Cancel
Save