From 3840eebfbc228226af2d2660d54176b23dc0cfd5 Mon Sep 17 00:00:00 2001 From: Weiming Zhao Date: Wed, 3 Mar 2021 17:28:53 +0000 Subject: [PATCH] [CI] Upload build artifacts --- .github/actions/build/build_in_docker.sh | 14 ++++++-------- .github/workflows/ipu_sim.yaml | 7 +++++++ .github/workflows/main.yaml | 8 +++++++- 3 files changed, 20 insertions(+), 9 deletions(-) diff --git a/.github/actions/build/build_in_docker.sh b/.github/actions/build/build_in_docker.sh index 3e2c7f6d4..405651b42 100755 --- a/.github/actions/build/build_in_docker.sh +++ b/.github/actions/build/build_in_docker.sh @@ -50,15 +50,13 @@ if [ -z "$DOCKER_ID" ]; then --disabled-password --home /home/$USER $USER" fi +extra_cmd="true" # dummy command + if [[ "$VARIANT" =~ graphcore ]]; then extra_cmd="source /opt/poplar_sdk-ubuntu_18_04-1.4.0+365-665f971c8f/poplar-ubuntu_18_04-1.4.0+71819-c5c0c8ebab/enable.sh \ && source /opt/poplar_sdk-ubuntu_18_04-1.4.0+365-665f971c8f/popart-ubuntu_18_04-1.4.0+5352-e86081acc9/enable.sh" - - docker exec --user $USER $CONTAINER_NAME bash -c \ - "$extra_cmd && cd /host && rm -fr build && mkdir -p build && cd build && \ - cmake -G Ninja $cmake_flags ../halo && ninja && $check_cmds" -else - docker exec --user $USER $CONTAINER_NAME bash -c \ - "cd /host && rm -fr build && mkdir -p build && cd build && \ - cmake -G Ninja $cmake_flags ../halo && ninja && $check_cmds && ninja package" fi + +docker exec --user $USER $CONTAINER_NAME bash -c \ + "$extra_cmd && cd /host && rm -fr build && mkdir -p build && cd build && \ + cmake -G Ninja $cmake_flags ../halo && ninja && $check_cmds && ninja package" diff --git a/.github/workflows/ipu_sim.yaml b/.github/workflows/ipu_sim.yaml index 0c4a61b12..46f18f7b1 100644 --- a/.github/workflows/ipu_sim.yaml +++ b/.github/workflows/ipu_sim.yaml @@ -22,3 +22,10 @@ jobs: uses: ./halo/.github/actions/build with: docker_image_variant: graphcore1.4.0-x86_64 + + - name: Upload + uses: actions/upload-artifact@v2 + with: + name: artifact + path: ${{runner.workspace}}/heterogeneity-aware-lowering-and-optimization/build/*.bz2 + if-no-files-found: error diff --git a/.github/workflows/main.yaml b/.github/workflows/main.yaml index f551f5445..bcef908d5 100644 --- a/.github/workflows/main.yaml +++ b/.github/workflows/main.yaml @@ -7,7 +7,7 @@ on: pull_request: branches-ignore: - "web" - + release: jobs: check: runs-on: ubuntu-latest @@ -44,3 +44,9 @@ jobs: uses: ./halo/.github/actions/build with: docker_image_variant: cuda10.0-cudnn7 + - name: Upload + uses: actions/upload-artifact@v2 + with: + name: artifact + path: ${{runner.workspace}}/heterogeneity-aware-lowering-and-optimization/build/*.bz2 + if-no-files-found: error