Skip to content

[Doc] Update OpenCL Build Docs for the Khronos OpenCL SDK #4222

@bashbaug

Description

@bashbaug

Summary

The build docs currently say that building the OpenCL backend (with ONEDNN_GPU_RUNTIME=OCL) requires the Intel OpenCL SDK. It would be great to update this documentation to include instructions to build with the Khronos OpenCL SDK. This may simply require documentation updates or it may require minor CMake changes as well.

URLs

https://uxlfoundation.github.io/oneDNN/dev_guide_build_options.html#opencl

OpenCL runtime requires Intel(R) SDK for OpenCL* applications.

Additional details

I suspect OS-provided packages or other vendor SDKs will suffice for building in most cases, so perhaps these should be documented as well. It would still be nice to provide instructions in the build documentation using the Khronos OpenCL SDK, though, when OS packages or vendor SDKs are unavailable or too old.

In case it's helpful, these are the search hints for OpenCL include files (the search hints for libs are similar). Note that ${opencl_root_hints} is populated by the documented OPENCLROOT option:

find_path(OpenCL_INCLUDE_DIR
NAMES
CL/cl.h OpenCL/cl.h
HINTS
${opencl_root_hints}
ENV "PROGRAMFILES(X86)"
ENV AMDAPPSDKROOT
ENV INTELOCLSDKROOT
ENV NVSDKCOMPUTE_ROOT
ENV CUDA_PATH
ENV ATISTREAMSDKROOT
ENV OCL_ROOT
PATH_SUFFIXES
include
sycl
OpenCL/common/inc
"AMD APP/include")

Metadata

Metadata

Assignees

Labels

documentationA request to change/fix/improve the documentation. Codeowner: @oneapi-src/onednn-doc

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions