Panfrost driver missing?

Has anything changed with hevc hardware decoding or is it still without a maintainer?

Marginal improvements. I was able to resurrect earlier HEVC code and it works well with 8-bit media and devices with 8-bit pipelines (GXBB/GXL) but thereā€™s enough 10-bit support in the DRM driver for that code-path to be active and 10-bit fails locking the box up. The original maintainer stopped work more than a year back and has been radio silent since February. So far I didnā€™t talent spot any non-professional developer taking an interest ā€¦ there are plent of pro developers who could pick up the work but they have this terrible habit of wanting to be paid for their work :slight_smile:

Seeking in ffmpeg is somewhat working now following efforts from the Pi Foundation devs on their own vdec. Right now theirs is working well due to changes made in drivers as well as ffmpeg, and Amlogic has regressed due to nobody making similar changes in the Amlogic vdec. Hopefully now people are back from winter holidays we might catch up again.

All of this is increasinly off-topic for a panfrost threat ā€¦ although I should mention panfrost has achieved GLES 3.0 conformance now, and not much required for 3.1.

6 Likes

I now have panfrost running on the Khadas 5.9 kernel from debian buster image.
https://dl.khadas.com/Firmware/VIM3/Debian/VIM3_Debian-server-buster_Linux-5.9-rc2_arm64_SD-USB_V0.9.3-200907.img.xz

I converted to devuan for that shiny clean freshly-showered feeling.

glmark2-es gets 117 score

the fancy compositor ā€˜picomā€™ runs (this is lowering the glmark2-es score in the screenshot).

There are some errors and issues:

  • Sometimes menus in Xorg do not draw, sometimes there is corruption in terminal window.
  • 4k resolution is slow and exhibits many more glitches.
  • Xfce is unusuable and crashes the gpu. Thi is not surprising because Xfce causes severe problems with other drivers also. I use openbox for a simple window manager.

Huge big thanks to the people at Collabara and Khadas, and everyone else who has contributed. Fun with Vim3 is now +200%! :smiley: Happy 2021!

[EDIT]
I tried a few things in an attempt to get more stabile linux desktop with panfrost driver:

  • Tested weston (wayland) instead of xorg.
  • Compiled and tested latest wayfire (wayland) instead of xorg
  • Compiled and tested latest mesa and drm (this makes the X pointer invisible in front fo many backgrounds)
  • Tested all setups on two different monitors at 4k and 1080p resolutions.

Under no setup did i achieve ā€˜perfectā€™ results. Best so far has been wayfire with latest (jan 8) mesa. A big help has been fixing gpu clock rate.
echo 799999987 > /sys/devices/platform/soc/ffe40000.gpu/devfreq/ffe40000.gpu/min_freq

=======================================================
    glmark2 2020.04
=======================================================
    OpenGL Information
    GL_VENDOR:     Panfrost
    GL_RENDERER:   Mali G52 (Panfrost)
    GL_VERSION:    OpenGL ES 2.0 Mesa 21.0.0-devel (git-f01bca8100)
