Skip to content

Commit a373d0f

Browse files
authored
Improve the error message for thread creation failure
1 parent 6013b36 commit a373d0f

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

driver/others/blas_server.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -595,6 +595,8 @@ int blas_thread_init(void){
595595
struct rlimit rlim;
596596
const char *msg = strerror(ret);
597597
fprintf(STDERR, "OpenBLAS blas_thread_init: pthread_create failed for thread %ld of %d: %s\n", i+1,blas_num_threads,msg);
598+
fprintf(STDERR, "OpenBLAS blas_thread_init: ensure that your address space and process count limits are big enough (ulimit -a)\n");
599+
fprintf(STDERR, "OpenBLAS blas_thread_init: or set a smaller OPENBLAS_NUM_THREADS to fit into what you have available\n");
598600
#ifdef RLIMIT_NPROC
599601
if(0 == getrlimit(RLIMIT_NPROC, &rlim)) {
600602
fprintf(STDERR, "OpenBLAS blas_thread_init: RLIMIT_NPROC "

0 commit comments

Comments
 (0)