diff --git a/MultiSource/Benchmarks/TSVC/tsc.inc b/MultiSource/Benchmarks/TSVC/tsc.inc --- a/MultiSource/Benchmarks/TSVC/tsc.inc +++ b/MultiSource/Benchmarks/TSVC/tsc.inc @@ -3760,14 +3760,14 @@ for (int nl = 0; nl < ntimes/2; nl++) { k = 0; index = 0; - max = abs(a[0]); + max = FABS(a[0]); k += inc; for (int i = 1; i < LEN; i++) { - if (abs(a[k]) <= max) { + if (FABS(a[k]) <= max) { goto L5; } index = i; - max = abs(a[k]); + max = FABS(a[k]); L5: k += inc; } @@ -3971,10 +3971,10 @@ TYPE max; for (int nl = 0; nl < ntimes*4; nl++) { - max = abs(a[0]); + max = FABS(a[0]); for (int i = 0; i < LEN; i++) { - if ((abs(a[i])) > max) { - max = abs(a[i]); + if ((FABS(a[i])) > max) { + max = FABS(a[i]); } } dummy(a, b, c, d, e, aa, bb, cc, max); diff --git a/MultiSource/Benchmarks/TSVC/types.h b/MultiSource/Benchmarks/TSVC/types.h --- a/MultiSource/Benchmarks/TSVC/types.h +++ b/MultiSource/Benchmarks/TSVC/types.h @@ -5,11 +5,14 @@ #define LEN2 256 #ifndef TYPE -#define TYPE float + #define TYPE float + #define FABS(x) fabsf(x) +#else + #define FABS(x) fabs(x) #endif #ifndef X_TYPE -#define X_TYPE TYPE + #define X_TYPE TYPE #endif #ifndef ALIGNMENT