=======================================================
[build] use-vbo=false: FPS: 262 FrameTime: 3.817 ms
[build] use-vbo=true: FPS: 305 FrameTime: 3.279 ms
[texture] texture-filter=nearest: FPS: 533 FrameTime: 1.876 ms
[texture] texture-filter=linear: FPS: 510 FrameTime: 1.961 ms
[texture] texture-filter=mipmap: FPS: 519 FrameTime: 1.927 ms
[shading] shading=gouraud: FPS: 199 FrameTime: 5.025 ms
[shading] shading=blinn-phong-inf: FPS: 196 FrameTime: 5.102 ms
[shading] shading=phong: FPS: 181 FrameTime: 5.525 ms
[shading] shading=cel: FPS: 175 FrameTime: 5.714 ms
[bump] bump-render=high-poly: FPS: 70 FrameTime: 14.286 ms
[bump] bump-render=normals: FPS: 632 FrameTime: 1.582 ms
[bump] bump-render=height: FPS: 658 FrameTime: 1.520 ms
[effect2d] kernel=0,1,0;1,-4,1;0,1,0;: FPS: 497 FrameTime: 2.012 ms
[effect2d] kernel=1,1,1,1,1;1,1,1,1,1;1,1,1,1,1;: FPS: 197 FrameTime: 5.076 ms
[pulsar] light=false:quads=5:texture=false: FPS: 534 FrameTime: 1.873 ms
[desktop] blur-radius=5:effect=blur:passes=1:separable=true:windows=4: FPS: 117 FrameTime: 8.547 ms
[desktop] effect=shadow:windows=4: FPS: 434 FrameTime: 2.304 ms
[buffer] columns=200:interleave=false:update-dispersion=0.9:update-fraction=0.5:update-method=map: FPS: 58 FrameTime: 17.241 ms
[buffer] columns=200:interleave=false:update-dispersion=0.9:update-fraction=0.5:update-method=subdata: FPS: 57 FrameTime: 17.544 ms
[buffer] columns=200:interleave=true:update-dispersion=0.9:update-fraction=0.5:update-method=map: FPS: 90 FrameTime: 11.111 ms
[ideas] speed=duration: FPS: 143 FrameTime: 6.993 ms
[jellyfish] <default>: FPS: 217 FrameTime: 4.608 ms
[terrain] <default>: FPS: 11 FrameTime: 90.909 ms
[shadow] <default>: FPS: 147 FrameTime: 6.803 ms
[refract] <default>: FPS: 15 FrameTime: 66.667 ms
[conditionals] fragment-steps=0:vertex-steps=0: FPS: 654 FrameTime: 1.529 ms
[conditionals] fragment-steps=5:vertex-steps=0: FPS: 645 FrameTime: 1.550 ms
[conditionals] fragment-steps=0:vertex-steps=5: FPS: 675 FrameTime: 1.481 ms
[function] fragment-complexity=low:fragment-steps=5: FPS: 548 FrameTime: 1.825 ms
[function] fragment-complexity=medium:fragment-steps=5: FPS: 516 FrameTime: 1.938 ms
[loop] fragment-loop=false:fragment-steps=5:vertex-steps=5: FPS: 537 FrameTime: 1.862 ms
[loop] fragment-steps=5:fragment-uniform=false:vertex-steps=5: FPS: 536 FrameTime: 1.866 ms
[loop] fragment-steps=5:fragment-uniform=true:vertex-steps=5: FPS: 407 FrameTime: 2.457 ms
=======================================================
                                  glmark2 Score: 341 
=======================================================

[EDIT2]
I have slightly better stability with:
echo 600000000 > /sys/devices/platform/soc/ffe40000.gpu/devfreq/ffe40000.gpu/min_freq
echo 600000000 > /sys/devices/platform/soc/ffe40000.gpu/devfreq/ffe40000.gpu/max_freq
WIth the Aug27 khadas
Linux Khadas 5.9.0-rc2 #0.9.3 SMP Thu Aug 27 17:22:08 CST 2020 aarch64 GNU/Linux

7 Likes

Well nothing has freed me from gpu lockups requiring power cycle.

Tried locking gpu to all frequencies
124999998 249999996 285714281 399999994 499999992 666666656 799999987

Khadas, chewittā€¦ Someone plz halp with a VIM3 kernel with the panfrost g52 fixes since August.

PLEASE PLEASE

@clort76 did you try the 5.10 kernel ?
any luck there ?

I donā€™t build distro images on-request for people but my kernel branches are public on GH. To resolve issues you may also need to build mesa from the master branch to pick up the latest changes. The rate of change in panfrost is still quite high so the general rule is that mesa master will be better than ā€œstableā€ release mesa versions.

3 Likes

I have tested mesa git master from jan 7 and this did not resolve the issues.

I conclude, but am not certain, that we need the newer panfrost patches in newer kernels.

I have documented my results with latest Mesa master git and the Khadas 5.9-rc0 kernel from August. The showstopping GPU crash occurs under xorg and wayland (with weston and wayfire windowmanagers).

I am requesting that the person who builds khadas kernels share a newer 5.10.? mainline kernel (these contain updated panfrost patches for bifrost/g52), along with the .dtb required for /boot

I can be helpful in providing thorough testing of newer panfrost khadas kernel drivers before ā€œofficial releaseā€ to dl.khadas.org, I am a graphics guy (not a kernel guy).

Relevant discussion can be found here: Panfrost Status on Odroid N2

5.10 is also an LTS branch, and is therefore a better option than the already EOL 5.9 branch.

1 Like

@clort76 will this suffice ?
https://github.com/ZephyrLabs/Khadas-VIM3-Firmware/releases/download/v1-alpha/VIM3_Ubuntu-minimal-focal_Linux-5.10-rc6_arm64_SD-USB_V0.9.8-210108.img.xz

I know its not the kernel, but its something I already compiled beforeā€¦

4 Likes

I see a /boot with vmlinuz and dtb/ so you may be my hero very soon. Thank you Electr1.

