From d286daa2ba4a6461b0e587592459db6765d3745b Mon Sep 17 00:00:00 2001 From: wernsaar Date: Tue, 15 Jul 2014 14:41:35 +0200 Subject: [PATCH] adjusted number of threads for small size --- interface/gemm.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/interface/gemm.c b/interface/gemm.c index 07fea153c..74908e842 100644 --- a/interface/gemm.c +++ b/interface/gemm.c @@ -405,11 +405,11 @@ void CNAME(enum CBLAS_ORDER order, enum CBLAS_TRANSPOSE TransA, enum CBLAS_TRANS #ifndef COMPLEX double MNK = (double) args.m * (double) args.n * (double) args.k; - if ( MNK <= (1024.0 * (double) GEMM_MULTITHREAD_THRESHOLD) ) + if ( MNK <= (16.0 * 1024.0 * (double) GEMM_MULTITHREAD_THRESHOLD) ) nthreads_max = 1; else { - if ( MNK <= (65536.0 * (double) GEMM_MULTITHREAD_THRESHOLD) ) + if ( MNK <= (2.0 * 65536.0 * (double) GEMM_MULTITHREAD_THRESHOLD) ) { nthreads_max = 4; if ( args.m < 16 * GEMM_MULTITHREAD_THRESHOLD )