diff options
author | Kenneth Graunke <[email protected]> | 2018-12-03 22:26:47 -0800 |
---|---|---|
committer | Kenneth Graunke <[email protected]> | 2018-12-21 15:29:25 -0800 |
commit | ed1a356c5e21a8d19287fea2512d3b3a82171e9f (patch) | |
tree | 9cdc82a30096c0e474503b20401b07d99b5d3e14 /scons/llvm.py | |
parent | 42d31e0516d64bca45a45f73e6a2f7f40e6daa4b (diff) |
st/mesa: Drop !passColor optimization in drawpixels shaders.
The glDrawPixels passthrough vertex shader copies position and texcoord
vertex attributes to varying outputs. It also optionally copies a third
gl_Color attribute, which sometimes is unnecessary. Until now, we've
compiled separate variants of the shader, one of which does this extra
copy, and the other of which doesn't. We have done this since 2007.
But, the vertex shader runs for a whopping four vertices, and so the
cost of a copying a single input to output is likely inconsequential.
In theory, we could bind one fewer vertex element - but we always bind
all three regardless. So, we don't even get that savings.
This patch unifies the two, so we always copy the optional color,
and save having to compile the variant. It also makes the VS input
interface match up with the vertex element state without any dead
(unused) input attributes.
Reviewed-by: Marek Olšák <[email protected]>
Diffstat (limited to 'scons/llvm.py')
0 files changed, 0 insertions, 0 deletions