These are jgmdevā€™s current glmark2-es2-wayland results on N2


=======================================================
glmark2 2020.04
=======================================================
OpenGL Information
GL_VENDOR: Panfrost
GL_RENDERER: Mali G52 (Panfrost)
GL_VERSION: OpenGL ES 2.0 Mesa 21.0.0-devel (git-67de6356f8)
=======================================================
[build] use-vbo=false: FPS: 570 FrameTime: 1.754 ms
[build] use-vbo=true: FPS: 611 FrameTime: 1.637 ms
[texture] texture-filter=nearest: FPS: 1386 FrameTime: 0.722 ms
[texture] texture-filter=linear: FPS: 1307 FrameTime: 0.765 ms
[texture] texture-filter=mipmap: FPS: 1282 FrameTime: 0.780 ms
[shading] shading=gouraud: FPS: 395 FrameTime: 2.532 ms
[shading] shading=blinn-phong-inf: FPS: 393 FrameTime: 2.545 ms
[shading] shading=phong: FPS: 362 FrameTime: 2.762 ms
[shading] shading=cel: FPS: 358 FrameTime: 2.793 ms
[bump] bump-render=high-poly: FPS: 138 FrameTime: 7.246 ms
[bump] bump-render=normals: FPS: 1459 FrameTime: 0.685 ms
[bump] bump-render=height: FPS: 1270 FrameTime: 0.787 ms
[effect2d] kernel=0,1,0;1,-4,1;0,1,0;: FPS: 706 FrameTime: 1.416 ms
[effect2d] kernel=1,1,1,1,1;1,1,1,1,1;1,1,1,1,1;: FPS: 286 FrameTime: 3.497 ms
[pulsar] light=false:quads=5:texture=false: FPS: 1596 FrameTime: 0.627 ms
[desktop] blur-radius=5:effect=blur:passes=1:separable=true:windows=4: FPS: 182 FrameTime: 5.495 ms
[desktop] effect=shadow:windows=4: FPS: 936 FrameTime: 1.068 ms
[buffer] columns=200:interleave=false:update-dispersion=0.9:update-fraction=0.5:update-method=map: FPS: 230 FrameTime: 4.348 ms
[buffer] columns=200:interleave=false:update-dispersion=0.9:update-fraction=0.5:update-method=subdata: FPS: 228 FrameTime: 4.386 ms
[buffer] columns=200:interleave=true:update-dispersion=0.9:update-fraction=0.5:update-method=map: FPS: 251 FrameTime: 3.984 ms
[ideas] speed=duration: FPS: 249 FrameTime: 4.016 ms
[jellyfish] : FPS: 447 FrameTime: 2.237 ms
[terrain] : FPS: 22 FrameTime: 45.455 ms
[shadow] : FPS: 279 FrameTime: 3.584 ms
[refract] : FPS: 36 FrameTime: 27.778 ms
[conditionals] fragment-steps=0:vertex-steps=0: FPS: 1249 FrameTime: 0.801 ms
[conditionals] fragment-steps=5:vertex-steps=0: FPS: 860 FrameTime: 1.163 ms
[conditionals] fragment-steps=0:vertex-steps=5: FPS: 1052 FrameTime: 0.951 ms
[function] fragment-complexity=low:fragment-steps=5: FPS: 1155 FrameTime: 0.866 ms
[function] fragment-complexity=medium:fragment-steps=5: FPS: 863 FrameTime: 1.159 ms
[loop] fragment-loop=false:fragment-steps=5:vertex-steps=5: FPS: 1077 FrameTime: 0.929 ms
[loop] fragment-steps=5:fragment-uniform=false:vertex-steps=5: FPS: 1045 FrameTime: 0.957 ms
[loop] fragment-steps=5:fragment-uniform=true:vertex-steps=5: FPS: 680 FrameTime: 1.471 ms
=======================================================
glmark2 Score: 695
=======================================================

1 Like

Thanks to Electr1, we have


=======================================================
    glmark2 2020.04
=======================================================
    OpenGL Information
    GL_VENDOR:     Panfrost
    GL_RENDERER:   Mali G52 (Panfrost)
    GL_VERSION:    OpenGL ES 2.0 Mesa 21.0.0-devel (git-f01bca8100)
