Skip to content

Commit 28e75a8

Browse files
authored
Tag get/set_affinity with OPENBLAS_EXPORT
1 parent 4230fe4 commit 28e75a8

1 file changed

Lines changed: 3 additions & 2 deletions

File tree

driver/others/blas_server.c

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -335,7 +335,7 @@ static void legacy_exec(void *func, int mode, blas_arg_t *args, void *sb){
335335
}
336336
}
337337

338-
#if defined(OS_LINUX) && !defined(NO_AFFINITY)
338+
#if defined(OS_LINUX) && !defined(NO_AFFINITY)
339339
int gotoblas_set_affinity(int);
340340
int gotoblas_set_affinity2(int);
341341
int get_node(void);
@@ -345,7 +345,7 @@ static int increased_threads = 0;
345345

346346
#ifdef OS_LINUX
347347
extern int openblas_get_num_threads(void);
348-
348+
OPENBLAS_EXPORT
349349
int openblas_setaffinity(int thread_idx, size_t cpusetsize, cpu_set_t* cpu_set) {
350350
const int active_threads = openblas_get_num_threads();
351351

@@ -360,6 +360,7 @@ int openblas_setaffinity(int thread_idx, size_t cpusetsize, cpu_set_t* cpu_set)
360360

361361
return pthread_setaffinity_np(thread, cpusetsize, cpu_set);
362362
}
363+
OPENBLAS_EXPORT
363364
int openblas_getaffinity(int thread_idx, size_t cpusetsize, cpu_set_t* cpu_set) {
364365
const int active_threads = openblas_get_num_threads();
365366

0 commit comments

Comments
 (0)