Hi guys,
I write a TAA shader in unity,I try to optimization this shader,change some float to half.
then I compare the shader brfore and after with mali offline compiler
Mali-G76 before,no spilling
Mali-G76 after,spilling
Mali-G77 before,spilling
Mali-G77 after,no spilling
2 questions:
1.Why the results of Mali-G76 and Mali-G77 are opposite
2.Why do I reduce the calculation precision, but it spilling on Mali-G76
5756.shader.zip
Nothing obvious jumps out as a quick fix - the shader is just very complex and uses a lot of variables and swizzles. Using mixed precision computation will require more casting and fp16 vec2 packing, so where possible try to compute an entire computation chain at either mediump or highp with minimal precision changes.
Newer drivers have solved the spilling in the original shader for Mali-G77, but the latest driver still spills in the shader with reduced precision for Mali-G76.
Thank you,I will try to use full highp on Mali-G76