Skip to content

Commit ef9e3f7

Browse files
authored
Merge pull request #5149 from martin-frbg/fixup5077-5088
Make the Neoverse GEMM/GEMV throttling code conditional on SMP
2 parents 1533fe4 + 09ba099 commit ef9e3f7

File tree

2 files changed

+4
-7
lines changed

2 files changed

+4
-7
lines changed

interface/gemm.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -177,6 +177,7 @@ static int init_amxtile_permission() {
177177
}
178178
#endif
179179

180+
#ifdef SMP
180181
#ifdef DYNAMIC_ARCH
181182
extern char* gotoblas_corename(void);
182183
#endif
@@ -242,6 +243,7 @@ static inline int get_gemm_optimal_nthreads(double MNK) {
242243
}
243244
}
244245
}
246+
#endif
245247

246248
#ifndef CBLAS
247249

interface/gemv.c

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,7 @@ static int (*gemv_thread[])(BLASLONG, BLASLONG, FLOAT, FLOAT *, BLASLONG, FLOAT
6363
};
6464
#endif
6565

66+
#ifdef SMP
6667
#ifdef DYNAMIC_ARCH
6768
extern char* gotoblas_corename(void);
6869
#endif
@@ -108,6 +109,7 @@ static inline int get_gemv_optimal_nthreads(BLASLONG MN) {
108109
else
109110
return num_cpu_avail(2);
110111
}
112+
#endif
111113

112114
#ifndef CBLAS
113115

@@ -248,13 +250,6 @@ void CNAME(enum CBLAS_ORDER order,
248250

249251
if (alpha == ZERO) return;
250252

251-
#if 0
252-
/* this optimization causes stack corruption on x86_64 under OSX, Windows and FreeBSD */
253-
if (trans == 0 && incx == 1 && incy == 1 && m*n < 2304 *GEMM_MULTITHREAD_THRESHOLD) {
254-
GEMV_N(m, n, 0, alpha, a, lda, x, incx, y, incy, NULL);
255-
return;
256-
}
257-
#endif
258253
IDEBUG_START;
259254

260255
FUNCTION_PROFILE_START();

0 commit comments

Comments
 (0)