Skip to content

Commit 83adbdf

Browse files
authored
[CI] Fix missing deps in dev igc installation (#13610)
All opencl tests with current dev igc installtation are failing. Investigation shows that we are missing libopencl-clang. Unfortunately dev igc deb package did not include libopencl-clang, and Ubuntu did not have the correct version either, apt has up to libopencl-clang13, while we need libopenc-clang14. So the workaround is to backup the version installed by released igc version, then install it back after installing dev igc. This also seperate the installation of dev igc to new step, so that we can always do checksum and remove force dependency option to dpkg.
1 parent 5cc0417 commit 83adbdf

File tree

4 files changed

+39
-22
lines changed

4 files changed

+39
-22
lines changed

.github/workflows/sycl-linux-precommit.yml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,9 @@ jobs:
6060
- name: Determine Arc tests
6161
id: arc_tests
6262
run: |
63-
if [ "${{ contains(needs.detect_changes.outputs.filters, 'drivers') }}" == "true" ]; then
63+
if [ "${{ contains(needs.detect_changes.outputs.filters, 'devigccfg') }}" == "true" ]; then
64+
echo 'arc_tests="(ESIMD|InvokeSimd|Matrix)/"' >> "$GITHUB_OUTPUT"
65+
elif [ "${{ contains(needs.detect_changes.outputs.filters, 'drivers') }}" == "true" ]; then
6466
echo 'arc_tests=""' >> "$GITHUB_OUTPUT"
6567
elif [ "${{ contains(needs.detect_changes.outputs.filters, 'esimd') }}" == "true" ]; then
6668
echo 'arc_tests="(ESIMD|InvokeSimd|Matrix)/"' >> "$GITHUB_OUTPUT"

devops/dependencies-igc-dev.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
{
22
"linux": {
33
"igc_dev": {
4-
"github_tag": "igc-dev-498324a",
5-
"version": "498324a",
6-
"updated_at": "2024-04-17T13:44:27Z",
7-
"url": "https://api.github.com/repos/intel/intel-graphics-compiler/actions/artifacts/1422168296/zip",
4+
"github_tag": "igc-dev-41e87ac",
5+
"version": "41e87ac",
6+
"updated_at": "2024-05-02T11:47:42Z",
7+
"url": "https://api.github.com/repos/intel/intel-graphics-compiler/actions/artifacts/1466894014/zip",
88
"root": "{DEPS_ROOT}/opencl/runtime/linux/oclgpu"
99
}
1010
}

devops/scripts/install_drivers.sh

Lines changed: 30 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -108,33 +108,47 @@ InstallIGFX () {
108108
echo "Compute Runtime version $CR_TAG"
109109
echo "CM compiler version $CM_TAG"
110110
echo "Level Zero version $L0_TAG"
111-
IS_IGC_DEV=$(CheckIGCdevTag $IGCTAG)
112-
IGNORE_CHECKSUM=false
113-
DPKG_OPTIONS=""
114-
if [ "$IS_IGC_DEV" == "Yes" ]; then
115-
echo "IGC dev git hash $IGC_DEV_VER"
116-
get_pre_release_igfx $IGC_DEV_URL $IGC_DEV_VER
117-
IGNORE_CHECKSUM=true
118-
DPKG_OPTIONS=" --force-depends-version"
119-
else
120-
echo "IGC version $IGC_TAG"
121-
get_release intel/intel-graphics-compiler $IGC_TAG \
122-
| grep ".*deb" \
123-
| wget -qi -
124-
fi
111+
echo "IGC version $IGC_TAG"
112+
# Always install released igc version first to get rid of the dependency issue
113+
# by installing the igc first, we will satisfy all the dpkg dependencies .
114+
# When we install dev igc later, it will then be treated as downgrade (because dev igc come with lowest version 1.0).
115+
# This can help us avoid using the risky force-depends-version option in dpkg command.
116+
#
117+
# Of course, this also installed the libopencl-clang so that we can copy and use later as a temporariy workaround.
118+
get_release intel/intel-graphics-compiler $IGC_TAG \
119+
| grep ".*deb" \
120+
| wget -qi -
125121
get_release intel/compute-runtime $CR_TAG \
126122
| grep -E ".*((deb)|(sum))" \
127123
| wget -qi -
128124
# Perform the checksum conditionally and then get the release
129-
( [ "$IGNORE_CHECKSUM" ] || sha256sum -c *.sum ) && \
125+
sha256sum -c *.sum && \
130126
get_release intel/cm-compiler $CM_TAG \
131127
| grep ".*deb" \
132128
| grep -v "u18" \
133129
| wget -qi -
134130
get_release oneapi-src/level-zero $L0_TAG \
135131
| grep ".*deb" \
136132
| wget -qi -
137-
dpkg -i $DPKG_OPTIONS *.deb && rm *.deb *.sum
133+
dpkg -i *.deb && rm *.deb *.sum
134+
IS_IGC_DEV=$(CheckIGCdevTag $IGCTAG)
135+
if [ "$IS_IGC_DEV" == "Yes" ]; then
136+
# Dev IGC deb package did not include libopencl-clang
137+
# opencl-clang repo does not provide release deb package either.
138+
# Backup and install it from release igc as a temporarily workaround
139+
# while we working to resolve the issue.
140+
echo "Backup libopencl-clang"
141+
cp -d /usr/local/lib/libopencl-clang.so.14* .
142+
echo "Download IGC dev git hash $IGC_DEV_VER"
143+
get_pre_release_igfx $IGC_DEV_URL $IGC_DEV_VER
144+
echo "Install IGC dev git hash $IGC_DEV_VER"
145+
dpkg -i *.deb
146+
echo "Install libopencl-clang"
147+
# Workaround only, will download deb and install with dpkg once fixed.
148+
cp -d libopencl-clang.so.14* /usr/local/lib/
149+
echo "Clean up"
150+
rm *.deb libopencl-clang.so.14*
151+
fi
138152
}
139153

140154
InstallCPURT () {

sycl/test-e2e/ESIMD/hardware_dispatch.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,8 @@
55
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
66
//
77
//===----------------------------------------------------------------------===//
8-
// RUN: %clangxx -fsycl -fsycl-targets=intel_gpu_bdw %s -o %t.out
8+
// Add "-options -vc-codegen" explicitly to workaround bug in dev igc package.
9+
// RUN: %clangxx -fsycl -fsycl-targets=intel_gpu_bdw %s -Xs "-options -vc-codegen" -o %t.out
910
// RUN: %t.out
1011
// TODO: remove XFAIL when the fix in GPU RT for Windows is updated on CI
1112
// machines

0 commit comments

Comments
 (0)