mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-07 17:58:26 +02:00
i965: Copy propagate before doing variable index lowering.
The scalar backend currently doesn't support variable indexing on
temporary arrays, but it does support it on uniform arrays, and
some stages support it for input arrays. Make sure these are
propagated through before exploding indirects into piles of
if-ladders unnecessarily.
On Broadwell, no instruction count change in shader-db.
total cycles in shared programs: 80675652 -> 80674928 (-0.00%)
cycles in affected programs: 649972 -> 649248 (-0.11%)
helped: 386
HURT: 165
This will help avoid code quality regressions in a future commit.
Cc: mesa-stable@lists.freedesktop.org
Signed-off-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Timothy Arceri <timothy.arceri@collabora.com>
(cherry picked from commit f7741c5211)
This commit is contained in:
parent
32bb867118
commit
335193107a
1 changed files with 2 additions and 0 deletions
|
|
@ -130,6 +130,8 @@ process_glsl_ir(gl_shader_stage stage,
|
|||
lower_noise(shader->ir);
|
||||
lower_quadop_vector(shader->ir, false);
|
||||
|
||||
do_copy_propagation(shader->ir);
|
||||
|
||||
bool lowered_variable_indexing =
|
||||
lower_variable_index_to_cond_assign((gl_shader_stage)stage,
|
||||
shader->ir,
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue