Options
There are a number of CMake options which are specific to the implementation and testing of the OpenCL library, these are outlined below.
- CA_CL_LIBRARY_NAME
A string CMake option to override the output name of the OpenCL shared library.
- Default value
"CL"
- CA_CL_LIBRARY_VERSION
A string CMake option of the form
<major>.<minor>
to override the version of the OpenCL shared library.- Default value
"${ComputeAorta_VERSION_MAJOR}.${ComputeAorta_VERSION_MINOR}"
- CA_CL_PUBLIC_LINK_LIBRARIES
A list of additional libraries that the
CL
target should be linked against.- Default value
""
- CA_CL_ENABLE_ICD_LOADER
A boolean CMake option to enable building with the OpenCL ICD Loader.
- Default value
OFF
- CA_CL_EXTERNAL_ICD_LOADER_SOURCE_DIR
A external path to the OpenCL-ICD-Loader repository, which will be used instead of the OpenCL-ICD-Loader repository in source/cl/external/OpenCL-ICD-Loader. This option is only used if CA_CL_ENABLE_ICD_LOADER is ON.
- Default value
""
- CA_CL_ENABLE_INTERCEPT_LAYER
A CMake option to enable an in-tree build of the OpenCL Intercept Layer, the default value is
OFF
. To enable this option setCA_CL_ENABLE_INTERCEPT_LAYER
toON
during configuration. When set toON
,CA_CL_ENABLE_ICD_LOADER
must also be set toON
, otherwise CMake will emit an error.When enabled all targets created using
add_ca_cl_executable()
oradd_ca_cl_library()
will link against theOpenCL
target defined by the OpenCL Intercept Layer instead of linking against the OpenCL ICD Loader. Additionally, to avoid CMake configuration errors where both projects attempt to define theOpenCL
target, the OpenCL ICD Loader will be built as an ExternalProject.
- CA_CL_EXTERNAL_INTERCEPT_LAYER_SOURCE_DIR
A external path to the OpenCL-Intercept-Layer repository, which will be used instead of the OpenCL-Intercept-Layer repository in source/cl/external/OpenCL-Intercept-Layer. This option is only used if CA_CL_ENABLE_INTERCEPT_LAYER is ON.
- Default value
""
- CA_CL_ENABLE_VECZ_VP_CHECK
A boolean CMake option to enable vector-predication checks, including the check-ock-UnitCL-prevec-vecz-vp-partial-scalarization target.
- Default value
OFF
- CA_CL_ENABLE_OFFLINE_KERNEL_TESTS
A boolean CMake option to enable UnitCL offline compiler kernel tests.
- Default value
ON
- CA_CL_ENABLE_EXTENDED_CHECKS
A boolean CMake option to enable extended UnitCL testing.
- Default value
ON
- CA_CL_TEST_STATIC_LIB
A boolean CMake option to enable testing with the static CL target. This forces all CL executables to link the static library, meaning lit tests with clc/oclc are included in this.
- Default value
OFF