=======================================================
[build] use-vbo=false: FPS: 604 FrameTime: 1.656 ms
[build] use-vbo=true: FPS: 652 FrameTime: 1.534 ms
[texture] texture-filter=nearest: FPS: 1766 FrameTime: 0.566 ms
[texture] texture-filter=linear: FPS: 1781 FrameTime: 0.561 ms
[texture] texture-filter=mipmap: FPS: 1781 FrameTime: 0.561 ms
[shading] shading=gouraud: FPS: 413 FrameTime: 2.421 ms
[shading] shading=blinn-phong-inf: FPS: 420 FrameTime: 2.381 ms
[shading] shading=phong: FPS: 378 FrameTime: 2.646 ms
[shading] shading=cel: FPS: 370 FrameTime: 2.703 ms
[bump] bump-render=high-poly: FPS: 147 FrameTime: 6.803 ms
[bump] bump-render=normals: FPS: 1483 FrameTime: 0.674 ms
[bump] bump-render=height: FPS: 1361 FrameTime: 0.735 ms
[effect2d] kernel=0,1,0;1,-4,1;0,1,0;: FPS: 751 FrameTime: 1.332 ms
[effect2d] kernel=1,1,1,1,1;1,1,1,1,1;1,1,1,1,1;: FPS: 300 FrameTime: 3.333 ms
[pulsar] light=false:quads=5:texture=false: FPS: 1641 FrameTime: 0.609 ms
[desktop] blur-radius=5:effect=blur:passes=1:separable=true:windows=4: FPS: 207 FrameTime: 4.831 ms
[desktop] effect=shadow:windows=4: FPS: 911 FrameTime: 1.098 ms
[buffer] columns=200:interleave=false:update-dispersion=0.9:update-fraction=0.5:update-method=map: FPS: 129 FrameTime: 7.752 ms
[buffer] columns=200:interleave=false:update-dispersion=0.9:update-fraction=0.5:update-method=subdata: FPS: 130 FrameTime: 7.692 ms
[buffer] columns=200:interleave=true:update-dispersion=0.9:update-fraction=0.5:update-method=map: FPS: 214 FrameTime: 4.673 ms
[ideas] speed=duration: FPS: 164 FrameTime: 6.098 ms
[jellyfish] <default>: FPS: 467 FrameTime: 2.141 ms
[terrain] <default>: FPS: 22 FrameTime: 45.455 ms
[shadow] <default>: FPS: 296 FrameTime: 3.378 ms
[refract] <default>: FPS: 36 FrameTime: 27.778 ms
[conditionals] fragment-steps=0:vertex-steps=0: FPS: 1260 FrameTime: 0.794 ms
[conditionals] fragment-steps=5:vertex-steps=0: FPS: 918 FrameTime: 1.089 ms
[conditionals] fragment-steps=0:vertex-steps=5: FPS: 1233 FrameTime: 0.811 ms
[function] fragment-complexity=low:fragment-steps=5: FPS: 1223 FrameTime: 0.818 ms
[function] fragment-complexity=medium:fragment-steps=5: FPS: 912 FrameTime: 1.096 ms
[loop] fragment-loop=false:fragment-steps=5:vertex-steps=5: FPS: 1179 FrameTime: 0.848 ms
[loop] fragment-steps=5:fragment-uniform=false:vertex-steps=5: FPS: 1171 FrameTime: 0.854 ms
[loop] fragment-steps=5:fragment-uniform=true:vertex-steps=5: FPS: 713 FrameTime: 1.403 ms
=======================================================
                                  glmark2 Score: 758 
=======================================================
3 Likes

That is good news, but what does Bender say about it? :laughing:

yay! better graphics performance! :partying_face:

@clort76 if possible could you list some step you used to get the current wayfire + the desktop environment + devuan converted from the regular image, I would like to try it out with some other changes and desktop environment :grinning:

I started with your ubuntu image, then converted to devuan using (basically) the steps i described in another post on this forum.

Then I built new wayfire and new mesa from git master. It took some help in irc to get wayfire setup.

N.B. some games are not happy. Morrowind (openMW) running at 1920x1080 gets under 10 fps in dense scenes with moderately-high settings

If anyone is interested in livechat, you are welcome to join freenode ##panfrost-offtopic, which is were some of us panfrost users hang out.

1 Like

Recent mesa optimizations have given us > 2000 FPS with textured cube (mipmap) :smiley:

glmark2-es2-wayland 
=======================================================
    glmark2 2020.04
=======================================================
    OpenGL Information
    GL_VENDOR:     Panfrost
    GL_RENDERER:   Mali G52 (Panfrost)
    GL_VERSION:    OpenGL ES 3.0 Mesa 21.1.0-devel (git-824ae64477)
=======================================================
[build] use-vbo=false: FPS: 656 FrameTime: 1.524 ms
[build] use-vbo=true: FPS: 662 FrameTime: 1.511 ms
[texture] texture-filter=nearest: FPS: 1922 FrameTime: 0.520 ms
[texture] texture-filter=linear: FPS: 1985 FrameTime: 0.504 ms
[texture] texture-filter=mipmap: FPS: 2020 FrameTime: 0.495 ms
[shading] shading=gouraud: FPS: 424 FrameTime: 2.358 ms
[shading] shading=blinn-phong-inf: FPS: 428 FrameTime: 2.336 ms
[shading] shading=phong: FPS: 380 FrameTime: 2.632 ms
[shading] shading=cel: FPS: 379 FrameTime: 2.639 ms
[bump] bump-render=high-poly: FPS: 147 FrameTime: 6.803 ms
[bump] bump-render=normals: FPS: 1699 FrameTime: 0.589 ms
[bump] bump-render=height: FPS: 1486 FrameTime: 0.673 ms
[effect2d] kernel=0,1,0;1,-4,1;0,1,0;: FPS: 754 FrameTime: 1.326 ms
[effect2d] kernel=1,1,1,1,1;1,1,1,1,1;1,1,1,1,1;: FPS: 301 FrameTime: 3.322 ms
[pulsar] light=false:quads=5:texture=false: FPS: 2108 FrameTime: 0.474 ms
[desktop] blur-radius=5:effect=blur:passes=1:separable=true:windows=4: FPS: 206 FrameTime: 4.854 ms
[desktop] effect=shadow:windows=4: FPS: 1013 FrameTime: 0.987 ms
[buffer] columns=200:interleave=false:update-dispersion=0.9:update-fraction=0.5:update-method=map: FPS: 146 FrameTime: 6.849 ms
[buffer] columns=200:interleave=false:update-dispersion=0.9:update-fraction=0.5:update-method=subdata: FPS: 148 FrameTime: 6.757 ms
[buffer] columns=200:interleave=true:update-dispersion=0.9:update-fraction=0.5:update-method=map: FPS: 236 FrameTime: 4.237 ms
[ideas] speed=duration: FPS: 238 FrameTime: 4.202 ms
[jellyfish] <default>: FPS: 476 FrameTime: 2.101 ms
[terrain] <default>: FPS: 22 FrameTime: 45.455 ms
[shadow] <default>: FPS: 297 FrameTime: 3.367 ms
[refract] <default>: FPS: 36 FrameTime: 27.778 ms
[conditionals] fragment-steps=0:vertex-steps=0: FPS: 1347 FrameTime: 0.742 ms
[conditionals] fragment-steps=5:vertex-steps=0: FPS: 918 FrameTime: 1.089 ms
[conditionals] fragment-steps=0:vertex-steps=5: FPS: 1303 FrameTime: 0.767 ms
[function] fragment-complexity=low:fragment-steps=5: FPS: 1137 FrameTime: 0.880 ms
[function] fragment-complexity=medium:fragment-steps=5: FPS: 918 FrameTime: 1.089 ms
[loop] fragment-loop=false:fragment-steps=5:vertex-steps=5: FPS: 1184 FrameTime: 0.845 ms
[loop] fragment-steps=5:fragment-uniform=false:vertex-steps=5: FPS: 1188 FrameTime: 0.842 ms
[loop] fragment-steps=5:fragment-uniform=true:vertex-steps=5: FPS: 722 FrameTime: 1.385 ms
=======================================================
                                  glmark2 Score: 814 
=======================================================

Notable improvements include

  • [texture] texture-filter=mipmap: +13.4 %
    
  • [bump] bump-render=normals: +14.6 %
    
  • [pulsar]: +28.5 %
    
  • [ideas] + 45.1 %
    

A few tests showed minor slowdown, but overall glmark2 score is up 7.4%

  • New linux-native games compiled and tested include Doom3, GTA III, GTA Vice City with playable fps.

  • Shaders from glsl sandbox still seem to do very poorly no matter what tool i use to run and render them.

  • Dolphin emulator is GPU bound but thereā€™s not much geometry visible, so there might be tweaks to bring it up to playable.

Would there be interest in a ā€œgaming on panfrostā€ thread with configuration and build tips?

5 Likes

Certainly.

(Filler text; ignore)

@clort76 Minecraft-java is an enticing game to test as well,

it runs barely playable on the RK3399, with mods for optimization like sodium,
I am sure the VIM3 could play with quite reasonable framerates, without the need for optimizations :slightly_smiling_face: