【干货分享】运行EGL Pixmap例子,测试MPSoC GPU性能

作者:付汉杰,hankf@xilinx.com,文章转载自:赛灵思中文社区论坛

可以使用EGL Pixmap例子测试MPSoC GPU性能。运行EGL Pixmap,要使用fbdev作为egl backend。

在 /project-spec/meta-user/conf/petalinuxbsp.conf里添加下列内容,再编译。

MALI_BACKEND_DEFAULT = "fbdev"
  IMAGE_INSTALL_append = " glmark2"
  DISTRO_FEATURES_remove = "x11"

然后使用新的文件启动单板,检查/usr/lib/libMali.so.8的真实指向。libMali.so.8应该指向libMali.so.8.0;不能指向x11版本的libMali.so.8.0,也就是/usr/lib/x11/libMali.so.8.0。正确指向:

root@zcu106_vcu_trd:~# ls /usr/lib/libMali.so.8 -l
lrwxrwxrwx 1 root root 14 Oct 24 08:07 /usr/lib/libMali.so.8 -> libMali.so.8.0

错误指向:

root@zcu106_vcu_trd:~# ls /usr/lib/libMali.so.8 -l
lrwxrwxrwx 1 root root      27 Oct 22 09:53 /usr/lib/libMali.so.8.0 -> /usr/lib/x11/libMali.so.8.0

测试打印

root@zcu106_vcu_trd:~# uname -a
Linux zcu106_vcu_trd 4.19.0-xilinx-v2019.1 #1 SMP Thu Oct 24 08:37:37 UTC 2019 aarch64 aarch64 aarch64 GNU/Linux
root@zcu106_vcu_trd:~# ls /usr/lib/libMali.so.8 -l
lrwxrwxrwx 1 root root 14 Oct 24 08:07 /usr/lib/libMali.so.8 -> libMali.so.8.0
root@zcu106_vcu_trd:~# ls
DMA_PixmapSampleOffscreen  shaders
root@zcu106_vcu_trd:~# chmod +x DMA_PixmapSampleOffscreen
root@zcu106_vcu_trd:~# ./DMA_PixmapSampleOffscreen
Warning gator_func(src/streamline_annotate.c:495): Not connected to gatord, the application will run normally but Streamline will not collect annotations. To collect annotations, please verify you are running gatord 5.24 or later and that SELinux is disabled.
FPS: = 62.341030
FPS: = 117.819085
FPS: = 117.955945
FPS: = 117.898722
FPS: = 117.910927
FPS: = 117.762765
FPS: = 117.934893
FPS: = 117.415290
FPS: = 117.758240
FPS: = 117.990914

最新文章

最新文章