oneDNN icon indicating copy to clipboard operation
oneDNN copied to clipboard

test the example of ocl, it reports "onednn_verbose,primitive,error,ocl,errcode -30,CL_INVALID_VALUE,src\gpu\ocl\ocl_utils.cpp:509"

Open feixuedudiao opened this issue 10 months ago • 9 comments

Summary

gpu-opencl-interop-cpp.exe > verbose_log.txt

onednn_verbose,info,oneDNN v3.4.1 (commit N/A) onednn_verbose,info,cpu,runtime:sequential,nthr:1 onednn_verbose,info,cpu,isa:Intel AVX2 onednn_verbose,info,gpu,runtime:OpenCL onednn_verbose,primitive,error,ocl,errcode -30,CL_INVALID_VALUE,src\gpu\ocl\ocl_utils.cpp:509 onednn_verbose,info,gpu,engine,0,name:Intel(R) UHD Graphics 630,driver_version:31.0.101,binary_kernels:enabled onednn_verbose,primitive,info,template:operation,engine,primitive,implementation,prop_kind,memory_descriptors,attributes,auxiliary,problem_desc,exec_time onednn_verbose,primitive,error,ocl,errcode -30,CL_INVALID_VALUE,src\gpu\ocl\ocl_utils.cpp:509 Example passed on GPU.

Environment

windows 10 cpu is i7-10700 @2.90GHz Compiler vs2022 with DNN_GPU_RUNTIME=ocl

Steps to reproduce

echo "beginning to build ...."

CALL "D:\Program Files\Microsoft Visual Studio\2022\Community\VC\Auxiliary\Build\vcvars64.bat"; REM CALL "D:\Program Files (x86)\Intel\oneAPI\setvars.bat"

mkdir "cpu_gpu_ocl_debug_x64" cd "cpu_gpu_ocl_debug_x64" cmake -G "Visual Studio 17 2022" -DCMAKE_BUILD_TYPE=debug -DDNNL_CPU_RUNTIME=SEQ -DDNNL_GPU_RUNTIME=OCL -DDNNL_WITH_LEVEL_ZERO=1 -DONEDNN_BUILD_GRAPH=OFF -DONEDNN_ENABLE_WORKLOAD=INFERENCE .. cmake --build . --config Debug cd ..

feixuedudiao avatar Apr 19 '24 08:04 feixuedudiao

@kealan-barbieri, it seems that the reported behavior is related to ebe77b566bb1cd273e9bda99cc62063b7c2a7e45. It seems that the error is caused by CL_DEVICE_HALF_FP_ATOMIC_CAPABILITIES_EXT not being one of the supported param_name values.

Does the new get_ocl_device_enabled_native_float_atomics function have any requirement to the OpenCL version? Can you please clarify if this is an expected behavior?

densamoilov avatar Apr 19 '24 16:04 densamoilov

Intel(R) UHD Graphics 630 support was discontinued and the last driver update published in the end of 2022. oneDNN does not support this generation either.

vpirogov avatar Apr 19 '24 19:04 vpirogov

CL_DEVICE_HALF_FP_ATOMIC_CAPABILITIES_EXT is the limiting factor for get_ocl_device_enabled_native_float_atomics. My understanding is it requires OpenCL 2.0 driver support (per extension doc), which is in line with the requirements in our README.

I'm testing to verify this code is compliant with our supported OpenCL versions. initial tests look good. The last driver version for Intel(R) UHD Graphics 630 does include API support for OpenCL 3.0 so this should not be an issue if that driver is installed.

kealan-barbieri avatar Apr 19 '24 20:04 kealan-barbieri

Submitted a trivial change that can eliminate this kind of issue without degrading the associated functionality. Thanks @rjoursler for the suggestion!

kealan-barbieri avatar Apr 19 '24 23:04 kealan-barbieri

@densamoilov, You are right! It crashed at " OCL_CHECK(clGetDeviceInfo(device, CL_DEVICE_HALF_FP_ATOMIC_CAPABILITIES_EXT, sizeof(cl_bitfield), &res, nullptr));" .But i don't know how to solve it or avoid it to happen. It happened in v3.4.1 of OneDNN,and there is no this parts code with v3.3.6, the difference of bettween the two version is what? 图片

feixuedudiao avatar Apr 22 '24 02:04 feixuedudiao

Hi @feixuedudiao, Thank you for reaching out to the Intel oneDNN team with your inquiry.

We understand that you are currently exploring the capabilities of the Intel oneDNN product, and we are happy to help it. We would like to get connect with you to better understand your specific use case and requirements.

can we get connected via email at [email protected] ?

onednnsupporttriage avatar Apr 22 '24 13:04 onednnsupporttriage

@onednnsupporttriage Thanks. Of course.

feixuedudiao avatar Apr 23 '24 05:04 feixuedudiao

Hi @feixuedudiao, do you have to chance to contact our support channel by the email ([email protected])?

thanks, Chao

onednnsupporttriage avatar May 06 '24 12:05 onednnsupporttriage

@onednnsupporttriage thanks, but it failed. 图片

feixuedudiao avatar May 08 '24 13:05 feixuedudiao