check for zero inc

This commit is contained in:
kseniyazaytseva 2024-02-10 00:48:07 +03:00
parent 5e9ead09ac
commit c6f30fd414
1 changed files with 20 additions and 0 deletions

View File

@ -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();