From a69da64cbb7c883333058c9adec508e7289b36d4 Mon Sep 17 00:00:00 2001 From: Martin Kroeker Date: Sun, 24 Mar 2024 10:14:14 +0100 Subject: [PATCH] restore the outer while() loop around blas_buffer_inuse setup --- driver/others/blas_server_omp.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/driver/others/blas_server_omp.c b/driver/others/blas_server_omp.c index 23110f807..bb9a644f8 100644 --- a/driver/others/blas_server_omp.c +++ b/driver/others/blas_server_omp.c @@ -407,6 +407,7 @@ int exec_blas(BLASLONG num, blas_queue_t *queue){ } #endif +while (true) for(i=0; i < MAX_PARALLEL_NUMBER; i++) { #ifdef HAVE_C11 _Bool inuse = false; @@ -419,7 +420,9 @@ int exec_blas(BLASLONG num, blas_queue_t *queue){ break; } } - + if (i != MAX_PARALLEL_NUMBER) + break; +} if (openblas_omp_adaptive_env() != 0) { #pragma omp parallel for num_threads(num) schedule(OMP_SCHED) for (i = 0; i < num; i ++) {