This repository has been archived by the owner on Nov 17, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 6.8k
Update MKLML dependency #13181
Merged
Merged
Update MKLML dependency #13181
Changes from 4 commits
Commits
Show all changes
6 commits
Select commit
Hold shift + click to select a range
954d3c7
update mkml
TaoLv 8ea44c3
refine DownloadMKLML.cmake
TaoLv 3f4bdf1
Merge remote-tracking branch 'origin/master' into update-mklml
TaoLv 96c169f
merge DownloadMKLML.cmake from #11148
TaoLv 0e53ef4
fix mkldnn release version
TaoLv a7fa18c
fix windows compilation
TaoLv File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,71 @@ | ||
# Licensed to the Apache Software Foundation (ASF) under one | ||
# or more contributor license agreements. See the NOTICE file | ||
# distributed with this work for additional information | ||
# regarding copyright ownership. The ASF licenses this file | ||
# to you under the Apache License, Version 2.0 (the | ||
# "License"); you may not use this file except in compliance | ||
# with the License. You may obtain a copy of the License at | ||
# | ||
# http://www.apache.org/licenses/LICENSE-2.0 | ||
# | ||
# Unless required by applicable law or agreed to in writing, | ||
# software distributed under the License is distributed on an | ||
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY | ||
# KIND, either express or implied. See the License for the | ||
# specific language governing permissions and limitations | ||
# under the License. | ||
|
||
# This script will download MKLML | ||
|
||
message(STATUS "Downloading MKLML...") | ||
|
||
set(MKLML_RELEASE v0.17-rc) | ||
set(MKLML_RELEASE_FILE_SUFFIX 2019.0.1.20180928) | ||
|
||
if(MSVC) | ||
set(MKL_NAME "mklml_win_${MKLML_RELEASE_FILE_SUFFIX}") | ||
|
||
file(DOWNLOAD "https://github.com/intel/mkl-dnn/releases/download/${MKLML_RELEASE}/${MKL_NAME}.zip" | ||
"${CMAKE_CURRENT_BINARY_DIR}/mklml/${MKL_NAME}.zip" | ||
EXPECTED_MD5 "443e661bdfd32dbbc99b460b43afceee" SHOW_PROGRESS) | ||
file(DOWNLOAD "https://github.com/apache/incubator-mxnet/releases/download/utils/7z.exe" | ||
"${CMAKE_CURRENT_BINARY_DIR}/mklml/7z2.exe" | ||
EXPECTED_MD5 "E1CF766CF358F368EC97662D06EA5A4C" SHOW_PROGRESS) | ||
|
||
execute_process(COMMAND "${CMAKE_CURRENT_BINARY_DIR}/mklml/7z2.exe" "-o${CMAKE_CURRENT_BINARY_DIR}/mklml/" "-y") | ||
execute_process(COMMAND "${CMAKE_CURRENT_BINARY_DIR}/mklml/7z.exe" | ||
"x" "${CMAKE_CURRENT_BINARY_DIR}/mklml/${MKL_NAME}.zip" "-o${CMAKE_CURRENT_BINARY_DIR}/mklml/" "-y") | ||
|
||
set(MKLROOT "${CMAKE_CURRENT_BINARY_DIR}/mklml/${MKL_NAME}") | ||
|
||
message(STATUS "Setting MKLROOT path to ${MKLROOT}") | ||
|
||
elseif(APPLE) | ||
set(MKL_NAME "mklml_mac_${MKLML_RELEASE_FILE_SUFFIX}") | ||
|
||
file(DOWNLOAD "https://github.com/intel/mkl-dnn/releases/download/${MKLML_RELEASE}/${MKL_NAME}.tgz" | ||
"${CMAKE_CURRENT_BINARY_DIR}/mklml/${MKL_NAME}.tgz" | ||
EXPECTED_MD5 "95f887af332205b1d15b392260003952" SHOW_PROGRESS) | ||
execute_process(COMMAND "tar" "-xzf" "${CMAKE_CURRENT_BINARY_DIR}/mklml/${MKL_NAME}.tgz" | ||
"-C" "${CMAKE_CURRENT_BINARY_DIR}/mklml/") | ||
|
||
set(MKLROOT "${CMAKE_CURRENT_BINARY_DIR}/mklml/${MKL_NAME}") | ||
|
||
message(STATUS "Setting MKLROOT path to ${MKLROOT}") | ||
|
||
elseif(UNIX) | ||
set(MKL_NAME "mklml_lnx_${MKLML_RELEASE_FILE_SUFFIX}") | ||
|
||
file(DOWNLOAD "https://github.com/intel/mkl-dnn/releases/download/${MKLML_RELEASE}/${MKL_NAME}.tgz" | ||
"${CMAKE_CURRENT_BINARY_DIR}/mklml/${MKL_NAME}.tgz" | ||
EXPECTED_MD5 "a63abf155361322b9c03f8fc50f4f317" SHOW_PROGRESS) | ||
execute_process(COMMAND "tar" "-xzf" "${CMAKE_CURRENT_BINARY_DIR}/mklml/${MKL_NAME}.tgz" | ||
"-C" "${CMAKE_CURRENT_BINARY_DIR}/mklml/") | ||
|
||
set(MKLROOT "${CMAKE_CURRENT_BINARY_DIR}/mklml/${MKL_NAME}") | ||
|
||
message(STATUS "Setting MKLROOT path to ${MKLROOT}") | ||
|
||
else() | ||
message(FATAL_ERROR "Wrong platform") | ||
endif() |
This file was deleted.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
shouldn't this be the mkldnn release version?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@szha for some reason, MKLML is distributed on the MKLDNN github releases page. The MKLDNN tag comes with corresponding MKLDNN binary release distribution. So, this version is for both MKLML and MKLDNN.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Right. Will change it.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
MKLML is a dependency of MKLDNN. v0.17 refers to the MKLDNN version.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes. v0.17 is the release version of MKL-DNN. MKLML version is 2019.0.1 in this case, which is declared in
mklml/include/mkl_version.h
. Different releases of MKL-DNN may have the same package of MKLML (but with different download URL).