Browse Source

i965/fs: Fix multiple ACP interference during copy propagation.

This is more fallout from cf375a3333.
It's possible for multiple ACP entries to interfere with a given VGRF
write, so we need to continue iterating even if an overlapping entry
has already been found.

Cc: Samuel Iglesias Gonsálvez <siglesias@igalia.com>
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
tags/12.0-branchpoint
Francisco Jerez 9 years ago
parent
commit
ad8f66ed33
1 changed files with 2 additions and 6 deletions
  1. 2
    6
      src/mesa/drivers/dri/i965/brw_fs_copy_propagation.cpp

+ 2
- 6
src/mesa/drivers/dri/i965/brw_fs_copy_propagation.cpp View File

@@ -758,10 +758,8 @@ fs_visitor::opt_copy_propagate_local(void *copy_prop_ctx, bblock_t *block,
if (inst->dst.file == VGRF) {
foreach_in_list_safe(acp_entry, entry, &acp[inst->dst.nr % ACP_HASH_SIZE]) {
if (regions_overlap(entry->dst, entry->regs_written,
inst->dst, inst->regs_written)) {
inst->dst, inst->regs_written))
entry->remove();
break;
}
}

/* Oops, we only have the chaining hash based on the destination, not
@@ -773,10 +771,8 @@ fs_visitor::opt_copy_propagate_local(void *copy_prop_ctx, bblock_t *block,
* _any_ of the registers that it reads
*/
if (regions_overlap(entry->src, entry->regs_read,
inst->dst, inst->regs_written)) {
inst->dst, inst->regs_written))
entry->remove();
continue;
}
}
}
}

Loading…
Cancel
Save