Skip to content

Commit 548b840

Browse files
Merge branch 'main' into rajprinc/unit-test-new-api-changes
2 parents 8f9784e + 7bf5a24 commit 548b840

File tree

158 files changed

+7568
-796
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

158 files changed

+7568
-796
lines changed

.github/actions/install-intel-graphics/action.yml

Lines changed: 52 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ inputs:
55
description: "Install for PVC or BMG gpu"
66
type: string
77
IGC:
8-
description: "Use ROLLING or STAGING release"
8+
description: "Use ROLLING, STAGING, or LTS release"
99
type: string
1010

1111
runs:
@@ -19,9 +19,7 @@ runs:
1919
which sudo || alias sudo=""
2020
if [[ "${{ inputs.GPU }}" == "BMG" ]] || [[ "${{ inputs.GPU }}" == "PVC" ]]; then
2121
#purge existing intel graphics packages
22-
sudo apt-get purge -y 'libigc*' 'intel-igc*' 'libigdgmm*' 'libigdfcl*' \
23-
'libze-intel-gpu*' 'libze1' 'libze-dev' 'intel-opencl-icd' \
24-
'intel-metrics-discovery' 'intel-gsc' 'intel-ocloc' || true
22+
dpkg -l | grep -E 'libigc|intel-igc|libigdgmm|libigdfcl|libze-intel-gpu|libze1|libze-dev|intel-opencl-icd|intel-metrics-discovery|intel-gsc|intel-ocloc' | awk '{print $2}' | xargs -r sudo apt-get purge -y || true
2523
sudo rm -f /etc/apt/sources.list.d/kobuk-team-ubuntu-intel-graphics-*
2624
2725
sudo add-apt-repository ppa:kobuk-team/intel-graphics
@@ -40,9 +38,7 @@ runs:
4038
which sudo || alias sudo=""
4139
if [[ "${{ inputs.GPU }}" == "BMG" ]] || [[ "${{ inputs.GPU }}" == "PVC" ]]; then
4240
#purge existing intel graphics packages
43-
sudo apt-get purge -y 'libigc*' 'intel-igc*' 'libigdgmm*' 'libigdfcl*' \
44-
'libze-intel-gpu*' 'libze1' 'libze-dev' 'intel-opencl-icd' \
45-
'intel-metrics-discovery' 'intel-gsc' 'intel-ocloc' || true
41+
dpkg -l | grep -E 'libigc|intel-igc|libigdgmm|libigdfcl|libze-intel-gpu|libze1|libze-dev|intel-opencl-icd|intel-metrics-discovery|intel-gsc|intel-ocloc' | awk '{print $2}' | xargs -r sudo apt-get purge -y || true
4642
sudo rm -f /etc/apt/sources.list.d/kobuk-team-ubuntu-intel-graphics-*
4743
4844
sudo add-apt-repository ppa:kobuk-team/intel-graphics-staging
@@ -53,3 +49,52 @@ runs:
5349
else
5450
exit 1
5551
fi
52+
- name: Install Intel graphics drivers
53+
if: inputs.IGC == 'LTS'
54+
shell: bash
55+
run: |
56+
shopt -s expand_aliases
57+
which sudo || alias sudo=""
58+
if [[ "${{ inputs.GPU }}" == "PVC" ]]; then
59+
# Purge existing intel graphics packages
60+
sudo apt-get purge -y 'libigc*' 'intel-igc*' 'libigdgmm*' 'libigdfcl*' \
61+
'libze-intel-gpu*' 'libze1' 'libze-dev' 'intel-opencl-icd' \
62+
'intel-metrics-discovery' 'intel-gsc' 'intel-ocloc' || true
63+
sudo rm -f /etc/apt/sources.list.d/kobuk-team-ubuntu-intel-graphics-*
64+
sudo rm -f /etc/apt/sources.list.d/intel-gpu-*.list
65+
66+
# Install LTS drivers for PVC
67+
. /etc/os-release
68+
if [[ ! " jammy noble " =~ " ${VERSION_CODENAME} " ]]; then
69+
echo "Ubuntu version ${VERSION_CODENAME} not supported"
70+
exit 1
71+
fi
72+
wget -qO - https://repositories.intel.com/gpu/intel-graphics.key | \
73+
sudo gpg --yes --dearmor --output /usr/share/keyrings/intel-graphics.gpg
74+
echo "deb [arch=amd64 signed-by=/usr/share/keyrings/intel-graphics.gpg] https://repositories.intel.com/gpu/ubuntu ${VERSION_CODENAME}/lts/2523 unified" | \
75+
sudo tee /etc/apt/sources.list.d/intel-gpu-${VERSION_CODENAME}.list
76+
sudo apt update
77+
sudo apt install -y \
78+
intel-opencl-icd libze-intel-gpu1 libze1 \
79+
intel-media-va-driver-non-free libmfx-gen1 libvpl2 \
80+
libegl-mesa0 libegl1-mesa-dev libgbm1 libgl1-mesa-dev libgl1-mesa-dri \
81+
libglapi-mesa libgles2-mesa-dev libglx-mesa0 libigdgmm12 libxatracker2 mesa-va-drivers \
82+
mesa-vdpau-drivers mesa-vulkan-drivers va-driver-all vainfo hwinfo clinfo
83+
84+
85+
rm -rf igc
86+
mkdir igc
87+
cd igc
88+
echo "Fetching latest IGC release..."
89+
IGC_CORE_URL=$(curl -s https://api.github.com/repos/intel/intel-graphics-compiler/releases/latest | grep "browser_download_url.*intel-igc-core-2.*amd64.deb\"" | head -1 | cut -d '"' -f 4)
90+
IGC_OPENCL_URL=$(curl -s https://api.github.com/repos/intel/intel-graphics-compiler/releases/latest | grep "browser_download_url.*intel-igc-opencl-2.*amd64.deb\"" | grep -v "devel" | head -1 | cut -d '"' -f 4)
91+
echo "Downloading IGC packages..."
92+
wget "${IGC_CORE_URL}"
93+
wget "${IGC_OPENCL_URL}"
94+
95+
# Install all downloaded packages
96+
sudo dpkg -i *.deb
97+
98+
else
99+
exit 1
100+
fi

.github/workflows/codeql.yml

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -79,10 +79,3 @@ jobs:
7979
uses: github/codeql-action/analyze@2e230e8fe0ad3a14a340ad0815ddb96d599d2aff # v3.25.8
8080
with:
8181
category: "/language:${{matrix.language}}"
82-
83-
- name: Upload Sarif Artifact
84-
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2
85-
with:
86-
name: codeql-results-${{ matrix.language }}
87-
path: ./results/${{ matrix.language }}.sarif
88-
retention-days: 7

.github/workflows/intel_test.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@ jobs:
2525
if: github.event_name == 'pull_request' || github.event_name == 'merge_group'
2626
uses: ./.github/workflows/intel_test_reusable.yml
2727
with:
28+
gpu: '["PVC", "BMG"]'
2829
compiler: '["RELEASE"]'
2930
intel_graphics: '["ROLLING"]'
3031
DPCPP_VERSION: ${{ inputs.DPCPP_VERSION }}
@@ -35,5 +36,6 @@ jobs:
3536
uses: ./.github/workflows/intel_test_reusable.yml
3637
with:
3738
compiler: '["RELEASE", "NIGHTLY"]'
39+
gpu: '["PVC", "BMG"]'
3840
intel_graphics: '["ROLLING", "STAGING"]'
3941
DPCPP_VERSION: ${{ inputs.DPCPP_VERSION }}

.github/workflows/intel_test_gpp_host.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@ jobs:
2727
with:
2828
compiler: '["RELEASE"]'
2929
intel_graphics: '["ROLLING"]'
30+
gpu: '["PVC", "BMG"]'
3031
DPCPP_VERSION: ${{ inputs.DPCPP_VERSION }}
3132

3233
# Full testing for pushes - 2 configurations
@@ -36,4 +37,5 @@ jobs:
3637
with:
3738
compiler: '["RELEASE", "NIGHTLY"]'
3839
intel_graphics: '["ROLLING"]'
40+
gpu: '["PVC", "BMG"]'
3941
DPCPP_VERSION: ${{ inputs.DPCPP_VERSION }}

.github/workflows/intel_test_gpp_host_reusable.yml

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,11 @@ on:
1010
intel_graphics:
1111
description: 'Intel graphics driver version'
1212
required: true
13-
type: string
13+
type: string
14+
gpu:
15+
description: 'GPU type (PVC, BMG)'
16+
required: true
17+
type: string
1418
DPCPP_VERSION:
1519
description: 'DPC++ version'
1620
required: false
@@ -26,7 +30,7 @@ jobs:
2630
matrix:
2731
compiler: ${{ fromJSON(inputs.compiler) }}
2832
intel_graphics: ${{ fromJSON(inputs.intel_graphics) }}
29-
gpu: [BMG, PVC]
33+
gpu: ${{ fromJSON(inputs.gpu) }}
3034
include:
3135
- gpu: BMG
3236
sycl_target: intel_gpu_bmg_g21

.github/workflows/intel_test_reusable.yml

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,11 @@ on:
1010
intel_graphics:
1111
description: 'Intel graphics driver version'
1212
required: true
13-
type: string
13+
type: string
14+
gpu:
15+
description: 'GPU type (PVC, BMG)'
16+
required: true
17+
type: string
1418
DPCPP_VERSION:
1519
description: 'DPC++ version'
1620
required: false
@@ -26,7 +30,7 @@ jobs:
2630
matrix:
2731
compiler: ${{ fromJSON(inputs.compiler) }}
2832
intel_graphics: ${{ fromJSON(inputs.intel_graphics) }}
29-
gpu: [BMG, PVC]
33+
gpu: ${{ fromJSON(inputs.gpu) }}
3034
include:
3135
- gpu: BMG
3236
sycl_target: intel_gpu_bmg_g21

.github/workflows/pvc_nightly.yml

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
name: "PVC nightly test"
2+
3+
on:
4+
schedule:
5+
- cron: '0 19 * * *'
6+
workflow_dispatch:
7+
inputs:
8+
DPCPP_VERSION:
9+
description: "DPCPP version to use"
10+
type: string
11+
12+
permissions: {}
13+
14+
concurrency:
15+
group: ${{ github.workflow }}-${{ github.ref }}
16+
cancel-in-progress: true
17+
18+
jobs:
19+
sycl-test:
20+
uses: ./.github/workflows/intel_test_reusable.yml
21+
with:
22+
compiler: '["RELEASE", "NIGHTLY"]'
23+
intel_graphics: '["LTS"]'
24+
DPCPP_VERSION: ${{ inputs.DPCPP_VERSION }}
25+
gpu: '["PVC"]'
26+
27+
gpp-host-test:
28+
needs: sycl-test
29+
uses: ./.github/workflows/intel_test_gpp.yml
30+
with:
31+
compiler: '["RELEASE"]'
32+
intel_graphics: '["LTS"]'
33+
DPCPP_VERSION: ${{ inputs.DPCPP_VERSION }}
34+
gpu: '["PVC"]'
35+
36+
Lines changed: 115 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,115 @@
1+
name: "SYCL Python EVT Test"
2+
3+
on:
4+
push:
5+
branches: [ "main" ]
6+
pull_request:
7+
branches: [ "main" ]
8+
merge_group:
9+
branches: [ "main" ]
10+
workflow_dispatch:
11+
12+
permissions: {}
13+
14+
concurrency:
15+
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
16+
cancel-in-progress: true
17+
18+
jobs:
19+
run-evt-tests:
20+
name: Run Python EVT tests on Intel BMG
21+
runs-on: bmg
22+
timeout-minutes: 90
23+
24+
steps:
25+
- name: Checkout repository
26+
uses: actions/checkout@a5ac7e51b41094c92402da3b24376905380afc29 # v4.1.6
27+
28+
- name: Install Python venv package
29+
shell: bash
30+
run: |
31+
sudo apt-get install -y python3.13-venv
32+
33+
- name: Install Intel graphics drivers
34+
uses: ./.github/actions/install-intel-graphics
35+
with:
36+
GPU: 'BMG'
37+
IGC: 'ROLLING'
38+
39+
- name: Install DPC++
40+
id: install_dpcpp
41+
uses: ./.github/actions/install-dpcpp
42+
with:
43+
DPCPP_RELEASE: RELEASE
44+
#DPCPP_VERSION: ${{ inputs.DPCPP_VERSION }}
45+
DPCPP_PATH: ~/dpcpp
46+
47+
- name: Setup virtual environment
48+
shell: bash
49+
run: |
50+
python3 -m venv ~/.venv
51+
source ~/.venv/bin/activate
52+
. setvars.sh
53+
# Persist environment variables to following steps
54+
env >> $GITHUB_ENV
55+
sycl-ls
56+
57+
- name: Install DPCTL
58+
id: install_dpctl
59+
uses: ./.github/actions/install-dpctl
60+
with:
61+
DPCTL_URL: https://github.com/IntelPython/dpctl.git
62+
DPCTL_BRANCH: master
63+
DPCTL_PATH: ~/dpctl
64+
VENV_PATH: ~/.venv
65+
66+
- name: Install Torch XPU
67+
shell: bash
68+
run: |
69+
source ~/.venv/bin/activate
70+
pip install torch torchvision torchaudio --index-url https://download.pytorch.org/whl/test/xpu
71+
pip uninstall --yes intel-sycl-rt intel-cmplr-lib-ur umf
72+
73+
- name: Install CUTLASS Python Package
74+
shell: bash
75+
run: |
76+
source ~/.venv/bin/activate
77+
pip install -e .
78+
export CUTLASS_USE_SYCL=1
79+
export ONEAPI_DEVICE_SELECTOR=level_zero:gpu
80+
81+
- name: Run Python EVT Tests (Xe-compatible)
82+
shell: bash
83+
run: |
84+
source ~/.venv/bin/activate
85+
export CUTLASS_USE_SYCL=1
86+
export ONEAPI_DEVICE_SELECTOR=level_zero:gpu
87+
python test/python/cutlass/evt/run_xe_evt_tests.py -j xe_evt_ci
88+
89+
- name: Cleanup DPC++
90+
if: always()
91+
shell: bash
92+
run: |
93+
echo "Cleaning up DPC++ installation..."
94+
echo "Removing OneAPI packages..."
95+
sudo apt remove -y intel-oneapi-runtime-libs intel-oneapi-compiler-dpcpp-cpp || true
96+
sudo rm -f /etc/apt/sources.list.d/oneAPI.list
97+
sudo rm -f /usr/share/keyrings/oneapi-archive-keyring.gpg
98+
# Clean up environment files
99+
rm -f setvars.sh
100+
# Clean up build artifacts
101+
rm -rf build/ || true
102+
echo "DPC++ cleanup completed"
103+
104+
- name: Cleanup DPCTL
105+
if: always()
106+
shell: bash
107+
run: |
108+
echo "Cleaning up DPCTL installation..."
109+
DPCTL_PATH="${{ inputs.DPCTL_PATH || '~/dpctl' }}"
110+
DPCTL_PATH=$(eval echo $DPCTL_PATH) # Expand ~ to home directory
111+
if [ -d "$DPCTL_PATH" ]; then
112+
echo "Removing DPCTL directory: $DPCTL_PATH"
113+
sudo rm -rf "$DPCTL_PATH"
114+
fi
115+
echo "DPCTL cleanup completed"

0 commit comments

Comments
 (0)