[FEATURE] Enable dynamic linking with MKL and compiler based OpenMP#20474
[FEATURE] Enable dynamic linking with MKL and compiler based OpenMP#20474leezu merged 16 commits intoapache:masterfrom
Conversation
|
Hey @akarbown , Thanks for submitting the PR
CI supported jobs: [edge, sanity, miscellaneous, centos-cpu, windows-cpu, unix-cpu, unix-gpu, clang, website, centos-gpu, windows-gpu] Note: |
src/initialize.cc
Outdated
| #if defined( __INTEL_LLVM_COMPILER) | ||
| mkl_set_threading_layer(MKL_THREADING_INTEL); | ||
| #else | ||
| mkl_set_threading_layer(MKL_THREADING_GNU); |
There was a problem hiding this comment.
Does this work with Windows? Intel developer's reference states "for GNU threading on Linux* operating system only" https://software.intel.com/content/www/us/en/develop/documentation/onemkl-developer-reference-c/top/support-functions/single-dynamic-library-control/mkl-set-threading-layer.html
There was a problem hiding this comment.
Good point! I forgot about Windows! I'll exclude it in a moment.
56c1404 to
b3c66c6
Compare
|
@mxnet-bot run ci[sanity] |
|
Jenkins CI successfully triggered : [sanity] |
|
@mxnet-bot run ci [all] |
|
@mxnet-bot run ci[all] |
|
@leezu, could you help me with rerunning 'sanity' check in this PR? I've checked it locally and I don't see any issues. I suppose that this sanity check failed because of the timeout (SIGTERM). Is it possible? |
|
@josephevans can we extend the max time for sanity? This PR triggers rebuild of the Docker used for Sanity, and apparently thus timeouts |
|
@mxnet-bot run ci [unix-cpu] |
|
@mxnet-bot run ci[website] |
|
Jenkins CI successfully triggered : [website] |
|
@mxnet-bot run ci[clang, miscellaneous, unix-cpu, unix-gpu] |
|
Jenkins CI successfully triggered : [unix-gpu, clang, miscellaneous, unix-cpu] |
|
@mxnet-bot run ci[unix-cpu] |
|
Jenkins CI successfully triggered : [unix-cpu] |
|
@mxnet-bot run ci[unix-gpu, miscellaneous] |
|
Jenkins CI successfully triggered : [unix-gpu, miscellaneous] |
|
@mxnet-bot run ci[miscellaneous] |
|
Jenkins CI successfully triggered : [miscellaneous] |
|
@mxnet-bot run ci[miscellaneous] |
|
Jenkins CI successfully triggered : [miscellaneous] |
|
@mxnet-bot run ci[miscellaneous] |
|
Jenkins CI successfully triggered : [miscellaneous] |
|
@mxnet-bot run ci[unix-cpu, unix-gpu] |
|
Jenkins CI successfully triggered : [unix-cpu, unix-gpu] |
|
@mxnet-bot run ci[unix-cpu] |
|
Jenkins CI successfully triggered : [unix-cpu] |
This is a temporary change to check if adding MKL runtime support won't crash MacOS.
Turn off SDL for MKL on MacOS as it need fixes.
Add proper mkl_threading flags for Mac Os. Enable all tests that are for MacOS + MKL tests. Rebuild numpy with MKL BLAS (instead of OpenBLAS).
1041620 to
3cd9340
Compare
|
@mxnet-bot run ci[unix-cpu, unix-gpu, centos-gpu] |
|
Jenkins CI successfully triggered : [unix-cpu, unix-gpu, centos-gpu] |
|
@mxnet-bot run ci[centos-gpu] |
|
Jenkins CI successfully triggered : [centos-gpu] |
|
Thank you @akarbown! |
OneMKL 2021.3 fixed linking OpenMP while using SDL and MKL_THREADING_LAYER set to GNU.
Description
OneMKL 2021.3 fixes the issue described here. Thus, it enables linking with MKL dynamic libraries without having multiple OneMPs in a single process. It is possible due to linking MxNET with oneMKL Single Dynamic Library (SDL) and then setting the appropriate threading layer at run time in a function mkl_threading_layer() (or through environment variable MKL_THREADING_LAYER).
Connected with: [#19610], [#18255] and [#17794].
Changes
Comments
Does using oneMKL 2021.3 as the recommended one should be mentioned in the documentation?