Re: Segmentation Fault Running clinfo

From: Jan Beich <jbeich_at_FreeBSD.org>
Date: Wed, 26 Feb 2025 22:07:49 UTC
Daniel Eastwood <DanieltheDeer@outlook.com> writes:

> Hello everyone,
>
>   I just installed OpenCL on a APU laptop with integrated graphics
> using clover driver. When I tried to run clinfo, seems everything is
> displayed properly but at the end of the program, it crashes with
> SEGFAULT. And clpeak could not start the test and crashes with
> SEGFAULT, too. I wonder why? How can I fix it?
>
> Device name: AMD SUMO (DRM 2.50.0 / 13.4-RELEASE, LLVM 15.0.7)
> Device version: OpenCL 1.1 Mesa 24.1.7
> …
> The only thing not displayed properly is Max Clock Freq: 0MHz
> (I installed everything through packages, will ports solve that?)

May be a known crash[1]. Can you try Rusticl[2] instead of Clover?
Upstream plans[3] to remove Clover. However, AMD SUMO uses r600 where
Rusticl support is experimental[4].

# pkg install mesa-devel
$ export RUSTICL_ENABLE=r600 || setenv RUSTICL_ENABLE r600
$ clinfo
$ clpeak

[1] https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=240761
[2] https://docs.mesa3d.org/envvars.html#envvar-RUSTICL_ENABLE
[3] https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/19385
[4] https://gitlab.freedesktop.org/mesa/mesa/-/issues/7420