<div dir="ltr">Hi all,<div><br></div><div>Is there a way to see the machine code that is generated by the GLSL compiler for all GPU instruction sets? For example, I would like to know if the optimizer optimizes certain (equivalent) constructs (or not), and avoid them if possible. I know there is a lot to optimization on GPUs that I don't know, but I'd still like to get some ballpark estimates. For example, I'm curious whether:</div>
<div><br></div><div>    //let p1, p2, p3 be vec2 uniforms</div><div><br></div><div>    vec4(p1, 0, 0) + vec4(p2, 0, 0) + vec4(p3, 0, 1)</div><div><br></div><div>produces identical machine code as:</div><div><br></div><div>
    vec4(p1+p2+p3, 0, 1);</div><div><br></div><div>for all architectures supported by Mesa.</div></div>