check for zero inc
This commit is contained in:
parent
5e9ead09ac
commit
c6f30fd414
|
@ -46,6 +46,12 @@
|
|||
|
||||
#ifdef USE_ABS
|
||||
|
||||
#if defined(DOUBLE)
|
||||
#define ABS fabs
|
||||
#else
|
||||
#define ABS fabsf
|
||||
#endif
|
||||
|
||||
#ifndef USE_MIN
|
||||
|
||||
/* ABS & MAX */
|
||||
|
@ -92,6 +98,8 @@
|
|||
|
||||
#else
|
||||
|
||||
#define ABS
|
||||
|
||||
#ifndef USE_MIN
|
||||
|
||||
/* MAX */
|
||||
|
@ -130,6 +138,12 @@ FLOATRET NAME(blasint *N, FLOAT *x, blasint *INCX){
|
|||
|
||||
if (n <= 0) return 0;
|
||||
|
||||
#ifndef COMPLEX
|
||||
if (incx == 0) return (ABS(*x));
|
||||
#else
|
||||
if (incx == 0) return (ABS(*x) + ABS(*(x+1)));
|
||||
#endif
|
||||
|
||||
IDEBUG_START;
|
||||
|
||||
FUNCTION_PROFILE_START();
|
||||
|
@ -158,6 +172,12 @@ FLOAT CNAME(blasint n, FLOAT *x, blasint incx){
|
|||
|
||||
if (n <= 0) return 0;
|
||||
|
||||
#ifndef COMPLEX
|
||||
if (incx == 0) return (ABS(*x));
|
||||
#else
|
||||
if (incx == 0) return (ABS(*x) + ABS(*(x+1)));
|
||||
#endif
|
||||
|
||||
IDEBUG_START;
|
||||
|
||||
FUNCTION_PROFILE_START();
|
||||
|
|
Loading…
Reference in New Issue