From 6d9dd7f938b729ab53f8c5c86359ca35afca7237 Mon Sep 17 00:00:00 2001 From: Andrew Reusch Date: Mon, 8 Feb 2021 10:56:51 -0800 Subject: [PATCH] Jenkinsfile changes for #7333. (#7388) --- Jenkinsfile | 36 ++++++++++++++++++++++++---------- tests/scripts/task_ci_setup.sh | 33 +++++++++++++++++++++++++++++++ 2 files changed, 59 insertions(+), 10 deletions(-) create mode 100755 tests/scripts/task_ci_setup.sh diff --git a/Jenkinsfile b/Jenkinsfile index c9b9e35883b2..49e996adfc5b 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -181,7 +181,7 @@ stage('Build') { make(ci_cpu, 'build', '-j2') pack_lib('cpu', tvm_multilib) timeout(time: max_time, unit: 'MINUTES') { - sh "${docker_run} ${ci_cpu} ./tests/scripts/task_ci_python_setup.sh" + sh "${docker_run} ${ci_cpu} ./tests/scripts/task_ci_setup.sh" sh "${docker_run} ${ci_cpu} ./tests/scripts/task_python_unittest.sh" sh "${docker_run} ${ci_cpu} ./tests/scripts/task_python_integration.sh" sh "${docker_run} ${ci_cpu} ./tests/scripts/task_python_vta_fsim.sh" @@ -199,7 +199,7 @@ stage('Build') { sh "${docker_run} ${ci_wasm} ./tests/scripts/task_config_build_wasm.sh" make(ci_wasm, 'build', '-j2') timeout(time: max_time, unit: 'MINUTES') { - sh "${docker_run} ${ci_wasm} ./tests/scripts/task_ci_python_setup.sh" + sh "${docker_run} ${ci_wasm} ./tests/scripts/task_ci_setup.sh" sh "${docker_run} ${ci_wasm} ./tests/scripts/task_web_wasm.sh" } } @@ -232,7 +232,7 @@ stage('Build') { sh "${docker_run} ${ci_qemu} ./tests/scripts/task_config_build_qemu.sh" make(ci_qemu, 'build', '-j2') timeout(time: max_time, unit: 'MINUTES') { - sh "${docker_run} ${ci_qemu} ./tests/scripts/task_ci_python_setup.sh" + sh "${docker_run} ${ci_qemu} ./tests/scripts/task_ci_setup.sh" sh "${docker_run} ${ci_qemu} ./tests/scripts/task_python_microtvm.sh" } } @@ -247,7 +247,7 @@ stage('Unit Test') { init_git() unpack_lib('gpu', tvm_multilib) timeout(time: max_time, unit: 'MINUTES') { - sh "${docker_run} ${ci_gpu} ./tests/scripts/task_ci_python_setup.sh" + sh "${docker_run} ${ci_gpu} ./tests/scripts/task_ci_setup.sh" sh "${docker_run} ${ci_gpu} ./tests/scripts/task_sphinx_precheck.sh" sh "${docker_run} ${ci_gpu} ./tests/scripts/task_python_unittest_gpuonly.sh" sh "${docker_run} ${ci_gpu} ./tests/scripts/task_python_integration_gpuonly.sh" @@ -261,7 +261,7 @@ stage('Unit Test') { init_git() unpack_lib('i386', tvm_multilib) timeout(time: max_time, unit: 'MINUTES') { - sh "${docker_run} ${ci_i386} ./tests/scripts/task_ci_python_setup.sh" + sh "${docker_run} ${ci_i386} ./tests/scripts/task_ci_setup.sh" sh "${docker_run} ${ci_i386} ./tests/scripts/task_python_unittest.sh" sh "${docker_run} ${ci_i386} ./tests/scripts/task_python_integration.sh" sh "${docker_run} ${ci_i386} ./tests/scripts/task_python_vta_fsim.sh" @@ -275,7 +275,7 @@ stage('Unit Test') { // init_git() // unpack_lib('arm', tvm_multilib) // timeout(time: max_time, unit: 'MINUTES') { - // sh "${docker_run} ${ci_arm} ./tests/scripts/task_ci_python_setup.sh" + // sh "${docker_run} ${ci_arm} ./tests/scripts/task_ci_setup.sh" // sh "${docker_run} ${ci_arm} ./tests/scripts/task_python_unittest.sh" // // sh "${docker_run} ${ci_arm} ./tests/scripts/task_python_integration.sh" // } @@ -288,7 +288,7 @@ stage('Unit Test') { init_git() unpack_lib('gpu', tvm_multilib) timeout(time: max_time, unit: 'MINUTES') { - sh "${docker_run} ${ci_gpu} ./tests/scripts/task_ci_python_setup.sh" + sh "${docker_run} ${ci_gpu} ./tests/scripts/task_ci_setup.sh" sh "${docker_run} ${ci_gpu} ./tests/scripts/task_java_unittest.sh" } } @@ -303,7 +303,7 @@ stage('Integration Test') { init_git() unpack_lib('gpu', tvm_multilib) timeout(time: max_time, unit: 'MINUTES') { - sh "${docker_run} ${ci_gpu} ./tests/scripts/task_ci_python_setup.sh" + sh "${docker_run} ${ci_gpu} ./tests/scripts/task_ci_setup.sh" sh "${docker_run} ${ci_gpu} ./tests/scripts/task_python_topi.sh" } } @@ -315,7 +315,7 @@ stage('Integration Test') { init_git() unpack_lib('gpu', tvm_multilib) timeout(time: max_time, unit: 'MINUTES') { - sh "${docker_run} ${ci_gpu} ./tests/scripts/task_ci_python_setup.sh" + sh "${docker_run} ${ci_gpu} ./tests/scripts/task_ci_setup.sh" sh "${docker_run} ${ci_gpu} ./tests/scripts/task_python_frontend.sh" } } @@ -327,11 +327,27 @@ stage('Integration Test') { init_git() unpack_lib('cpu', tvm_multilib) timeout(time: max_time, unit: 'MINUTES') { - sh "${docker_run} ${ci_cpu} ./tests/scripts/task_ci_python_setup.sh" + sh "${docker_run} ${ci_cpu} ./tests/scripts/task_ci_setup.sh" sh "${docker_run} ${ci_cpu} ./tests/scripts/task_python_frontend_cpu.sh" } } } +<<<<<<< HEAD +======= + }, + 'docs: GPU': { + node('TensorCore') { + ws(per_exec_ws("tvm/docs-python-gpu")) { + init_git() + unpack_lib('gpu', tvm_multilib) + timeout(time: max_time, unit: 'MINUTES') { + sh "${docker_run} ${ci_gpu} ./tests/scripts/task_ci_setup.sh" + sh "${docker_run} ${ci_gpu} ./tests/scripts/task_python_docs.sh" + } + pack_lib('mydocs', 'docs.tgz') + } + } +>>>>>>> 5103bb6a6... Jenkinsfile changes for #7333. (#7388) } // TODO: Fix the doc // 'docs: GPU': { diff --git a/tests/scripts/task_ci_setup.sh b/tests/scripts/task_ci_setup.sh new file mode 100755 index 000000000000..f48ed49a2266 --- /dev/null +++ b/tests/scripts/task_ci_setup.sh @@ -0,0 +1,33 @@ +#!/bin/bash +# 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. + +set -e +set -u +set -o pipefail + +# Script to setup additional python env. +# +# Use the following command to install the +# package to /workspace/.local, these additional +# packages will have precedence over the system packages. +# +# command: python3 -m pip install --user == +# +echo "Addtiional setup in" ${CI_IMAGE_NAME} + +python3 -m pip install --user tlcpack-sphinx-addon==0.1.4 synr==0.2.1