Skip to content
Merged
4 changes: 2 additions & 2 deletions .github/workflows/sycl-linux-precommit.yml
Original file line number Diff line number Diff line change
Expand Up @@ -143,15 +143,15 @@ jobs:
image_options: -u 1001 --device=/dev/dri -v /dev/dri/by-path:/dev/dri/by-path --privileged --cap-add SYS_ADMIN
target_devices: level_zero:gpu;opencl:gpu
reset_intel_gpu: true
extra_lit_opts: --param matrix-xmx8=True --param gpu-intel-dg2=True
extra_lit_opts: --param matrix-xmx8=True
env: '{"LIT_FILTER":${{ needs.determine_arc_tests.outputs.arc_tests }} }'
- name: E2E tests with dev igc on Intel Arc A-Series Graphics
runner: '["Linux", "arc"]'
image: ghcr.io/intel/llvm/ubuntu2404_intel_drivers:devigc
image_options: -u 1001 --device=/dev/dri -v /dev/dri/by-path:/dev/dri/by-path --privileged --cap-add SYS_ADMIN
target_devices: level_zero:gpu;opencl:gpu
reset_intel_gpu: true
extra_lit_opts: --param matrix-xmx8=True --param gpu-intel-dg2=True
extra_lit_opts: --param matrix-xmx8=True
env: '{"LIT_FILTER":${{ needs.determine_arc_tests.outputs.arc_tests }} }'
use_igc_dev: true
- name: E2E tests on Intel Ponte Vecchio GPU
Expand Down
3 changes: 0 additions & 3 deletions .github/workflows/sycl-nightly.yml
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,6 @@ jobs:
target_devices: level_zero:gpu
reset_intel_gpu: true
tests_selector: e2e
extra_lit_opts: --param gpu-intel-gen12=True

- name: Intel OCL GPU
runner: '["Linux", "gen12"]'
Expand All @@ -67,7 +66,6 @@ jobs:
target_devices: opencl:gpu
reset_intel_gpu: true
tests_selector: e2e
extra_lit_opts: --param gpu-intel-gen12=True

- name: OCL CPU (AMD)
runner: '["Linux", "amdgpu"]'
Expand Down Expand Up @@ -126,7 +124,6 @@ jobs:
name: Intel GEN12 Graphics with Level Zero
runner: '["Windows","gen12"]'
sycl_toolchain_archive: ${{ needs.build-win.outputs.artifact_archive_name }}
extra_lit_opts: --param gpu-intel-gen12=True

cuda-aws-start:
needs: [ubuntu2204_build]
Expand Down
6 changes: 2 additions & 4 deletions .github/workflows/sycl-post-commit.yml
Original file line number Diff line number Diff line change
Expand Up @@ -47,12 +47,11 @@ jobs:
include:
- name: Intel GEN12 Graphics with Level Zero
runner: '["Linux", "gen12"]'
extra_lit_opts: --param gpu-intel-gen12=True
target_devices: level_zero:gpu;opencl:fpga
reset_intel_gpu: true
- name: Intel Arc A-Series Graphics with Level Zero
runner: '["Linux", "arc"]'
extra_lit_opts: --param matrix-xmx8=True --param gpu-intel-dg2=True
extra_lit_opts: --param matrix-xmx8=True
reset_intel_gpu: true
- name: AMD/HIP
runner: '["Linux", "amdgpu"]'
Expand All @@ -69,7 +68,7 @@ jobs:
- name: Perf tests on Intel GEN12 Graphics system
runner: '["Linux", "gen12"]'
env: '{"LIT_FILTER":"PerformanceTests/"}'
extra_lit_opts: -a -j 1 --param enable-perf-tests=True --param gpu-intel-gen12=True
extra_lit_opts: -a -j 1 --param enable-perf-tests=True
target_devices: all
reset_intel_gpu: true
- name: Perf tests on Intel Arc A-Series Graphics system
Expand Down Expand Up @@ -120,7 +119,6 @@ jobs:
name: Intel GEN12 Graphics with Level Zero
runner: '["Windows","gen12"]'
sycl_toolchain_archive: ${{ needs.build-win.outputs.artifact_archive_name }}
extra_lit_opts: --param gpu-intel-gen12=True
compiler: icx

