-
Notifications
You must be signed in to change notification settings - Fork 30
Add a workflow to install nightly intel/llvm + drivers #621
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
Conversation
bcf6ddc
to
7e043bb
Compare
e1740f3
to
8870ef4
Compare
export NIGHTLY_TAG=$(python3 -c "import sys, urllib.parse as ul; print (ul.quote_plus(sys.argv[1]))" $(git tag | sort -V | tail -1)) | ||
cd .. | ||
export DOWNLOAD_URL_PREFIX=https://github.com/intel/llvm/releases/download | ||
wget ${DOWNLOAD_URL_PREFIX}/${NIGHTLY_TAG}/dpcpp-compiler.tar.gz |
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.
We can cache these downloaded copies to speed up the workflow.
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.
This would be great. I just need to know where to look for an example. GTest installation was being cached, so I will look there.
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.
I see couple of issues here: Where are you checking if the cache is hit? I do not think caching the sycl-bundle
repo based on all files in it is going to work. We need to ascertain if the cached folder is the one we want to use.
I suggest the following:
a) Create a conf file inside sycl-bundle
that stores the SHA of the nightly that was used by the workflow previously.
b) Hash the sycl-bundle
folder as before to ensure we have all the needed files.
c) Use the following git command (I found using internet search) to get the SHA of the latest nightly:
git -c 'versionsort.suffix=-' ls-remote --tags --sort='v:refname' git@github.com:intel/llvm.git| tail --lines=1 | awk '{print $1}'
Then check if a cached entry exists
- name: Download nightly and components
if: steps.cache-sycl-bundle.outputs.cache-hit != 'true'
Also check if the SHA matches. (I do not know how to do that)
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.
You do not need a conf file. As we are storing the cloned repo we might as well run git tag | sort -V | tail -1
and compare the SHA with what the command I pasted returns.
8ed7f1c
to
aa51900
Compare
Build dpctl with that Use OCL_ICD_FILENAMES to inform plugin of CPU driver location
aa51900
to
37d97ab
Compare
Save the nightly tag into bundle_id.txt and use its content to build the cache
06937d5
to
696ab05
Compare
cd sycl_bundle | ||
export LATEST_LLVM_TAG=$(git -c 'versionsort.suffix=-' ls-remote --tags --sort='v:refname' https://github.com/intel/llvm.git | tail --lines=1) | ||
export LATEST_LLVM_TAG_SHA=$(echo ${LATEST_LLVM_TAG} | awk '{print $1}') | ||
export NIGHTLY_TAG=$(python3 -c "import sys, urllib.parse as ul; print (ul.quote_plus(sys.argv[1]))" $(echo ${LATEST_LLVM_TAG} | awk '{gsub(/^refs\/tags\//, "", $2)} {print $2}')) |
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.
You also need to check if the NIGHLY_TAG
matches with the cached bundle_id
.
4a88d6e
to
8346a0d
Compare
Build dpctl with Open Source DPC++ toolchain.
LD_LIBRARY_PATH
andPATH
,CPATH
OCL_ICD_FILENAMES
so that SYCL OpenCL plug-in knows what library to loaddpctl
and runpytest
.