Complement cmake script to compile tensorflow with mkl and mkldnn on Windows (#16936)
authorTang, Wenyi <twytwy12345@live.com>
Tue, 17 Apr 2018 19:17:48 +0000 (03:17 +0800)
committerDerek Murray <derek.murray@gmail.com>
Tue, 17 Apr 2018 19:17:48 +0000 (12:17 -0700)
commitf67aa59c264a0ca84d2ff2e7a551d16136af6e56
tree307ec19bcb087b433f31ff766785bfe8f9b433f0
parentf1b892b608a3e2b5fa8a16c03ac3c3ca6293ad65
Complement cmake script to compile tensorflow with mkl and mkldnn on Windows (#16936)

* Add build batch for windows

* Automaticaly find python, cuda, mkl runtimes in PATH

* auto select cmake generator

* Add external library mkldnn. Add options for mkl and mkldnn

* fix syntax error in make.bat

* Fix errorlevel syntex bug in make.bat

* Add /arch:avx2 flags to enable avx2 on windows

* Revert to keep `tensprflow_WIN_CPU_SIMD_OPTIONS` unchanged, add an option `tensorflow_ENABLE_MKL_SUPPORT` to include MKL compilation. Still specify SIMD flags by setting `tensorflow_WIN_CPU_SIMD_OPTIONS` to such as '/arch:AVX2'

* Fix a mistake of CUDA path in make.bat

* resolve conflict in mkl_cpu_allocator.h

* Improve error detection

* Use where /Q to detect cmd environment

* fix "ELSE IF" the syntax error in make.bat

* update README.md, wrap windows based codes by #ifdef _WIN32

* unistd.h is not needed in mkl_cpu_allocator.h any more in master branch

* Remove inline of kMaxLimitStr, which causes compile error in VS2015

* Add static_cast in  to fix compile error

* remove make.bat

* Removed make.bat description part
tensorflow/contrib/cmake/CMakeLists.txt
tensorflow/contrib/cmake/README.md
tensorflow/contrib/cmake/external/mkldnn.cmake [new file with mode: 0644]
tensorflow/core/common_runtime/mkl_cpu_allocator.h
tensorflow/core/graph/mkl_tfconversion_pass.h
tensorflow/core/kernels/mkl_relu_op.cc
tensorflow/core/util/mkl_util.h