Skip to content

[CI] Enable cached checkout in main pipeline #5180

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 12 commits into from
Dec 23, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
38 changes: 27 additions & 11 deletions .github/workflows/sycl_linux_build_and_test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -109,11 +109,16 @@ jobs:
image: ${{ fromJSON(needs.configure.outputs.params).build_image }}
options: -u 1001:1001
steps:
- uses: actions/checkout@v2
# GHA requires relative paths for actions. Copy actions from container root
# to CWD.
- run: cp -r /actions .
# Cleanup will be run after all actions are completed.
- name: Register cleanup after job is finished
uses: ./actions/cleanup
- uses: ./actions/cached_checkout
with:
path: src
- name: Register cleanup after job is finished
uses: ./src/devops/actions/cleanup
cache_path: "/__w/repo_cache/"
- name: Setup Cache
uses: actions/cache@v2
if: ${{ steps.parameters.build_github_cache }}
Expand Down Expand Up @@ -213,11 +218,14 @@ jobs:
image: ${{ fromJSON(needs.configure.outputs.params).intel_drivers_image }}
options: -u 1001 --device=/dev/dri
steps:
- run: cp -r /actions .
- name: Register cleanup after job is finished
uses: ./actions/cleanup
# FIXME cached_checkout fails here, but works everywhere else
- uses: actions/checkout@v2
with:
path: llvm
- name: Register cleanup after job is finished
uses: ./llvm/devops/actions/cleanup
# TODO should this action be packed into container as well?
- uses: ./llvm/devops/actions/llvm_test_suite
name: Run LLVM Test Suite
with:
Expand All @@ -240,11 +248,13 @@ jobs:
image: ${{ fromJSON(needs.configure.outputs.params).intel_drivers_image }}
options: -u 1001 --device=/dev/dri
steps:
- run: cp -r /actions .
- name: Register cleanup after job is finished
uses: ./actions/cleanup
# FIXME cached_checkout fails here, but works everywhere else
- uses: actions/checkout@v2
with:
path: llvm
- name: Register cleanup after job is finished
uses: ./llvm/devops/actions/cleanup
- uses: ./llvm/devops/actions/llvm_test_suite
name: Run LLVM Test Suite
with:
Expand All @@ -267,11 +277,13 @@ jobs:
image: ${{ fromJSON(needs.configure.outputs.params).intel_drivers_image }}
options: -u 1001
steps:
- run: cp -r /actions .
- name: Register cleanup after job is finished
uses: ./actions/cleanup
# FIXME cached_checkout fails here, but works everywhere else
- uses: actions/checkout@v2
with:
path: llvm
- name: Register cleanup after job is finished
uses: ./llvm/devops/actions/cleanup
- uses: ./llvm/devops/actions/llvm_test_suite
name: Run LLVM Test Suite
with:
Expand All @@ -293,11 +305,15 @@ jobs:
image: ${{ fromJSON(needs.configure.outputs.params).amdgpu_image }}
options: --device=/dev/dri --device=/dev/kfd
steps:
- run: cp -r /actions .
- name: Register cleanup after job is finished
uses: ./actions/cleanup
# TODO remove this step one LLVM Test Suite action is settled and packed
# into container.
# FIXME cached_checkout fails here, but works everywhere else
- uses: actions/checkout@v2
with:
path: llvm
- name: Register cleanup after job is finished
uses: ./llvm/devops/actions/cleanup
- uses: ./llvm/devops/actions/llvm_test_suite
name: Run LLVM Test Suite
with:
Expand Down
5 changes: 4 additions & 1 deletion devops/actions/llvm_test_suite/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,12 +33,15 @@ post-if: false
runs:
using: "composite"
steps:
- run: cp -r /actions .
shell: bash
- name: Checkout LLVM Test Suite
uses: actions/checkout@v2
uses: ./actions/cached_checkout
with:
path: llvm_test_suite
repository: 'intel/llvm-test-suite'
ref: ${{ inputs.test_ref }}
cache_path: "/__w/repo_cache/"
- name: Download compiler toolchain
uses: actions/download-artifact@v2
with:
Expand Down