Hi all:
I got the following result by compiling a opencl program. I do not know what is "work registers" and "uniform registers". Mali T600 a register bank that contains 1024 registers. Are the 1024 registers the sum of "wor resigters" and "uniform registers" ?
Thank you
-Jack
---------------------------------------------------------------------------
ARM Mali Offline Compiler v5.7.0(C) Copyright 2007-2017 ARM Limited.All rights reserved.7 work registers used, 5 uniform registers used, spilling not used. A L/S T BoundInstructions Emitted: 20 10 2 AShortest Path Cycles: 2 2 0 A, L/SLongest Path Cycles: N/A N/A N/A N/AA = Arithmetic, L/S = Load/Store, T = TextureNote: The cycles counts do not include possible stalls due to cache misses.Note: Shaders with loops may return "N/A" for cycle counts if the number of cycles cannot be statically determined.
There are 1024 work registers, which are allocated to the running threads. Single threads can either be allocated either 4, 8, or 16 registers.
Uniform registers are an independent resource, with typically up to 16 available to a single shader program (shared across all threads in that draw call or compute dispatch).
HTH, Pete
Would an actually used GLES shader vec4 rougly equates to, at least, 4 work registers used ?
One work register is 128-bit on Midgard. You can fit a highp vec4 in a single work register.
Thanks for the information !
Does that mean that breaking up the single register, like shoe-honing two vec2 into one vec4 and then using these two parts (xy and zw) for completely different operations, is a big no-no in term of registers use ?
Multiple variables can share the same working register. Two mediump vec4s can use one working register.
Packing two vec2s into a vec4 and swizzling them should not affect register usage.
Alright. I'll continue using this technique then