lebeg commented on a change in pull request #13681: Making MKL-DNN default on MXNet master URL: https://github.com/apache/incubator-mxnet/pull/13681#discussion_r248077722
########## File path: CMakeLists.txt ########## @@ -20,7 +20,7 @@ mxnet_option(USE_F16C "Build with x86 F16C instruction support" ON) mxnet_option(USE_LAPACK "Build with lapack support" ON) mxnet_option(USE_MKL_IF_AVAILABLE "Use MKL if found" ON) mxnet_option(USE_MKLML_MKL "Use MKLDNN variant of MKL (if MKL found)" ON IF USE_MKL_IF_AVAILABLE AND (NOT APPLE)) -mxnet_option(USE_MKLDNN "Use MKLDNN variant of MKL (if MKL found)" ON IF USE_MKL_IF_AVAILABLE AND (NOT APPLE)) +mxnet_option(USE_MKLDNN "Use MKLDNN variant of MKL (if MKL found)" ON IF USE_MKL_IF_AVAILABLE AND (NOT APPLE) AND (NOT MSVC) AND (CMAKE_SYSTEM_PROCESSOR MATCHES x86_64)) Review comment: Yes, I think `SYSTEM_ARCHITECTURE STREQUAL "x86_64" AND NOT CMAKE_CROSSCOMPILING` should work. But you need to add the trick for `CMAKE_CROSSCOMPILING` from [here](https://github.com/apache/incubator-mxnet/pull/13576/files#diff-af3b638bc2a3e6c650974192a53c7291R6) as well: ``` # workaround to store CMAKE_CROSSCOMPILING because is getting reset by the project command if(CMAKE_CROSSCOMPILING) set(__CMAKE_CROSSCOMPILING ${CMAKE_CROSSCOMPILING}) set(__CMAKE_CROSSCOMPILING_OVERRIDE ON) endif() project(mxnet C CXX) if(__CMAKE_CROSSCOMPILING_OVERRIDE) set(CMAKE_CROSSCOMPILING ${__CMAKE_CROSSCOMPILING}) endif() ``` ---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: [email protected] With regards, Apache Git Services
