You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tvm.apache.org by jr...@apache.org on 2021/04/01 05:51:45 UTC

[tvm] branch ci-docker-staging updated: WIP

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

jroesch pushed a commit to branch ci-docker-staging
in repository https://gitbox.apache.org/repos/asf/tvm.git


The following commit(s) were added to refs/heads/ci-docker-staging by this push:
     new 9ebc663  WIP
9ebc663 is described below

commit 9ebc663f18630e24fea62b5bac27b1fe8a4896a9
Author: Jared Roesch <ro...@gmail.com>
AuthorDate: Wed Mar 31 22:51:06 2021 -0700

    WIP
---
 Jenkinsfile                           |  2 +-
 docker/install/ubuntu_install_rocm.sh |  6 +++---
 python/tvm/contrib/nvcc.py            |  2 ++
 src/target/opt/build_cuda_on.cc       | 13 +++++++++++--
 4 files changed, 17 insertions(+), 6 deletions(-)

diff --git a/Jenkinsfile b/Jenkinsfile
index 3550f93..3e59424 100644
--- a/Jenkinsfile
+++ b/Jenkinsfile
@@ -126,7 +126,7 @@ def make(docker_type, path, make_flag) {
     try {
       sh "${docker_run} ${docker_type} ./tests/scripts/task_build.sh ${path} ${make_flag}"
       // always run cpp test when build
-      sh "${docker_run} ${docker_type} ./tests/scripts/task_cpp_unittest.sh"
+      sh "${docker_run} ${docker_type} sudo ./tests/scripts/task_cpp_unittest.sh"
     } catch (hudson.AbortException ae) {
       // script exited due to user abort, directly throw instead of retry
       if (ae.getMessage().contains('script returned exit code 143')) {
diff --git a/docker/install/ubuntu_install_rocm.sh b/docker/install/ubuntu_install_rocm.sh
index 0945c58..4db731f 100755
--- a/docker/install/ubuntu_install_rocm.sh
+++ b/docker/install/ubuntu_install_rocm.sh
@@ -6,9 +6,9 @@
 # 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
@@ -21,7 +21,7 @@ set -u
 set -o pipefail
 
 # Install ROCm cross compilation toolchain.
-wget -qO - http://repo.radeon.com/rocm/apt/debian/rocm.gpg.key | sudo apt-key add -
+wget -qO - https://repo.radeon.com/rocm/rocm.gpg.key | sudo apt-key add -
 echo deb [arch=amd64] http://repo.radeon.com/rocm/apt/debian/ xenial main > /etc/apt/sources.list.d/rocm.list
 apt-get update && apt-get install -y \
     rocm-dev \
diff --git a/python/tvm/contrib/nvcc.py b/python/tvm/contrib/nvcc.py
index 99844f7..606db3e 100644
--- a/python/tvm/contrib/nvcc.py
+++ b/python/tvm/contrib/nvcc.py
@@ -95,6 +95,8 @@ def compile_cuda(code, target="ptx", arch=None, options=None, path_target=None):
         # On Windows it is not in the path by default.
         cmd += ["-ccbin", cxx_compiler_path]
 
+    print(cmd)
+
     proc = subprocess.Popen(cmd, stdout=subprocess.PIPE, stderr=subprocess.STDOUT)
 
     (out, _) = proc.communicate()
diff --git a/src/target/opt/build_cuda_on.cc b/src/target/opt/build_cuda_on.cc
index 1a0f089..7909952 100644
--- a/src/target/opt/build_cuda_on.cc
+++ b/src/target/opt/build_cuda_on.cc
@@ -86,8 +86,17 @@ std::string NVRTCCompile(const std::string& code, bool include_path = false) {
   if (e1 == cudaSuccess && e2 == cudaSuccess) {
     cc = std::to_string(major) + std::to_string(minor);
   } else {
-    LOG(WARNING) << "cannot detect compute capability from your device, "
-                 << "fall back to compute_30.";
+    LOG(WARNING) << "cannot detect the compute capability of your Nvidia device";
+
+    if (e1 != cudaSuccess) {
+      LOG(WARNING) << "due to being unable to read major version (error: " << cudaGetErrorString(e1) << ")";
+    }
+
+    if (e2 != cudaSuccess) {
+      LOG(WARNING) << "due to being unable to read minor version (error: " << cudaGetErrorString(e2) << ")";
+    }
+
+    LOG(WARNING) << "applying fall back to compute_30";
   }
 
   compile_params.push_back("-arch=compute_" + cc);