From: Sacha Refshauge Date: Sat, 19 Aug 2017 05:07:42 +0000 (+1000) Subject: Fix threading usage in CMake: s/SMP/USE_THREAD/ X-Git-Tag: v0.3.0~82^2~10 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=37858d11462110a9f5b3c28dd6ed5915c6010925;p=platform%2Fupstream%2Fopenblas.git Fix threading usage in CMake: s/SMP/USE_THREAD/ --- diff --git a/driver/level2/CMakeLists.txt b/driver/level2/CMakeLists.txt index aa5f031..8fceba9 100644 --- a/driver/level2/CMakeLists.txt +++ b/driver/level2/CMakeLists.txt @@ -73,7 +73,7 @@ GenerateNamedObjects("zgbmv_k.c" "TRANS;CONJ;XCONJ" "gbmv_d" false "" "" "" 2) # special defines for complex foreach (float_type ${FLOAT_TYPES}) - if (SMP) + if (USE_THREAD) GenerateNamedObjects("gemv_thread.c" "" "gemv_thread_n" false "" "" false ${float_type}) GenerateNamedObjects("gemv_thread.c" "TRANSA" "gemv_thread_t" false "" "" false ${float_type}) @@ -107,7 +107,7 @@ foreach (float_type ${FLOAT_TYPES}) GenerateNamedObjects("z${ulvm_source}" "LOWER;HEMVREV" "${op_name}_M" false "" "" false ${float_type}) endforeach() - if (SMP) + if (USE_THREAD) GenerateNamedObjects("gemv_thread.c" "CONJ" "gemv_thread_r" false "" "" false ${float_type}) GenerateNamedObjects("gemv_thread.c" "CONJ;TRANSA" "gemv_thread_c" false "" "" false ${float_type}) @@ -186,7 +186,7 @@ foreach (float_type ${FLOAT_TYPES}) GenerateCombinationObjects("${l_source}" "UNIT" "N" "TRANSA" 0 "${op_name}_TU" false ${float_type}) endforeach () - if (SMP) + if (USE_THREAD) GenerateNamedObjects("ger_thread.c" "" "" false "" "" false ${float_type}) foreach(nu_smp_source ${NU_SMP_SOURCES}) string(REGEX MATCH "[a-z]+_[a-z]+" op_name ${nu_smp_source}) @@ -197,7 +197,7 @@ foreach (float_type ${FLOAT_TYPES}) endif () endforeach () -if (SMP) +if (USE_THREAD) GenerateCombinationObjects("${UL_SMP_SOURCES}" "LOWER" "U" "" 2) endif () diff --git a/driver/level3/CMakeLists.txt b/driver/level3/CMakeLists.txt index c91e85f..f788c45 100644 --- a/driver/level3/CMakeLists.txt +++ b/driver/level3/CMakeLists.txt @@ -9,7 +9,7 @@ set(GEMM_COMPLEX_DEFINES RN CN RT CT NR TR RR CR NC TC RC CC) foreach (GEMM_DEFINE ${GEMM_DEFINES}) string(TOLOWER ${GEMM_DEFINE} GEMM_DEFINE_LC) GenerateNamedObjects("gemm.c" "${GEMM_DEFINE}" "gemm_${GEMM_DEFINE_LC}" 0) - if (SMP AND NOT USE_SIMPLE_THREADED_LEVEL3) + if (USE_THREAD AND NOT USE_SIMPLE_THREADED_LEVEL3) GenerateNamedObjects("gemm.c" "${GEMM_DEFINE};THREADED_LEVEL3" "gemm_thread_${GEMM_DEFINE_LC}" 0) endif () endforeach () @@ -32,7 +32,7 @@ GenerateCombinationObjects("syrk_k.c" "LOWER;TRANS" "U;N" "" 1) GenerateCombinationObjects("syr2k_k.c" "LOWER;TRANS" "U;N" "" 1) GenerateCombinationObjects("syrk_kernel.c" "LOWER" "U" "" 2) GenerateCombinationObjects("syr2k_kernel.c" "LOWER" "U" "" 2) -if (SMP) +if (USE_THREAD) # N.B. these do NOT have a float type (e.g. DOUBLE) defined! GenerateNamedObjects("gemm_thread_m.c;gemm_thread_n.c;gemm_thread_mn.c;gemm_thread_variable.c;syrk_thread.c" "" "" 0 "" "" 1) @@ -71,7 +71,7 @@ foreach (float_type ${FLOAT_TYPES}) GenerateNamedObjects("zher2k_k.c" "HER2K;LOWER" "her2k_LN" false "" "" false ${float_type}) GenerateNamedObjects("zher2k_k.c" "HER2K;LOWER;TRANS;CONJ" "her2k_LC" false "" "" false ${float_type}) - if (SMP AND NOT USE_SIMPLE_THREADED_LEVEL3) + if (USE_THREAD AND NOT USE_SIMPLE_THREADED_LEVEL3) #herk GenerateCombinationObjects("zherk_k.c" "LOWER" "U" "HERK;THREADED_LEVEL3" 3 "herk_thread_N" false ${float_type}) GenerateCombinationObjects("zherk_k.c" "LOWER" "U" "HERK;THREADED_LEVEL3;TRANS;CONJ" 3 "herk_thread_C" false ${float_type}) @@ -93,7 +93,7 @@ foreach (float_type ${FLOAT_TYPES}) if(USE_GEMM3M) GenerateNamedObjects("gemm3m.c" "${gemm_define}" "gemm3m_${gemm_define_LC}" false "" "" false ${float_type}) endif() - if (SMP AND NOT USE_SIMPLE_THREADED_LEVEL3) + if (USE_THREAD AND NOT USE_SIMPLE_THREADED_LEVEL3) GenerateNamedObjects("gemm.c" "${gemm_define};THREADED_LEVEL3" "gemm_thread_${gemm_define_LC}" false "" "" false ${float_type}) if(USE_GEMM3M) GenerateNamedObjects("gemm3m.c" "${gemm_define};THREADED_LEVEL3" "gemm3m_thread_${gemm_define_LC}" false "" "" false ${float_type}) @@ -106,7 +106,7 @@ foreach (float_type ${FLOAT_TYPES}) foreach (GEMM_DEFINE ${GEMM_DEFINES}) string(TOLOWER ${GEMM_DEFINE} GEMM_DEFINE_LC) GenerateNamedObjects("gemm3m.c" "${GEMM_DEFINE}" "gemm3m_${GEMM_DEFINE_LC}" false "" "" false ${float_type}) - if (SMP AND NOT USE_SIMPLE_THREADED_LEVEL3) + if (USE_THREAD AND NOT USE_SIMPLE_THREADED_LEVEL3) GenerateNamedObjects("gemm3m.c" "${GEMM_DEFINE};THREADED_LEVEL3" "gemm3m_thread_${GEMM_DEFINE_LC}" false "" "" false ${float_type}) endif () endforeach () diff --git a/driver/others/CMakeLists.txt b/driver/others/CMakeLists.txt index 376cc66..e20b14e 100644 --- a/driver/others/CMakeLists.txt +++ b/driver/others/CMakeLists.txt @@ -7,7 +7,7 @@ else () set(MEMORY memory.c) endif () -if (SMP) +if (USE_THREAD) if (USE_OPENMP) set(BLAS_SERVER blas_server_omp.c) diff --git a/lapack/CMakeLists.txt b/lapack/CMakeLists.txt index b613c6c..9fb0006 100644 --- a/lapack/CMakeLists.txt +++ b/lapack/CMakeLists.txt @@ -46,7 +46,7 @@ GenerateNamedObjects("${LAPACK_MANGLED_SOURCES}" "" "" false "" "" false 3) GenerateNamedObjects("laswp/generic/laswp_k.c" "" "laswp_plus" false "" "" false 3) GenerateNamedObjects("laswp/generic/laswp_k.c" "MINUS" "laswp_minus" false "" "" false 3) -if (SMP) +if (USE_THREAD) if (USE_OPENMP) set(GETRF_SRC getrf/getrf_parallel_omp.c)