Package: pocl-opencl-icd Version: 3.0-7 Severity: normal X-Debbugs-Cc: cla...@mathr.co.uk
Dear Maintainer, * What led up to the situation? I have a program that uses OpenCL, including simultaneous use of multiple platforms and devices. When mesa-opencl-icd (Clover) is installed, usage of pocl-opencl-icd (PoCL) segfaults. The backtrace reveals PoCL calls LLVM 13, but somehow things get confused inside and LLVM 13 calls LLVM 15 which causes a crash. LLVM 15 is linked by mesa-opencl-icd. * What exactly did you do (or not do) that was effective (or ineffective)? Workaround to get functioning OpenCL: Either uninstall mesa-opencl-icd, and use pocl-opencl-icd for OpenCL, or uninstall pocl-opencl-icd and libpocl2, and use mesa-opencl-icd for OpenCL. * What outcome did you expect instead? It would be great if pocl-opencl-icd could be used at the same time as mesa-opencl-icd. I don't know how the dynamic library linking works, but maybe upgrading to LLVM 15 as used by mesa-opencl-icd would mask the issue? GDB Backtrace: ---8<--- (gdb) run ... Thread 55 "fraktaler-3.gcc" received signal SIGSEGV, Segmentation fault. [Switching to Thread 0x7fffab7fe6c0 (LWP 68040)] 0x00007fffed0d1528 in llvm::AnalysisManager<llvm::Function>::getResultImpl(llvm::AnalysisKey*, llvm::Function&) () from /lib/x86_64-linux-gnu/libLLVM-15.so.1 (gdb) bt #0 0x00007fffed0d1528 in llvm::AnalysisManager<llvm::Function>::getResultImpl(llvm::AnalysisKey*, llvm::Function&) () from /lib/x86_64-linux-gnu/libLLVM-15.so.1 #1 0x00007fffed0d13ca in llvm::AnalysisManager<llvm::Function>::getResultImpl(llvm::AnalysisKey*, llvm::Function&) () from /lib/x86_64-linux-gnu/libLLVM-15.so.1 #2 0x00007fffee2749b6 in llvm::AAManager::run(llvm::Function&, llvm::AnalysisManager<llvm::Function>&) () from /lib/x86_64-linux-gnu/libLLVM-15.so.1 #3 0x00007fffee52242b in ?? () from /lib/x86_64-linux-gnu/libLLVM-15.so.1 #4 0x00007fff8375aba1 in llvm::AnalysisManager<llvm::Function>::getResultImpl(llvm::AnalysisKey*, llvm::Function&) () from /lib/x86_64-linux-gnu/libLLVM-13.so.1 #5 0x00007fff841710e1 in llvm::InstCombinePass::run(llvm::Function&, llvm::AnalysisManager<llvm::Function>&) () from /lib/x86_64-linux-gnu/libLLVM-13.so.1 #6 0x00007fff85cd3a9d in ?? () from /lib/x86_64-linux-gnu/libLLVM-13.so.1 #7 0x00007fff8375841e in llvm::PassManager<llvm::Function, llvm::AnalysisManager<llvm::Function>>::run(llvm::Function&, llvm::AnalysisManager<llvm::Function>&) () from /lib/x86_64-linux-gnu/libLLVM-13.so.1 #8 0x00007fff8507e74d in ?? () from /lib/x86_64-linux-gnu/libLLVM-13.so.1 #9 0x00007fff8375bf7a in llvm::ModuleToFunctionPassAdaptor::run(llvm::Module&, llvm::AnalysisManager<llvm::Module>&) () from /lib/x86_64-linux-gnu/libLLVM-13.so.1 #10 0x00007fff8507e58d in ?? () from /lib/x86_64-linux-gnu/libLLVM-13.so.1 #11 0x00007fff8375717e in llvm::PassManager<llvm::Module, llvm::AnalysisManager<llvm::Module>>::run(llvm::Module&, llvm::AnalysisManager<llvm::Module>&) () from /lib/x86_64-linux-gnu/libLLVM-13.so.1 #12 0x00007fff8a18270f in ?? () from /lib/x86_64-linux-gnu/libclang-cpp.so.13 #13 0x00007fff8a17cf40 in clang::EmitBackendOutput(clang::DiagnosticsEngine&, clang::HeaderSearchOptions const&, clang::CodeGenOptions const&, clang::TargetOptions const&, clang::LangOptions const&, llvm::StringRef, llvm::Module*, clang::BackendAction, std::unique_ptr<llvm::raw_pwrite_stream, std::default_delete<llvm::raw_pwrite_stream> >) () from /lib/x86_64-linux-gnu/libclang-cpp.so.13 #14 0x00007fff8a43fefe in ?? () from /lib/x86_64-linux-gnu/libclang-cpp.so.13 #15 0x00007fff8941e794 in clang::ParseAST(clang::Sema&, bool, bool) () from /lib/x86_64-linux-gnu/libclang-cpp.so.13 #16 0x00007fff8a43c6d1 in clang::CodeGenAction::ExecuteAction() () from /lib/x86_64-linux-gnu/libclang-cpp.so.13 #17 0x00007fff8ac854a6 in clang::FrontendAction::Execute() () from /lib/x86_64-linux-gnu/libclang-cpp.so.13 #18 0x00007fff8abfeca6 in clang::CompilerInstance::ExecuteAction(clang::FrontendAction&) () from /lib/x86_64-linux-gnu/libclang-cpp.so.13 #19 0x00007fffa97acf86 in ?? () from /lib/x86_64-linux-gnu/libpocl.so.2.9.0 #20 0x00007fffa973ed40 in ?? () from /lib/x86_64-linux-gnu/libpocl.so.2.9.0 #21 0x00007fffa973d88c in ?? () from /lib/x86_64-linux-gnu/libpocl.so.2.9.0 #22 0x000055555563d383 in opencl_get_kernel (context=context@entry=0x7fffac001070, nt=nt@entry=nt_double, par=...) at src/opencl.cc:319 #23 0x000055555564bfd6 in render_device (queue=..., nt=nt_double, device=..., par=..., h=<optimized out>, ref_recalculated=<optimized out>, bla_recalculated=true, running=0x55555578e9a6 <running>) at src/render.cc:137 #24 0x000055555564e58c in operator() (device=<optimized out>, __closure=0x7fffc5a9c630) at src/render.cc:293 #25 operator() (__closure=0x7fffb8000cd8) at src/parallel.h:149 #26 std::__invoke_impl<void, parallel1d<render(const wlookup&, const param&, hooks*, bool, progress_t*, bool volatile*)::<lambda(coord_t)> >(int, coord_t, coord_t, coord_t, bool volatile*, render(const wlookup&, const param&, hooks*, bool, progress_t*, bool volatile*)::<lambda(coord_t)>)::<lambda()> > (__f=...) at /usr/include/c++/12/bits/invoke.h:61 #27 std::__invoke<parallel1d<render(const wlookup&, const param&, hooks*, bool, progress_t*, bool volatile*)::<lambda(coord_t)> >(int, coord_t, coord_t, coord_t, bool volatile*, render(const wlookup&, const param&, hooks*, bool, progress_t*, bool volatile*)::<lambda(coord_t)>)::<lambda()> > (__fn=...) at /usr/include/c++/12/bits/invoke.h:96 #28 std::thread::_Invoker<std::tuple<parallel1d<render(const wlookup&, const param&, hooks*, bool, progress_t*, bool volatile*)::<lambda(coord_t)> >(int, coord_t, coord_t, coord_t, bool volatile*, render(const wlookup&, const param&, hooks*, bool, progress_t*, bool volatile*)::<lambda(coord_t)>)::<lambda()> > >::_M_invoke<0> (this=0x7fffb8000cd8) at /usr/include/c++/12/bits/std_thread.h:252 #29 std::thread::_Invoker<std::tuple<parallel1d<render(const wlookup&, const param&, hooks*, bool, progress_t*, bool volatile*)::<lambda(coord_t)> >(int, coord_t, coord_t, coord_t, bool volatile*, render(const wlookup&, const param&, hooks*, bool, progress_t*, bool volatile*)::<lambda(coord_t)>)::<lambda()> > >::operator() (this=0x7fffb8000cd8) at /usr/include/c++/12/bits/std_thread.h:259 #30 std::thread::_State_impl<std::thread::_Invoker<std::tuple<parallel1d<render(const wlookup&, const param&, hooks*, bool, progress_t*, bool volatile*)::<lambda(coord_t)> >(int, coord_t, coord_t, coord_t, bool volatile*, render(const wlookup&, const param&, hooks*, bool, progress_t*, bool volatile*)::<lambda(coord_t)>)::<lambda()> > > >::_M_run(void) (this=0x7fffb8000cd0) at /usr/include/c++/12/bits/std_thread.h:210 #31 0x00007ffff7cd44a3 in ?? () from /lib/x86_64-linux-gnu/libstdc++.so.6 #32 0x00007ffff70e1fd4 in start_thread (arg=<optimized out>) at ./nptl/pthread_create.c:442 #33 0x00007ffff716266c in clone3 () at ../sysdeps/unix/sysv/linux/x86_64/clone3.S:81 (gdb) ---8<--- -- System Information: Debian Release: bookworm/sid APT prefers testing APT policy: (990, 'testing'), (500, 'testing-debug'), (500, 'unstable'), (1, 'experimental') Architecture: amd64 (x86_64) Foreign Architectures: i386 Kernel: Linux 6.0.0-4-amd64 (SMP w/16 CPU threads; PREEMPT) Kernel taint flags: TAINT_OOT_MODULE, TAINT_UNSIGNED_MODULE Locale: LANG=en_GB.UTF-8, LC_CTYPE=en_GB.UTF-8 (charmap=UTF-8), LANGUAGE=en_GB:en Shell: /bin/sh linked to /usr/bin/dash Init: systemd (via /run/systemd/system) LSM: AppArmor: enabled Versions of packages pocl-opencl-icd depends on: ii libpocl2 3.0-7 pocl-opencl-icd recommends no packages. pocl-opencl-icd suggests no packages. -- no debconf information