macos_default:
Expand Down
1 change: 0 additions & 1 deletion .github/workflows/sycl-windows-precommit.yml
Original file line number Diff line number Diff line change
Expand Up @@ -55,4 +55,3 @@ jobs:
name: Intel GEN12 Graphics with Level Zero
runner: '["Windows","gen12"]'
sycl_toolchain_archive: ${{ needs.build.outputs.artifact_archive_name }}
extra_lit_opts: --param gpu-intel-gen12=True
14 changes: 6 additions & 8 deletions sycl/test-e2e/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -239,6 +239,12 @@ environment:
* **arch-\<name\>** - [SYCL architecture](https://github.com/intel/llvm/blob/sycl/sycl/doc/extensions/experimental/sycl_ext_oneapi_device_architecture.asciidoc)
of a device (e.g. `arch-intel_gpu_pvc`, the name matches what you can pass
into `-fsycl-targets` compiler flag);
* **gpu-intel-dg2** - Intel GPU DG2 availability; Automatically set if device
architecture belongs to DG2 family;
* **gpu-intel-gen11** - Intel GPU Gen11 availability; Automatically set if device
architecture belongs to Gen11 family;
* **gpu-intel-gen12** - Intel GPU Gen12 availability; Automatically set if device
architecture belongs to Gen12 family;

#### Manually-set features

Expand All @@ -247,17 +253,9 @@ section below). All these features are related to HW detection and they should
be considered deprecated, because we have HW auto-detection functionality in
place. No new tests should use these features:

* **gpu-intel-gen11** - Intel GPU Gen11 availability;
* **gpu-intel-gen12** - Intel GPU Gen12 availability;
* **gpu-intel-dg2** - Intel GPU DG2 availability;
* **gpu-intel-pvc** - Intel GPU PVC availability;
* **gpu-intel-pvc-vg** - Intel GPU PVC-VG availability;

Note: some of those features describing whole GPU families and auto-detection of
HW does not provide this functionality at the moment. As an improvement, we
could add those features even with auto-detection, because the only alternative
at the moment is to explicitly list every architecture from a family.

### llvm-lit parameters

Following options can be passed to llvm-lit tool through --param option to
Expand Down
42 changes: 42 additions & 0 deletions sycl/test-e2e/lit.cfg.py
Original file line number Diff line number Diff line change
Expand Up @@ -176,6 +176,31 @@
if lit_config.params.get("igc-dev", False):
config.available_features.add("igc-dev")

# Map between device family and architecture types.
device_family_arch_map = {
# <Family name> : Set of architectures types (and aliases)
# DG2
"gpu-intel-dg2": {
"intel_gpu_acm_g12",
"intel_gpu_dg2_g12",
"intel_gpu_acm_g11",
"intel_gpu_dg2_g11",
"intel_gpu_acm_g10",
"intel_gpu_dg2_g10",
},
# Gen12
"gpu-intel-gen12": {"intel_gpu_tgllp", "intel_gpu_tgl"},
# Gen11
"gpu-intel-gen11": {"intel_gpu_icllp", "intel_gpu_icl"},
}


def get_device_family_from_arch(arch):
for device_family, arch_set in device_family_arch_map.items():
if arch in arch_set:
return device_family
return None

def check_igc_tag_and_add_feature():
if os.path.isfile(config.igc_tag_file):
with open(config.igc_tag_file, "r") as tag_file:
Expand Down Expand Up @@ -773,10 +798,27 @@ def open_check_file(file_name):
aspect_features = set("aspect-" + a for a in aspects)
sg_size_features = set("sg-" + s for s in sg_sizes)
architecture_feature = set("arch-" + s for s in architectures)
# Add device family features like intel-gpu-gen12, intel-gpu-dg2 based on
# the architecture reported by sycl-ls.
device_family = set(
get_device_family_from_arch(arch)
for arch in architectures
if get_device_family_from_arch(arch) is not None
)

# Print the detected GPU family name.
if len(device_family) > 0:
lit_config.note(
"Detected GPU family for {}: {}".format(
sycl_device, ", ".join(device_family)
)
)

features = set()
features.update(aspect_features)
features.update(sg_size_features)
features.update(architecture_feature)
features.update(device_family)

be, dev = sycl_device.split(":")
features.add(dev.replace("fpga", "accelerator"))
Expand Down
Loading