Skip to content

dev-v2 branch build failure #885

@Dr-Noob

Description

@Dr-Noob

Summary

Building dev-v2 with NVIDIA backend support fails.

Version

oneDNN dev-v2 (commit ad5176c)

Environment

Intel Xeon Gold. CentOS 8.2, clang 12.0 clang version 12.0.0 (https://github.com/intel/llvm 633691327b3f2d6a2a7a8321244682e91db78e7d).

Compiler obtained from https://github.com/intel/llvm and built succesfully with:

[drnoob@xeon sycl_workspace]$ python $DPCPP_HOME/llvm/buildbot/configure.py --cuda -t release
[drnoob@xeon sycl_workspace]$ python $DPCPP_HOME/llvm/buildbot/compile.py

Steps to reproduce

Tried to build as explained in README.md

[drnoob@xeon sycl_workspace]$ git clone https://github.com/oneapi-src/oneDNN && cd oneDNN
[drnoob@xeon oneDNN]$ git checkout dev-v2
[drnoob@xeon oneDNN]$ mkdir build/ && cd build/ 
[drnoob@xeon build]$ cp ../../build.sh .
[drnoob@xeon build]$ cat build.sh
export SYCL_HOME=~/sycl_workspace
export ONEDNN_HOME=$SYCL_HOME/oneDNN/
export DPCPP_HOME=$SYCL_HOME/llvm/build/bin/

export CC=$DPCPP_HOME/clang
export CXX=$DPCPP_HOME/clang++

cmake -DDNNL_CPU_RUNTIME=DPCPP -DDNNL_GPU_RUNTIME=DPCPP \
      -DDNNL_GPU_VENDOR=NVIDIA -G Ninja \
      -DOPENCLROOT=$SYCL_HOME/llvm/build/lib/ \
      -DOpenCL_INCLUDE_DIR=$SYCL_HOME/llvm/build/include/sycl/CL \
      -DCUBLAS_INCLUDE_DIR=/path/cuda-11.0/targets/x86_64-linux/include/ \
      -DCUBLAS_LIBRARY=/path/cuda-11.0/targets/x86_64-linux/lib/ \
      -DCUDNN_INCLUDE_DIR=/path/cuda-11.0/include/ \
      -DCUDNN_LIBRARY=/path/cuda-11.0/lib64 \
      -DTBBROOT=$SYCL_HOME/tbb/oneapi-tbb-2021.1-beta10/ ..
[drnoob@xeon build]$ ./build.sh
[drnoob@xeon build]$ ninja

Observed behavior

[drnoob@xeon build]$ ninja
[313/845] Building CXX object src/gpu/nvidia/CMakeFiles/dnnl_sycl_nvidia.dir/cudnn_lrn.cpp.o
FAILED: src/gpu/nvidia/CMakeFiles/dnnl_sycl_nvidia.dir/cudnn_lrn.cpp.o 
/home/drnoob/sycl_workspace/llvm/build/bin/clang++  -DCUDA_NO_HALF -DDNNL_DLL -DDNNL_DLL_EXPORTS -DDNNL_ENABLE_MAX_CPU_ISA -DDNNL_X64=1 -DNGEN_CPP11 -DNGEN_NEO_INTERFACE -DNGEN_NO_OP_NAMES -DNGEN_SAFE -DNGEN_WINDOWS_COMPAT -D__STDC_CONSTANT_MACROS -D__STDC_LIMIT_MACROS -I/home/drnoob/sycl_workspace/tbb/oneapi-tbb-2021.1-beta10/include -I../include -Iinclude -I../src -I/home/drnoob/sycl_workspace/llvm/build/include/sycl/CL -I/usr/local/cuda/include -I/home/modules/cuda-11.0/include -I/home/modules/cuda-11.0/targets/x86_64-linux/include -std=c++11 -fsycl -fvisibility-inlines-hidden  -Wall -Wno-unknown-pragmas -w -fvisibility=internal -msse4.1 -fPIC -Wformat -Wformat-security -fstack-protector-all   -Wno-pass-failed  -O2 -DNDEBUG -D_FORTIFY_SOURCE=2 -MD -MT src/gpu/nvidia/CMakeFiles/dnnl_sycl_nvidia.dir/cudnn_lrn.cpp.o -MF src/gpu/nvidia/CMakeFiles/dnnl_sycl_nvidia.dir/cudnn_lrn.cpp.o.d -o src/gpu/nvidia/CMakeFiles/dnnl_sycl_nvidia.dir/cudnn_lrn.cpp.o -c ../src/gpu/nvidia/cudnn_lrn.cpp
In file included from ../src/gpu/nvidia/cudnn_lrn.cpp:18:
In file included from ../src/gpu/nvidia/cudnn_lrn.hpp:23:
In file included from /home/drnoob/sycl_workspace/llvm/build/bin/../include/sycl/CL/sycl.hpp:11:
In file included from /home/drnoob/sycl_workspace/llvm/build/bin/../include/sycl/CL/sycl/ONEAPI/atomic.hpp:11:
In file included from /home/drnoob/sycl_workspace/llvm/build/bin/../include/sycl/CL/sycl/ONEAPI/atomic_accessor.hpp:11:
In file included from /home/drnoob/sycl_workspace/llvm/build/bin/../include/sycl/CL/sycl/ONEAPI/atomic_enums.hpp:12:
In file included from /home/drnoob/sycl_workspace/llvm/build/bin/../include/sycl/CL/sycl/access/access.hpp:10:
In file included from /home/drnoob/sycl_workspace/llvm/build/bin/../include/sycl/CL/sycl/detail/common.hpp:11:
/home/drnoob/sycl_workspace/llvm/build/bin/../include/sycl/CL/cl_ext_intel.h:431:9: error: unknown type name 'cl_properties'
typedef cl_properties cl_mem_properties_intel;
        ^
In file included from ../src/gpu/nvidia/cudnn_lrn.cpp:18:
In file included from ../src/gpu/nvidia/cudnn_lrn.hpp:23:
In file included from /home/drnoob/sycl_workspace/llvm/build/bin/../include/sycl/CL/sycl.hpp:11:
In file included from /home/drnoob/sycl_workspace/llvm/build/bin/../include/sycl/CL/sycl/ONEAPI/atomic.hpp:11:
In file included from /home/drnoob/sycl_workspace/llvm/build/bin/../include/sycl/CL/sycl/ONEAPI/atomic_accessor.hpp:11:
In file included from /home/drnoob/sycl_workspace/llvm/build/bin/../include/sycl/CL/sycl/ONEAPI/atomic_enums.hpp:12:
In file included from /home/drnoob/sycl_workspace/llvm/build/bin/../include/sycl/CL/sycl/access/access.hpp:10:
In file included from /home/drnoob/sycl_workspace/llvm/build/bin/../include/sycl/CL/sycl/detail/common.hpp:121:
In file included from /home/drnoob/sycl_workspace/llvm/build/bin/../include/sycl/CL/sycl/exception.hpp:15:
/home/drnoob/sycl_workspace/llvm/build/bin/../include/sycl/CL/sycl/detail/pi.h:228:7: error: use of undeclared identifier 'CL_DEVICE_QUEUE_ON_DEVICE_PROPERTIES'
      CL_DEVICE_QUEUE_ON_DEVICE_PROPERTIES,
      ^
/home/drnoob/sycl_workspace/llvm/build/bin/../include/sycl/CL/sycl/detail/pi.h:229:45: error: use of undeclared identifier 'CL_DEVICE_QUEUE_ON_HOST_PROPERTIES'
  PI_DEVICE_INFO_QUEUE_ON_HOST_PROPERTIES = CL_DEVICE_QUEUE_ON_HOST_PROPERTIES,
                                            ^
/home/drnoob/sycl_workspace/llvm/build/bin/../include/sycl/CL/sycl/detail/pi.h:233:31: error: use of undeclared identifier 'CL_DEVICE_IL_VERSION_KHR'
  PI_DEVICE_INFO_IL_VERSION = CL_DEVICE_IL_VERSION_KHR,
                              ^
/home/drnoob/sycl_workspace/llvm/build/bin/../include/sycl/CL/sycl/detail/pi.h:251:39: error: use of undeclared identifier 'CL_DEVICE_MAX_NUM_SUB_GROUPS'
  PI_DEVICE_INFO_MAX_NUM_SUB_GROUPS = CL_DEVICE_MAX_NUM_SUB_GROUPS,
                                      ^
/home/drnoob/sycl_workspace/llvm/build/bin/../include/sycl/CL/sycl/detail/pi.h:253:7: error: use of undeclared identifier 'CL_DEVICE_SUB_GROUP_INDEPENDENT_FORWARD_PROGRESS'
      CL_DEVICE_SUB_GROUP_INDEPENDENT_FORWARD_PROGRESS,
      ^
/home/drnoob/sycl_workspace/llvm/build/bin/../include/sycl/CL/sycl/detail/pi.h:287:34: error: use of undeclared identifier 'CL_QUEUE_DEVICE_DEFAULT'
  PI_QUEUE_INFO_DEVICE_DEFAULT = CL_QUEUE_DEVICE_DEFAULT,
                                 ^
/home/drnoob/sycl_workspace/llvm/build/bin/../include/sycl/CL/sycl/detail/pi.h:290:24: error: use of undeclared identifier 'CL_QUEUE_SIZE'
  PI_QUEUE_INFO_SIZE = CL_QUEUE_SIZE
                       ^
/home/drnoob/sycl_workspace/llvm/build/bin/../include/sycl/CL/sycl/detail/pi.h:334:34: error: use of undeclared identifier 'CL_KERNEL_MAX_SUB_GROUP_SIZE_FOR_NDRANGE'
  PI_KERNEL_MAX_SUB_GROUP_SIZE = CL_KERNEL_MAX_SUB_GROUP_SIZE_FOR_NDRANGE,
                                 ^
/home/drnoob/sycl_workspace/llvm/build/bin/../include/sycl/CL/sycl/detail/pi.h:335:34: error: use of undeclared identifier 'CL_KERNEL_MAX_NUM_SUB_GROUPS'; did you mean 'PI_KERNEL_MAX_SUB_GROUP_SIZE'?
  PI_KERNEL_MAX_NUM_SUB_GROUPS = CL_KERNEL_MAX_NUM_SUB_GROUPS,
                                 ^
/home/drnoob/sycl_workspace/llvm/build/bin/../include/sycl/CL/sycl/detail/pi.h:334:3: note: 'PI_KERNEL_MAX_SUB_GROUP_SIZE' declared here
  PI_KERNEL_MAX_SUB_GROUP_SIZE = CL_KERNEL_MAX_SUB_GROUP_SIZE_FOR_NDRANGE,
  ^
/home/drnoob/sycl_workspace/llvm/build/bin/../include/sycl/CL/sycl/detail/pi.h:336:38: error: use of undeclared identifier 'CL_KERNEL_COMPILE_NUM_SUB_GROUPS'; did you mean 'PI_KERNEL_MAX_NUM_SUB_GROUPS'?
  PI_KERNEL_COMPILE_NUM_SUB_GROUPS = CL_KERNEL_COMPILE_NUM_SUB_GROUPS,
                                     ^
/home/drnoob/sycl_workspace/llvm/build/bin/../include/sycl/CL/sycl/detail/pi.h:335:3: note: 'PI_KERNEL_MAX_NUM_SUB_GROUPS' declared here
  PI_KERNEL_MAX_NUM_SUB_GROUPS = CL_KERNEL_MAX_NUM_SUB_GROUPS,
  ^
/home/drnoob/sycl_workspace/llvm/build/bin/../include/sycl/CL/sycl/detail/pi.h:374:30: error: use of undeclared identifier 'CL_COMMAND_SVM_FREE'
  PI_COMMAND_TYPE_SVM_FREE = CL_COMMAND_SVM_FREE,
                             ^
/home/drnoob/sycl_workspace/llvm/build/bin/../include/sycl/CL/sycl/detail/pi.h:375:32: error: use of undeclared identifier 'CL_COMMAND_SVM_MEMCPY'
  PI_COMMAND_TYPE_SVM_MEMCPY = CL_COMMAND_SVM_MEMCPY,
                               ^
/home/drnoob/sycl_workspace/llvm/build/bin/../include/sycl/CL/sycl/detail/pi.h:376:33: error: use of undeclared identifier 'CL_COMMAND_SVM_MEMFILL'
  PI_COMMAND_TYPE_SVM_MEMFILL = CL_COMMAND_SVM_MEMFILL,
                                ^
/home/drnoob/sycl_workspace/llvm/build/bin/../include/sycl/CL/sycl/detail/pi.h:377:29: error: use of undeclared identifier 'CL_COMMAND_SVM_MAP'
  PI_COMMAND_TYPE_SVM_MAP = CL_COMMAND_SVM_MAP,
                            ^
/home/drnoob/sycl_workspace/llvm/build/bin/../include/sycl/CL/sycl/detail/pi.h:378:31: error: use of undeclared identifier 'CL_COMMAND_SVM_UNMAP'
  PI_COMMAND_TYPE_SVM_UNMAP = CL_COMMAND_SVM_UNMAP
                              ^
/home/drnoob/sycl_workspace/llvm/build/bin/../include/sycl/CL/sycl/detail/pi.h:405:33: error: use of undeclared identifier 'CL_ABGR'
  PI_IMAGE_CHANNEL_ORDER_ABGR = CL_ABGR,
                                ^
/home/drnoob/sycl_workspace/llvm/build/bin/../include/sycl/CL/sycl/detail/pi.h:444:37: error: use of undeclared identifier 'CL_SAMPLER_MIP_FILTER_MODE'; did you mean 'PI_SAMPLER_INFO_FILTER_MODE'?
  PI_SAMPLER_INFO_MIP_FILTER_MODE = CL_SAMPLER_MIP_FILTER_MODE,
                                    ^
/home/drnoob/sycl_workspace/llvm/build/bin/../include/sycl/CL/sycl/detail/pi.h:443:3: note: 'PI_SAMPLER_INFO_FILTER_MODE' declared here
  PI_SAMPLER_INFO_FILTER_MODE = CL_SAMPLER_FILTER_MODE,
  ^
/home/drnoob/sycl_workspace/llvm/build/bin/../include/sycl/CL/sycl/detail/pi.h:445:29: error: use of undeclared identifier 'CL_SAMPLER_LOD_MIN'
  PI_SAMPLER_INFO_LOD_MIN = CL_SAMPLER_LOD_MIN,
                            ^
fatal error: too many errors emitted, stopping now [-ferror-limit=]
20 errors generated.

Expected behavior

Expected a successful build.

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions