I'm rendering some cubes via gpu instancing / compute shaders, and specifically on Samsung S7 Edge the more instances I add the more flickers I get. This is reproducible so far only on T880, other GPUs I've tried are good, including other Malis like G71.
Latest firmware, OpenGL ES 3.2 v1.r22p0-01rel0 driver.
I found the thread with almost the same problems on S7 as well, but GLES3.1 and supposed to be solved in r22 driver. I can't use GLES due to come compute shaders stuff not implemented and throwing an error, but otherwise it seems to be related issue: https://community.arm.com/developer/tools-software/graphics/f/discussions/10285/opengl-es-3-1-on-mali-t880-flashes/33025#33025
Please find the test APK here: drive.google.com/open
"Add prefabs" button adds 4096 instances and for me flickering starts around 16k instances and gets really, really bad after 32k.
Hi Wildman, The Galaxy S7 is running a very early Vulkan driver, so it's possible this is just a driver bug in the early drivers.
What is your total vertex count after instancing is applied?
One possibility is that Mali has a limited memory pool for post-transform memory - as a tile-based renderer all vertex shader outputs get written back to main memory before fragment shading. If you have a total vertex data requirement which is too high - either due to vertex count or data per vertex - then you can exceed the size of this data buffer. See this blog for details:https://community.arm.com/developer/tools-software/graphics/b/blog/posts/memory-limits-with-vulkan-on-mali-gpus
Thank you Pete,
I'm instancing up to 100k cubes, 8 verts per each, while staying above 30fps. But occasional flicker starts much earlier, at around 16k cubes. Checking out the blog posts!
Thanks. That doesn't sound too high unless you have an awful lot of data per vertex (post-transform space is normally > 128MB on the early drivers), so for ~ 1 million verts you should have 128 bytes per vertex which should be plenty.
It's barebones untextured, fixed color cubes. No vertex data whatsoever besides the position.
View all questions in Graphics and Gaming forum