Intel® oneAPI DPC++/C++ Compiler Developer Guide and Reference

ID 767253
Date 3/22/2024
Public

A newer version of this document is available. Customers should click here to go to the newest version.

Document Table of Contents

fsycl-device-code-split

Specifies a SYCL* device code module assembly.

Syntax

Linux:

-fsycl-device-code-split[=value]

Windows:

-fsycl-device-code-split[=value]

Arguments

value

Can be only one of the following:

per_kernel

Creates a separate device code module for each SYCL* kernel. Each device code module will contain a kernel and all its dependencies, such as called functions and used variables.

per_source

Creates a separate device code module for each source (translation unit).

Each device code module will contain a collection of kernels grouped on per-source basis and all their dependencies, such as all used variables and called functions, including the SYCL_EXTERNAL macro-marked functions from other translation units.

off

Creates a single module for all kernels. If option -fsycl-no-rdc is specified, the behavior is the same as per_source.

auto

The compiler will use a heuristic to select the best way of splitting device code. This is the same as specifying fsycl-device-code-split with no value.

Default

auto

This is the default whether you do not specify the compiler option or you do specify the compiler option, but omit a value. The compiler will use a heuristic to select the best way of splitting device code.

Description

This option specifies a SYCL* device code module assembly.

CAUTION:

If option -fno-sycl-rdc is also specified, option -fsycl-device-code-split=off is equivalent to -fsycl-device-code-split=per_source.

NOTE:

When using this option, you must also specify option -fsycl.

For information about available SYCL drivers, refer to Invoke the Compiler.

NOTE:

When SYCL offloading is enabled, this option only applies to device-specific compilation.

IDE Equivalent

None

Alternate Options

None

See Also