Skip to content

[SYCL] Unsupported kernel parameter type #1476

@jinz2014

Description

@jinz2014

Building the sycl benchmark at (https://github.com/bcosenza/sycl-bench) causes the following error after I build the current SYCL. Thanks for your check.

[ 3%] Building CXX object CMakeFiles/sobel7.dir/single-kernel/sobel7.cpp.o
Unsupported kernel parameter type
UNREACHABLE executed at /home/cc/sycl_workspace/llvm/clang/lib/Sema/SemaSYCL.cpp:1057!
Stack dump:
0. Program arguments: /home/cc/sycl_workspace/install/bin/clang-11 -cc1 -triple spir64-unknown-unknown-sycldevice -fsycl -fsycl-is-device -fdeclare-spirv-bu iltins -aux-triple x86_64-unknown-linux-gnu -sycl-std=2017 -Wno-sycl-strict -emit-llvm-bc -emit-llvm-uselists -disable-free -main-file-name sobel7.cpp -mrelocati on-model static -mthread-model posix -mframe-pointer=all -fmath-errno -fno-rounding-math -mconstructor-aliases -aux-target-cpu x86-64 -dwarf-column-info -fno-spl it-dwarf-inlining -debugger-tuning=gdb -resource-dir /home/cc/sycl_workspace/install/lib/clang/11.0.0 -D LLVM_SYCL -I /home/cc/sycl-bench/include -I /home/cc /sycl-bench/polybench/common -D NDEBUG -internal-isystem /usr/lib/gcc/x86_64-linux-gnu/7.5.0/../../../../include/c++/7.5.0 -internal-isystem /usr/lib/gcc/x86_64- linux-gnu/7.5.0/../../../../include/x86_64-linux-gnu/c++/7.5.0 -internal-isystem /usr/lib/gcc/x86_64-linux-gnu/7.5.0/../../../../include/x86_64-linux-gnu/c++/7.5 .0 -internal-isystem /usr/lib/gcc/x86_64-linux-gnu/7.5.0/../../../../include/c++/7.5.0/backward -internal-isystem /usr/lib/gcc/x86_64-linux-gnu/7.5.0/../../../.. /include/c++/7.5.0 -internal-isystem /usr/lib/gcc/x86_64-linux-gnu/7.5.0/../../../../include/x86_64-linux-gnu/c++/7.5.0 -internal-isystem /usr/lib/gcc/x86_64-lin ux-gnu/7.5.0/../../../../include/x86_64-linux-gnu/c++/7.5.0 -internal-isystem /usr/lib/gcc/x86_64-linux-gnu/7.5.0/../../../../include/c++/7.5.0/backward -interna l-isystem /home/cc/sycl_workspace/install/bin/../include/sycl -internal-isystem /usr/local/include -internal-isystem /home/cc/sycl_workspace/install/lib/clang/11 .0.0/include -internal-externc-isystem /usr/include/x86_64-linux-gnu -internal-externc-isystem /include -internal-externc-isystem /usr/include -internal-isystem /usr/local/include -internal-isystem /home/cc/sycl_workspace/install/lib/clang/11.0.0/include -internal-externc-isystem /usr/include/x86_64-linux-gnu -internal-e xternc-isystem /include -internal-externc-isystem /usr/include -O3 -std=c++1z -fdeprecated-macro -fdebug-compilation-dir /home/cc/sycl-bench/build -ferror-limit 19 -fmessage-length 0 -fgnuc-version=4.2.1 -fobjc-runtime=gcc -fcxx-exceptions -fexceptions -fdiagnostics-show-option -fcolor-diagnostics -vectorize-loops -vecto rize-slp -faddrsig -o /tmp/sobel7-113a16.bc -x c++ /home/cc/sycl-bench/single-kernel/sobel7.cpp
parser at end of file
/home/cc/sycl_workspace/install/bin/../include/sycl/CL/sycl/handler.hpp:548:8: instantiating function definition 'cl::sycl::handler::parallel_for<Sobel7B enchKernel, (lambda at /home/cc/sycl-bench/single-kernel/sobel7.cpp:52:52), 2>'
/home/cc/sycl_workspace/install/bin/clang-11(_ZN4llvm3sys15PrintStackTraceERNS_11raw_ostreamE+0x2a)[0x55a88e0ec85a]
/home/cc/sycl_workspace/install/bin/clang-11(_ZN4llvm3sys17RunSignalHandlersEv+0x34)[0x55a88e0ea374]
/home/cc/sycl_workspace/install/bin/clang-11(+0x1dc64c3)[0x55a88e0ea4c3]
/lib/x86_64-linux-gnu/libpthread.so.0(+0x12890)[0x7f8492645890]
/lib/x86_64-linux-gnu/libc.so.6(gsignal+0xc7)[0x7f8491520e97]
/lib/x86_64-linux-gnu/libc.so.6(abort+0x141)[0x7f8491522801]
/home/cc/sycl_workspace/install/bin/clang-11(+0x1d443aa)[0x55a88e0683aa]
/home/cc/sycl_workspace/install/bin/clang-11(_ZN5clang4Sema21ConstructOpenCLKernelEPNS_12FunctionDeclERNS_13MangleContextE+0x2707)[0x55a88fde8057]
/home/cc/sycl_workspace/install/bin/clang-11(_ZN5clang4Sema28PerformPendingInstantiationsEb+0x657)[0x55a88ff51017]
/home/cc/sycl_workspace/install/bin/clang-11(_ZN5clang4Sema29InstantiateFunctionDefinitionENS_14SourceLocationEPNS_12FunctionDeclEbbb+0x9ba)[0x55a88ff51afa]
/home/cc/sycl_workspace/install/bin/clang-11(_ZN5clang4Sema28PerformPendingInstantiationsEb+0x1de)[0x55a88ff50b9e]
/home/cc/sycl_workspace/install/bin/clang-11(+0x35b440b)[0x55a88f8d840b]
/home/cc/sycl_workspace/install/bin/clang-11(_ZN5clang4Sema25ActOnEndOfTranslationUnitEv+0x9f)[0x55a88f8d8c8f]
/home/cc/sycl_workspace/install/bin/clang-11(_ZN5clang6Parser17ParseTopLevelDeclERNS_9OpaquePtrINS_12DeclGroupRefEEEb+0x343)[0x55a88f7e1923]
/home/cc/sycl_workspace/install/bin/clang-11(_ZN5clang8ParseASTERNS_4SemaEbb+0x229)[0x55a88f7d74e9]
/home/cc/sycl_workspace/install/bin/clang-11(_ZN5clang13CodeGenAction13ExecuteActionEv+0xa8)[0x55a88eea62a8]
/home/cc/sycl_workspace/install/bin/clang-11(_ZN5clang14FrontendAction7ExecuteEv+0xc9)[0x55a88e8c7539]
/home/cc/sycl_workspace/install/bin/clang-11(_ZN5clang16CompilerInstance13ExecuteActionERNS_14FrontendActionE+0x202)[0x55a88e884502]
/home/cc/sycl_workspace/install/bin/clang-11(_ZN5clang25ExecuteCompilerInvocationEPNS_16CompilerInstanceE+0xc9c)[0x55a88e9770fc]
/home/cc/sycl_workspace/install/bin/clang-11(_Z8cc1_mainN4llvm8ArrayRefIPKcEES2_Pv+0x1134)[0x55a88d06f334]
/home/cc/sycl_workspace/install/bin/clang-11(+0xd46689)[0x55a88d06a689]
/home/cc/sycl_workspace/install/bin/clang-11(main+0x77f)[0x55a88cfe617f]
/lib/x86_64-linux-gnu/libc.so.6(__libc_start_main+0xe7)[0x7f8491503b97]
/home/cc/sycl_workspace/install/bin/clang-11(_start+0x2a)[0x55a88d06a1ea]
clang-11: error: unable to execute command: Aborted (core dumped)
clang-11: error: clang frontend command failed due to signal (use -v to see invocation)
clang version 11.0.0 (https://github.com/intel/llvm 4cf1610)
Target: x86_64-unknown-linux-gnu
Thread model: posix
InstalledDir: /home/cc/sycl_workspace/install/bin
clang-11: note: diagnostic msg: PLEASE submit a bug report to https://bugs.llvm.org/ and include the crash backtrace, preprocessed source, and associated run scr ipt.
clang-11: note: diagnostic msg: Error generating preprocessed source(s).
CMakeFiles/sobel7.dir/build.make:62: recipe for target 'CMakeFiles/sobel7.dir/single-kernel/sobel7.cpp.o' failed
make[2]: *** [CMakeFiles/sobel7.dir/single-kernel/sobel7.cpp.o] Error 254
CMakeFiles/Makefile2:104: recipe for target 'CMakeFiles/sobel7.dir/all' failed
make[1]: *** [CMakeFiles/sobel7.dir/all] Error 2
Makefile:129: recipe for target 'all' failed
make: *** [all] Error 2

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions