This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Mali Offline compiler GLSL clamp performance on Mali-Gxx

Hi,

Been doing some analysis on some GLSL shader programs with the Mali Offline Compiler, great program btw.

It is however reporting that a clamp (vec3,float,float) is somehow slower for the Mali-Gxx than doing a seperate min/max according the offline compiler.

vec3 clamp_minmax (vec3 val, float minimum, float maximum){
return clamp(val, minimum, maximum);
}

vs

vec3 clamp_minmax (vec3 val, float minimum, float maximum){
vec3 rval = min(val, maximum);
return max (rval, minimum);
}

Note that the minimum is a constant 0.0f.

Is this expected and correct for a Mali-Gxx ?

Parents
  • The absolute numbers for the G series are incorrect (at least for the arithmetic cost) - we'll be fixing this in the next offline compiler release later in the year. The trend direction in terms of is it getting faster or slower should be accurate though, to the best of my knowledge.

Reply
  • The absolute numbers for the G series are incorrect (at least for the arithmetic cost) - we'll be fixing this in the next offline compiler release later in the year. The trend direction in terms of is it getting faster or slower should be accurate though, to the best of my knowledge.

Children