Skip to content

[SYCL] Improve env var controls docs #799

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

Merged
merged 1 commit into from
Nov 25, 2019
Merged
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
23 changes: 18 additions & 5 deletions sycl/doc/SYCLEnvironmentVariables.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,24 @@ This file describes environment variables that are having effect on SYCL compile

# Controlling SYCL RT

| Environment variable | Description |
| ----------- | ----------- |
| SYCL_PI_TRACE | If set forces tracing of PI calls to stdout. |
| SYCL_BE={PI_OPENCL,PI_OTHER} | When SYCL RT is built with PI this controls which plugin to use. |
| SYCL_PRINT_EXECUTION_GRAPH | Print execution graph to DOT text file. Options are described below. |
**Warning:** the environment variables described in this document are used for
development and debugging of SYCL runtime and compiler. Their semantics are
subject to change. Do not rely on these variables in production code.

| Environment variable | Values | Description |
| -------------------- | ------ | ----------- |
| SYCL_PI_TRACE | Any(*) | Force tracing of PI calls to stderr. |
| SYCL_BE | PI_OPENCL, PI_OTHER | When SYCL RT is built with PI this controls which plugin to use. Default value is PI_OPENCL. |
| SYCL_DEVICE_TYPE | One of: CPU, GPU, ACC, HOST | Force SYCL to use the specified device type. If unset, default selection rules are applied. If set to any unlisted value, this control has no effect. If the requested device type is not found, a `cl::sycl::runtime_error` exception is thrown. If a non-default device selector is used, a device must satisfy both the selector and this control to be chosen. This control only has effect on devices created with a selector. |
| SYCL_PROGRAM_BUILD_OPTIONS | String of valid OpenCL build options | Override build options for all programs. |
| SYCL_USE_KERNEL_SPV | Path to the SPIR-V binary | Load device image from the specified file. If runtime is unable to read the file, `cl::sycl::runtime_error` exception is thrown.|
| SYCL_DUMP_IMAGES | Any(*) | Dump device image binaries to file. Control has no effect if SYCL_USE_KERNEL_SPV is set. |
| SYCL_PRINT_EXECUTION_GRAPH | Described [below](#sycl_print_execution_graph-options) | Print execution graph to DOT text file. |
| SYCL_THROW_ON_BLOCK | Any(*) | Throw an exception on attempt to wait for a blocked command. |

`(*) Note: Any means this environment variable is effective when set to any non-null value.`

## SYCL_PRINT_EXECUTION_GRAPH Options

SYCL_PRINT_EXECUTION_GRAPH can accept one or more comma separated values from table below

Expand Down