KhronosGroup / KhronosGroup/OpenCL-SDK
Device toolchains
- Dominant language
- C++
- Stars
- 777
- Forks
- 163
- Avg merge
- 6d 17h
- Merged PRs (30d)
- 2
Description
CMake has the notion of a Host toolchain which is useful for configuring for cross compilation and specifying which compiler to use. Would it be useful to extend this concept to cover Device toolchains as well? The OpenCL CTS Framework repository previously had the notion of a Device Toolchain described here: https://github.com/KhronosGroup/OpenCL-CTS-Framework/tree/master/03-conformance-checks
Some of the variables that were used in that repository are documented below:
* **CMAKE_OPENCL_TOOLCHAIN_NAME** - A string that can be used to describe the compiler
* **CMAKE_OPENCL_C_COMPILER** - Analogous to CMake's **CMAKE_C_COMPILER** variable. This is the path to the OpenCL C compiler binary
* **CMAKE_OPENCL_CXX_COMPILER** - Analogous to CMake's **CMAKE_CXX_COMPILER** variable. This is the path to the OpenCL C++ compiler binary
* **CMAKE_OPENCL_CXX_STDLIB** - This is the path to the OpenCL C++ compiler's standard library. OpenCL C++ standard libraries are assumed to be header-only for now.
* **CMAKE_OPENCL_CXX_INCLUDE_FLAG** - Used when passing in additional includes to the OpenCL C or OpenCL C++ compiler. A typical definition is "-I".
* **CMAKE_OPENCL_CXX_OUTPUT_FLAG** - Used when informing the compiler where to place the output binary. A typical definition is "-o".
* **CMAKE_OPENCL_CXX_INPUT_FLAG** - Used when passing in the source file's path to the OpenCL or OpenCL C++ compiler. With the reference Clang, this is left unset.
* **CMAKE_OPENCL_DEFAULT_FLAGS** - Default flags that are passed with every invocation of the compiler.
Contributor guide
No contributing guide indexed for this repository
Research direction
Start by reviewing the existing CMake host-toolchain support and the Device Toolchain description in the referenced OpenCL CTS Framework `03-conformance-checks` path. Compare the listed CMAKE_OPENCL_* variables with current needs, then define the toolchain design and validation needed before implementation.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cmake, cpp
- Domain
- build-system
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100