mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-07 09:18:04 +02:00
i965/fs: Fix a bug with dead_code_eliminate on large writes
Previously, if an instruction wrote to more than one register, we implicitly assumed that it filled the entire register. We never hit this before because the only time we did multi-register writes was things like texturing which always wrote to all of the registers. However, with the upcoming ability to do 16-wide instructions in SIMD8 and things of that nature, we can have multi-register writes at offsets and we'll hit this. Signed-off-by: Jason Ekstrand <jason.ekstrand@intel.com> Reviewed-by: Matt Turner <mattst88@gmail.com>
This commit is contained in:
parent
1385a4b706
commit
c24dd54f97
1 changed files with 1 additions and 1 deletions
|
|
@ -58,7 +58,7 @@ fs_visitor::dead_code_eliminate()
|
|||
int var = live_intervals->var_from_reg(&inst->dst);
|
||||
result_live = BITSET_TEST(live, var);
|
||||
} else {
|
||||
int var = live_intervals->var_from_vgrf[inst->dst.reg];
|
||||
int var = live_intervals->var_from_reg(&inst->dst);
|
||||
for (int i = 0; i < inst->regs_written; i++) {
|
||||
result_live = result_live || BITSET_TEST(live, var + i);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue