Experiment 1) Discovering LIMA:

When I first heard about the lima driver it was over at limadriver.org, at that time I didn’t had much interest as I was more of an RPi FanBoy but also the VC4 Opensource driver was coming along fairly well that that seemed more interesting and in contrast the development on the lima driver had gone a bit stale tbh.

Fast forward to a few months back I saw this post from Phoronix, about the re-initiation of work on the Lima driver by Qiang Yu, but again reading the lines “So far this Mesa Gallium3D driver can run a simple OpenGL triangle draw application” put my interest on hold… until two weeks back.

 

Experiment 2) Off-Screen Rendering

Now when I finally decided to go ahead and try this out, I didn’t had any device that would work out of the box with the existing build systems (as it later turns out I did) that included buildroot for Allwinner based devices and Yocto for Amlogic SoC. So naturally I had to enable a close relative and that turned out to be the Banana Pi M1+ since CubieBoard2 was already enabled with lima in build root and both the boards use the Allwinner A20 SoC.

So they way Mali GPUs work in general, and this is afaik, they are used for rendering ONLY, all the display work is done by a separate display processor usually specific to the SoC vendor (like sun4i-drm for Allwinner, mason-drm for Amlogic etc.) unless they are using one build by Arm. So at a given time there are two DRM(Direct Rendering Infrastructure + Kernel Modsetting + a bunch of other things) drivers running one for the “Display Processor” for the actual video output and a second one for the actual GPU for rendering. And LIMA tackles the latter one, the one that does all the rendering.

So now that you know this you should also know that I was completely unaware of this situation, so I merrily went ahead and enabled the lima-drm driver for Banana Pi and…. drum roll…. kmscube crashed 🙁 (for obvious reasons). However it worked great off-screen and this is how that looks:

 

Experiment 3) On-Screen Rendering and Nano Pi M1

NOW after a few emails back and forth I am aware of the situation. So before I went ahead and enabled the sun4i-drm, I really wanted to see Lima working, and still unaware of the fact that I do actually own a verified board, I went ahead and bought the Nano Pi M1 since Qiang Yu uses that on his end and it was really cheap.

So it did end up working really well, and I also ended up adding support for the Banana Pi M1+

 

Experiment 4) Khadas Vim, Mali 450, and GLMark2

NOW I FINALLY REALIZE that I have the Khadas Vim that has the Amlogic S905X which is verified, I setup a yocto build for that and… drum roll… It wont boot 🙁

Again a few emails back and forth and we found out the issue was with wrong root partition path, solved that and now kmscube runs smoooooth.

But now I want to sun something a bit more “real world” because as exciting it is to people like me, a spinning cube on a grey background doesn’t speak out to the general public as spinning horse, cat and jellyfish do. Ofc I am talking about glmark2. After coming across this thread on the mesa-lima repo, I was able to get bits and pieces of GLMark2 working and it looked Coool…

Here is a small demo of kmscube and whatever-runs-in-GLMark2: 400 vs 450

 

And now I am off to try and enable more boards and possibly SoC(s)…

 

Acknowledgements:

Qiang Yu: for LIMA and helping out with Banana Pi M1+

Erico Nunes: For Allwinner LIMA Buildroot

Neil Armstrong: For Help with Kadas Vim and Amlogic OE meta layer and moon landing

Vasily Khoruzhick: GLMark2 discussions.

Hey all,

I know I don’t do a lot of blog posts like this one, most of them are just extra info on the video I upload, however that is planned to change and hopefully it looks more like a blog.
To begin with, some good news!

I am so excited to announce that I have joined the 96Boards team at Linaro as an Applications Engineer 😀

As a part of my job I’d be responsible, along with my colleges for a lot of demo projects that are created by my team as well as a bunch of documentations and community support as usual.
This brings up an obvious question about the YouTube content, and the answer is pretty straight forward. Yes there would be a lot less videos, maybe one video per weekend with some exceptions now and then. I would still be reviewing other boards and non-96boards related content as well and promise to not let my position influence my reviews.

As for whats up next, today I will leave for San Francisco to attend Linaro Connect and hope to bring some great content and (V)(B)logs from the event, If you are visiting as well, hope to meet you at connect !

Mainpage: https://fuchsia.googlesource.com/docs/+/master/book.md

Getting started https://fuchsia.googlesource.com/docs/+/master/getting_started.md

 

Transcript:

Welcome back everyone to another video, in this one we’ll be attempting to boot fuchsia os, or at least a part of it on an actual x86 PC based hardware. Fuchsia OS is still very much experimental at this stage, so expect more failures than success…

Before we get started I would like to give a shout out to sebe, who has on many occasions helped with Fuchsia and Magenta related issues…

So let’s get to it, there are some prerequisites before we get started, make sure that your fuchsia source is updated and you have completed the build for x86-64 target from the “getting started” guide. Once that is done, insert the usb drive that you want t make bootable while in the working directory execute the usb gigaboot build script inside the scripts folder.

This script has three options, one of which allows you to either use a basic magenta kernel based os without most of the Fuchsia functionality, we’ll look into it later on. Upon execution of the script, it will start to compile a few source files and after that it will ask the usb drive that is to be used to boot the OS, type the device name while making sure that you adhere to all the warnings as all of the data on the selected device will be wiped clean.

Once that is done the script will continue to write files to the USB drive, after it has completed the process it will automatically unmount the drive.

Finally now we can boot from the drive.

Here how it went for me, I didn’t boot at all on my laptop that is running on a pentium 3805U CPU, next the gigaboot bootloader booted fine on the same laptop but with a celeron based processor but failed to boot fuchsia or even just the magenta kernel.

Finally I tried it on the UP board that is running atom x5-z8350, which didn’t boot the full fuchsia os but was able to run the command line shell with the magenta kernel just fine…

And once again, this os is very experimental and supports a very small amount of intel hd gpu’s to display the GUI. and I can’t guarantee success as much as I can guarantee failure, but it’s still a fun experiment to do and just test what all hardware in your home or work is compatible with running the Fuchsia OS !!!

With that, I hope you enjoyed the show, thanks for liking sharing and subscribing and i’ll see you all in the next one.

Raspberry Pi 3 VideoCore 4

=======================================================
    glmark2 2014.03
=======================================================
    OpenGL Information
    GL_VENDOR:     Broadcom
    GL_RENDERER:   Gallium 0.4 on VC4 V3D 2.1
    GL_VERSION:    OpenGL ES 2.0 Mesa 13.0.0
=======================================================
[build] use-vbo=false: FPS: 127 FrameTime: 7.874 ms
[build] use-vbo=true: FPS: 136 FrameTime: 7.353 ms
[texture] texture-filter=nearest: FPS: 134 FrameTime: 7.463 ms
[texture] texture-filter=linear: FPS: 131 FrameTime: 7.634 ms
[texture] texture-filter=mipmap: FPS: 123 FrameTime: 8.130 ms
[shading] shading=gouraud: FPS: 122 FrameTime: 8.197 ms
[shading] shading=blinn-phong-inf: FPS: 121 FrameTime: 8.264 ms
[shading] shading=phong: FPS: 114 FrameTime: 8.772 ms
[shading] shading=cel: FPS: 112 FrameTime: 8.929 ms
[bump] bump-render=high-poly: FPS: 76 FrameTime: 13.158 ms
[bump] bump-render=normals: FPS: 135 FrameTime: 7.407 ms
[bump] bump-render=height: FPS: 133 FrameTime: 7.519 ms
[effect2d] kernel=0,1,0;1,-4,1;0,1,0;: FPS: 90 FrameTime: 11.111 ms
[effect2d] kernel=1,1,1,1,1;1,1,1,1,1;1,1,1,1,1;: FPS: 63 FrameTime: 15.873 ms
[pulsar] light=false:quads=5:texture=false: FPS: 136 FrameTime: 7.353 ms
[desktop] blur-radius=5:effect=blur:passes=1:separable=true:windows=4: FPS: 40 FrameTime: 25.000 ms
[desktop] effect=shadow:windows=4: FPS: 80 FrameTime: 12.500 ms
[buffer] columns=200:interleave=false:update-dispersion=0.9:update-fraction=0.5:update-method=map: FPS: 57 FrameTime: 17.544 ms
[buffer] columns=200:interleave=false:update-dispersion=0.9:update-fraction=0.5:update-method=subdata: FPS: 56 FrameTime: 17.857 ms
[buffer] columns=200:interleave=true:update-dispersion=0.9:update-fraction=0.5:update-method=map: FPS: 66 FrameTime: 15.152 ms
[ideas] speed=duration: FPS: 137 FrameTime: 7.299 ms
[jellyfish] : FPS: 89 FrameTime: 11.236 ms
[terrain] : FPS: 5 FrameTime: 200.000 ms
[shadow] : FPS: 76 FrameTime: 13.158 ms
[refract] : FPS: 21 FrameTime: 47.619 ms
[conditionals] fragment-steps=0:vertex-steps=0: FPS: 144 FrameTime: 6.944 ms
[conditionals] fragment-steps=5:vertex-steps=0: FPS: 113 FrameTime: 8.850 ms
[conditionals] fragment-steps=0:vertex-steps=5: FPS: 141 FrameTime: 7.092 ms
[function] fragment-complexity=low:fragment-steps=5: FPS: 128 FrameTime: 7.812 ms
[function] fragment-complexity=medium:fragment-steps=5: FPS: 96 FrameTime: 10.417 ms
[loop] fragment-loop=false:fragment-steps=5:vertex-steps=5: FPS: 125 FrameTime: 8.000 ms
[loop] fragment-steps=5:fragment-uniform=false:vertex-steps=5: FPS: 125 FrameTime: 8.000 ms
[loop] fragment-steps=5:fragment-uniform=true:vertex-steps=5: FPS: 81 FrameTime: 12.346 ms
=======================================================
                                  glmark2 Score: 101 
=======================================================

 

Banana Pi M1 Mali 400 MP2

=======================================================
    glmark2 2014.03+git20150611.fa71af2d
=======================================================
    OpenGL Information
    GL_VENDOR:     ARM
    GL_RENDERER:   Mali-400 MP
    GL_VERSION:    OpenGL ES 2.0
=======================================================
[build] use-vbo=false: FPS: 74 FrameTime: 13.514 ms
[build] use-vbo=true: FPS: 77 FrameTime: 12.987 ms
[texture] texture-filter=nearest: FPS: 84 FrameTime: 11.905 ms
[texture] texture-filter=linear: FPS: 83 FrameTime: 12.048 ms
[texture] texture-filter=mipmap: FPS: 84 FrameTime: 11.905 ms
[shading] shading=gouraud: FPS: 74 FrameTime: 13.514 ms
[shading] shading=blinn-phong-inf: FPS: 74 FrameTime: 13.514 ms
[shading] shading=phong: FPS: 73 FrameTime: 13.699 ms
[shading] shading=cel: FPS: 65 FrameTime: 15.385 ms
[bump] bump-render=high-poly: FPS: 54 FrameTime: 18.519 ms
[bump] bump-render=normals: FPS: 86 FrameTime: 11.628 ms
[bump] bump-render=height: FPS: 90 FrameTime: 11.111 ms
[effect2d] kernel=0,1,0;1,-4,1;0,1,0;: FPS: 32 FrameTime: 31.250 ms
[effect2d] kernel=1,1,1,1,1;1,1,1,1,1;1,1,1,1,1;: FPS: 20 FrameTime: 50.000 ms
[pulsar] light=false:quads=5:texture=false: FPS: 92 FrameTime: 10.870 ms
[desktop] blur-radius=5:effect=blur:passes=1:separable=true:windows=4: FPS: 16 FrameTime: 62.500 ms
[desktop] effect=shadow:windows=4: FPS: 48 FrameTime: 20.833 ms
[buffer] columns=200:interleave=false:update-dispersion=0.9:update-fraction=0.5:update-method=map: Unsupported
[buffer] columns=200:interleave=false:update-dispersion=0.9:update-fraction=0.5:update-method=subdata: FPS: 39 FrameTime: 25.641 ms
[buffer] columns=200:interleave=true:update-dispersion=0.9:update-fraction=0.5:update-method=map: Unsupported
[ideas] speed=duration: FPS: 74 FrameTime: 13.514 ms
[jellyfish] : FPS: 47 FrameTime: 21.277 ms
[terrain] : Unsupported
[shadow] : FPS: 25 FrameTime: 40.000 ms
[refract] : FPS: 15 FrameTime: 66.667 ms
[conditionals] fragment-steps=0:vertex-steps=0: FPS: 89 FrameTime: 11.236 ms
[conditionals] fragment-steps=5:vertex-steps=0: FPS: 60 FrameTime: 16.667 ms
[conditionals] fragment-steps=0:vertex-steps=5: FPS: 90 FrameTime: 11.111 ms
[function] fragment-complexity=low:fragment-steps=5: FPS: 75 FrameTime: 13.333 ms
[function] fragment-complexity=medium:fragment-steps=5: FPS: 46 FrameTime: 21.739 ms
[loop] fragment-loop=false:fragment-steps=5:vertex-steps=5: FPS: 76 FrameTime: 13.158 ms
[loop] fragment-steps=5:fragment-uniform=false:vertex-steps=5: FPS: 75 FrameTime: 13.333 ms
[loop] fragment-steps=5:fragment-uniform=true:vertex-steps=5: FPS: 75 FrameTime: 13.333 ms
=======================================================
                                  glmark2 Score: 63 
=======================================================

 

Raspberry Pi 3:

=======================================================
    glmark2 2014.03
=======================================================
    OpenGL Information
    GL_VENDOR:     Broadcom
    GL_RENDERER:   Gallium 0.4 on VC4 V3D 2.1
    GL_VERSION:    OpenGL ES 2.0 Mesa 13.0.0
=======================================================
[build] use-vbo=false: FPS: 127 FrameTime: 7.874 ms
[build] use-vbo=true: FPS: 136 FrameTime: 7.353 ms
[texture] texture-filter=nearest: FPS: 134 FrameTime: 7.463 ms
[texture] texture-filter=linear: FPS: 131 FrameTime: 7.634 ms
[texture] texture-filter=mipmap: FPS: 123 FrameTime: 8.130 ms
[shading] shading=gouraud: FPS: 122 FrameTime: 8.197 ms
[shading] shading=blinn-phong-inf: FPS: 121 FrameTime: 8.264 ms
[shading] shading=phong: FPS: 114 FrameTime: 8.772 ms
[shading] shading=cel: FPS: 112 FrameTime: 8.929 ms
[bump] bump-render=high-poly: FPS: 76 FrameTime: 13.158 ms
[bump] bump-render=normals: FPS: 135 FrameTime: 7.407 ms
[bump] bump-render=height: FPS: 133 FrameTime: 7.519 ms
[effect2d] kernel=0,1,0;1,-4,1;0,1,0;: FPS: 90 FrameTime: 11.111 ms
[effect2d] kernel=1,1,1,1,1;1,1,1,1,1;1,1,1,1,1;: FPS: 63 FrameTime: 15.873 ms
[pulsar] light=false:quads=5:texture=false: FPS: 136 FrameTime: 7.353 ms
[desktop] blur-radius=5:effect=blur:passes=1:separable=true:windows=4: FPS: 40 FrameTime: 25.000 ms
[desktop] effect=shadow:windows=4: FPS: 80 FrameTime: 12.500 ms
[buffer] columns=200:interleave=false:update-dispersion=0.9:update-fraction=0.5:update-method=map: FPS: 57 FrameTime: 17.544 ms
[buffer] columns=200:interleave=false:update-dispersion=0.9:update-fraction=0.5:update-method=subdata: FPS: 56 FrameTime: 17.857 ms
[buffer] columns=200:interleave=true:update-dispersion=0.9:update-fraction=0.5:update-method=map: FPS: 66 FrameTime: 15.152 ms
[ideas] speed=duration: FPS: 137 FrameTime: 7.299 ms
[jellyfish] : FPS: 89 FrameTime: 11.236 ms
[terrain] : FPS: 5 FrameTime: 200.000 ms
[shadow] : FPS: 76 FrameTime: 13.158 ms
[refract] : FPS: 21 FrameTime: 47.619 ms
[conditionals] fragment-steps=0:vertex-steps=0: FPS: 144 FrameTime: 6.944 ms
[conditionals] fragment-steps=5:vertex-steps=0: FPS: 113 FrameTime: 8.850 ms
[conditionals] fragment-steps=0:vertex-steps=5: FPS: 141 FrameTime: 7.092 ms
[function] fragment-complexity=low:fragment-steps=5: FPS: 128 FrameTime: 7.812 ms
[function] fragment-complexity=medium:fragment-steps=5: FPS: 96 FrameTime: 10.417 ms
[loop] fragment-loop=false:fragment-steps=5:vertex-steps=5: FPS: 125 FrameTime: 8.000 ms
[loop] fragment-steps=5:fragment-uniform=false:vertex-steps=5: FPS: 125 FrameTime: 8.000 ms
[loop] fragment-steps=5:fragment-uniform=true:vertex-steps=5: FPS: 81 FrameTime: 12.346 ms
=======================================================
                                  glmark2 Score: 101 
=======================================================

 

DragonBoard 410c

=======================================================
    glmark2 2017.07
=======================================================
    OpenGL Information
    GL_VENDOR:     freedreno
    GL_RENDERER:   Gallium 0.4 on FD307
    GL_VERSION:    OpenGL ES 3.0 Mesa 13.0.6
=======================================================
[build] use-vbo=false: FPS: 194 FrameTime: 5.155 ms
[build] use-vbo=true: FPS: 207 FrameTime: 4.831 ms
[texture] texture-filter=nearest: FPS: 162 FrameTime: 6.173 ms
[texture] texture-filter=linear: FPS: 151 FrameTime: 6.623 ms
[texture] texture-filter=mipmap: FPS: 156 FrameTime: 6.410 ms
[shading] shading=gouraud: FPS: 188 FrameTime: 5.319 ms
[shading] shading=blinn-phong-inf: FPS: 163 FrameTime: 6.135 ms
[shading] shading=phong: FPS: 130 FrameTime: 7.692 ms
[shading] shading=cel: FPS: 118 FrameTime: 8.475 ms
[bump] bump-render=high-poly: FPS: 132 FrameTime: 7.576 ms
[bump] bump-render=normals: FPS: 178 FrameTime: 5.618 ms
[bump] bump-render=height: FPS: 149 FrameTime: 6.711 ms
libpng warning: iCCP: known incorrect sRGB profile
[effect2d] kernel=0,1,0;1,-4,1;0,1,0;: FPS: 65 FrameTime: 15.385 ms
libpng warning: iCCP: known incorrect sRGB profile
[effect2d] kernel=1,1,1,1,1;1,1,1,1,1;1,1,1,1,1;: FPS: 17 FrameTime: 58.824 ms
[pulsar] light=false:quads=5:texture=false: FPS: 179 FrameTime: 5.587 ms
libpng warning: iCCP: known incorrect sRGB profile
[desktop] blur-radius=5:effect=blur:passes=1:separable=true:windows=4: FPS: 28 FrameTime: 35.714 ms
libpng warning: iCCP: known incorrect sRGB profile
[desktop] effect=shadow:windows=4: FPS: 92 FrameTime: 10.870 ms
[buffer] columns=200:interleave=false:update-dispersion=0.9:update-fraction=0.5:update-method=map: FPS: 68 FrameTime: 14.706 ms
[buffer] columns=200:interleave=false:update-dispersion=0.9:update-fraction=0.5:update-method=subdata: FPS: 67 FrameTime: 14.925 ms
[buffer] columns=200:interleave=true:update-dispersion=0.9:update-fraction=0.5:update-method=map: FPS: 85 FrameTime: 11.765 ms
[ideas] speed=duration: FPS: 66 FrameTime: 15.152 ms
[jellyfish] : FPS: 64 FrameTime: 15.625 ms
[terrain] : FPS: 3 FrameTime: 333.333 ms
[shadow] : FPS: 56 FrameTime: 17.857 ms
[refract] : FPS: 22 FrameTime: 45.455 ms
[conditionals] fragment-steps=0:vertex-steps=0: FPS: 174 FrameTime: 5.747 ms
[conditionals] fragment-steps=5:vertex-steps=0: FPS: 110 FrameTime: 9.091 ms
[conditionals] fragment-steps=0:vertex-steps=5: FPS: 169 FrameTime: 5.917 ms
[function] fragment-complexity=low:fragment-steps=5: FPS: 142 FrameTime: 7.042 ms
[function] fragment-complexity=medium:fragment-steps=5: FPS: 120 FrameTime: 8.333 ms
[loop] fragment-loop=false:fragment-steps=5:vertex-steps=5: FPS: 136 FrameTime: 7.353 ms
[loop] fragment-steps=5:fragment-uniform=false:vertex-steps=5: FPS: 136 FrameTime: 7.353 ms
[loop] fragment-steps=5:fragment-uniform=true:vertex-steps=5: FPS: 96 FrameTime: 10.417 ms
=======================================================
                                  glmark2 Score: 115 
=======================================================