Skip to content
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
5 changes: 5 additions & 0 deletions sycl/test-e2e/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -250,6 +250,11 @@ place. No new tests should use these features:
* **gpu-intel-pvc** - Intel GPU PVC availability;
* **gpu-intel-pvc-vg** - Intel GPU PVC-VG availability;

### Use the LLVM SPIR-V Backend to generate SPIR-V code
It's possible to use the LLVM SPIR-V Backend instead of the `llvm-spirv` tool
to convert LLVM IR to SPIR-V. This feature must be set manually by passing the
`spirv-backend` parameter to `llvm-lit`.

### llvm-lit parameters

Following options can be passed to llvm-lit tool through --param option to
Expand Down
5 changes: 5 additions & 0 deletions sycl/test-e2e/format.py
Original file line number Diff line number Diff line change
Expand Up @@ -183,6 +183,11 @@ def execute(self, test, litConfig):
)
sycl_target_opts += hip_arch_opts
substitutions.append(("%{hip_arch_opts}", hip_arch_opts))
if (
get_triple("spir64") in triples
and "spirv-backend" in test.config.available_features
):
sycl_target_opts += " -fsycl-use-spirv-backend-for-spirv-gen"
substitutions.append(("%{sycl_target_opts}", sycl_target_opts))

substitutions.append(
Expand Down
2 changes: 2 additions & 0 deletions sycl/test-e2e/lit.cfg.py
Original file line number Diff line number Diff line change
Expand Up @@ -225,6 +225,8 @@ def check_igc_tag_and_add_feature():
if lit_config.params.get("enable-perf-tests", False):
config.available_features.add("enable-perf-tests")

if lit_config.params.get("spirv-backend", False):
config.available_features.add("spirv-backend")

# Use this to make sure that any dynamic checks below are done in the build
# directory and not where the sources are located. This is important for the
Expand Down
Loading