This is an automated email from the ASF dual-hosted git repository.

jxie pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-mxnet.git


The following commit(s) were added to refs/heads/master by this push:
     new 1264313  Add Intel openmp as a submodule and build for x86 
architectures (#8730)
1264313 is described below

commit 1264313183d35c86ed49e7ec708a076fe858325f
Author: Chris Olivier <cjolivie...@gmail.com>
AuthorDate: Wed Nov 22 14:38:55 2017 -0800

    Add Intel openmp as a submodule and build for x86 architectures (#8730)
    
    * Refreshed branch intel_openmp
    
    * Disable Intel OpenMP local build for Windows until a Windows user can fix
    
    * Ignore 3rdparty license headers
---
 .gitmodules             |  3 +++
 3rdparty/openmp         |  1 +
 CMakeLists.txt          | 15 ++++++++++-----
 LICENSE                 |  1 +
 tools/license_header.py |  1 +
 5 files changed, 16 insertions(+), 5 deletions(-)

diff --git a/.gitmodules b/.gitmodules
index 7a76cba..f9b2ab6 100644
--- a/.gitmodules
+++ b/.gitmodules
@@ -16,3 +16,6 @@
 [submodule "cub"]
        path = cub
        url = https://github.com/dmlc/cub
+[submodule "3rdparty/openmp"]
+       path = 3rdparty/openmp
+       url = https://github.com/llvm-mirror/openmp
diff --git a/3rdparty/openmp b/3rdparty/openmp
new file mode 160000
index 0000000..37c7212
--- /dev/null
+++ b/3rdparty/openmp
@@ -0,0 +1 @@
+Subproject commit 37c72127e90360a020f351f18d9cccfc30e5145a
diff --git a/CMakeLists.txt b/CMakeLists.txt
index b6bb814..dd17917 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -54,10 +54,13 @@ if(EXISTS 
${CMAKE_CURRENT_SOURCE_DIR}/build/private/local_config.cmake)
   include(${CMAKE_CURRENT_SOURCE_DIR}/build/private/local_config.cmake)
 endif()
 
-set(CMAKE_MODULE_PATH 
"${PROJECT_SOURCE_DIR}/cmake/Modules;${CMAKE_MODULE_PATH}")
-
-
+if(MSVC)
+  set(SYSTEM_ARCHITECTURE x86_64)
+else()
+  EXECUTE_PROCESS( COMMAND uname -m COMMAND tr -d '\n' OUTPUT_VARIABLE 
SYSTEM_ARCHITECTURE)
+endif()
 
+set(CMAKE_MODULE_PATH 
"${PROJECT_SOURCE_DIR}/cmake/Modules;${CMAKE_MODULE_PATH}")
 
 SET(EXTRA_OPERATORS "" CACHE PATH "EXTRA OPERATORS PATH")
 
@@ -263,11 +266,13 @@ endif()
 # ---[ OpenMP
 if(USE_OPENMP)
   find_package(OpenMP REQUIRED)
-  if(EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/openmp/CMakeLists.txt)
+  # This should build on Windows, but there's some problem and I don;t have a 
Windows box, so
+  # could a Windows user please fix?
+  if(EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/3rdparty/openmp/CMakeLists.txt AND 
SYSTEM_ARCHITECTURE STREQUAL "x86_64" AND NOT MSVC)
     # Intel/llvm OpenMP: https://github.com/llvm-mirror/openmp
     set(OPENMP_STANDALONE_BUILD TRUE)
     set(LIBOMP_ENABLE_SHARED FALSE)
-    add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/openmp)
+    add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/3rdparty/openmp)
     list(REMOVE_ITEM mxnet_LINKER_LIBS iomp5)
     list(APPEND mxnet_LINKER_LIBS omp)
     set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${OpenMP_C_FLAGS}")
diff --git a/LICENSE b/LICENSE
index 01dfcf4..4173ec8 100644
--- a/LICENSE
+++ b/LICENSE
@@ -234,6 +234,7 @@
     1. Fast R-CNN  - For details, see example/rcnn/LICENSE
     2. Faster R-CNN - For details, see example/rcnn/LICENSE
     3. tree_lstm - For details, see example/gluon/tree_lstm/LICENSE
+    4. OpenMP - For details, see 3rdparty/openmp/LICENSE.txt
 
 
     ========================================================================
diff --git a/tools/license_header.py b/tools/license_header.py
index e26fd2b..29538d1 100644
--- a/tools/license_header.py
+++ b/tools/license_header.py
@@ -61,6 +61,7 @@ _WHITE_LIST = ['R-package/',
                'dmlc-core/',
                'mshadow/',
                'nnvm',
+               '3rdparty',   
                'ps-lite',
                'src/operator/mkl/',
                'src/operator/contrib/ctc_include/']

-- 
To stop receiving notification emails like this one, please contact
['"comm...@mxnet.apache.org" <comm...@mxnet.apache.org>'].

Reply via email to