We recompiled with:
g++ -O2 clDeviceQuery.cpp -L /usr/lib -l OpenCL -o opencl-query
and now I have an OpenCL device. (fwiw my dmesg output looks very much like yours above.)
Thanks, J.
@Alex-Kushleyev said in GPU "hello world":
dmesg | grep gsl
We recompiled with:
g++ -O2 clDeviceQuery.cpp -L /usr/lib -l OpenCL -o opencl-query
and now I have an OpenCL device. (fwiw my dmesg output looks very much like yours above.)
Thanks, J.
@Alex-Kushleyev said in GPU "hello world":
dmesg | grep gsl
@Alex-Kushleyev - Thanks.
I downloaded and compiled clDeviceQuery.cpp.
It gives the same result as "clinfo" and "hellocl.c" - no devices found:
$ ./opencl-query
clDeviceQuery Starting...
Error -1001 in clGetPlatformIDs Call!
System Info:
Local Time/Date = 13:38:42, 11/22/2024
CPU Name: none
# of CPU processors: 8
Linux version 4.19.125 (oe-user@oe-host) (gcc version 7.5.0 (Ubuntu/Linaro 7.5.0-3ubuntu1~18.04), GNU ld (GNU Binutils for Ubuntu) 2.30) #1 SMP PREEMPT Fri May 17 23:29:23 UTC 2024
TEST FAILED !!!
Perhaps I need to load a kernel module to enable OpenCL? This is what's loaded:
$ lsmod
Module Size Used by
voxl_platform_mod 16384 0
voxl_gpio_mod 16384 0
voxl_fsync_mod 16384 0
machine_dlkm 159744 0
wcd938x_slave_dlkm 16384 0
wcd938x_dlkm 110592 1 machine_dlkm
wcd9xxx_dlkm 49152 1 wcd938x_dlkm
mbhc_dlkm 45056 1 wcd938x_dlkm
tx_macro_dlkm 106496 0
rx_macro_dlkm 102400 0
va_macro_dlkm 98304 0
wsa_macro_dlkm 69632 1 machine_dlkm
swr_ctrl_dlkm 57344 4 wsa_macro_dlkm,tx_macro_dlkm,rx_macro_dlkm,va_macro_dlkm
bolero_cdc_dlkm 57344 5 machine_dlkm,wsa_macro_dlkm,tx_macro_dlkm,rx_macro_dlkm,va_macro_dlkm
wsa881x_dlkm 45056 1 machine_dlkm
wcd_core_dlkm 32768 7 wsa881x_dlkm,machine_dlkm,wsa_macro_dlkm,tx_macro_dlkm,rx_macro_dlkm,va_macro_dlkm,wcd938x_dlkm
stub_dlkm 16384 0
hdmi_dlkm 24576 0
swr_dlkm 24576 4 wsa881x_dlkm,wcd938x_dlkm,swr_ctrl_dlkm,wcd938x_slave_dlkm
pinctrl_lpi_dlkm 20480 0
pinctrl_wcd_dlkm 16384 0
usf_dlkm 57344 0
native_dlkm 163840 0
platform_dlkm 2195456 1 native_dlkm
q6_dlkm 909312 9 bolero_cdc_dlkm,machine_dlkm,pinctrl_lpi_dlkm,usf_dlkm,va_macro_dlkm,swr_ctrl_dlkm,wcd9xxx_dlkm,native_dlkm,platform_dlkm
adsp_loader_dlkm 16384 0
apr_dlkm 229376 4 q6_dlkm,usf_dlkm,adsp_loader_dlkm,platform_dlkm
snd_event_dlkm 16384 5 bolero_cdc_dlkm,machine_dlkm,q6_dlkm,pinctrl_lpi_dlkm,apr_dlkm
q6_notifier_dlkm 16384 3 q6_dlkm,pinctrl_lpi_dlkm,apr_dlkm
q6_pdr_dlkm 16384 1 q6_notifier_dlkm
88XXau 2342912 0
8821cu 2465792 0
8188eu 1200128 0
@Alex-Kushleyev said in GPU "hello world":
QUALCOMM Adreno
Hi,
I'm trying to write a benchmark for GPU performance on a VOXL 2 (voxl-suite 1.3.5)
So far I've not been able to get a hardware-accelerated OpenGL context.
Is there a "hello world" example that draws something on the GPU and reads the resulting image?
This package
https://moderngl.readthedocs.io/en/latest/techniques/headless_ubuntu_18_server.html
looked promising, but when I run it I only get a software-rendering context.
Or a similar OpenCL tiny app? (I tried "hellocl.zip" mentioned in another thread, and it doesn't find any hardware, as does "clinfo").
Thanks,
James.