mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-06 13:48:06 +02:00
jay/ra: drop memory copy reordering
No shader-db changes, and no longer required for correctness. Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@intel.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/41064>
This commit is contained in:
parent
45845ea7f2
commit
1f62da938b
1 changed files with 6 additions and 20 deletions
|
|
@ -642,33 +642,19 @@ jay_emit_parallel_copies(jay_builder *b,
|
|||
/* Emit moves after swaps because they fan out and thus increase demand.
|
||||
* This gives us more freedom around temporaries. The rewrite of simple
|
||||
* copies above ensures correctness.
|
||||
*
|
||||
* Simiarly, we first emit memory-memory copies since those require
|
||||
* temporaries but only register copies can clobber the temporaries.
|
||||
*/
|
||||
for (unsigned i = 0; i < num_simple; i++) {
|
||||
jay_def dst = def_from_reg(simple[i].dst);
|
||||
jay_def src = def_from_reg(simple[i].src);
|
||||
|
||||
if (jay_is_mem(dst) && jay_is_mem(src)) {
|
||||
mov(b, dst, src, temps);
|
||||
mov(b, dst, src, temps);
|
||||
|
||||
if (temps.gpr == simple[i].dst || temps.gpr == simple[i].src) {
|
||||
temps.gpr = NO_REG;
|
||||
}
|
||||
}
|
||||
|
||||
for (unsigned i = 0; i < num_simple; i++) {
|
||||
jay_def dst = def_from_reg(simple[i].dst);
|
||||
jay_def src = def_from_reg(simple[i].src);
|
||||
|
||||
if (!(jay_is_mem(dst) && jay_is_mem(src))) {
|
||||
mov(b, dst, src, temps);
|
||||
|
||||
if (temps.gpr == simple[i].dst || temps.gpr == simple[i].src) {
|
||||
temps.gpr = NO_REG;
|
||||
}
|
||||
|
||||
if (temps.ugpr == simple[i].dst || temps.ugpr == simple[i].src) {
|
||||
temps.ugpr = NO_REG;
|
||||
}
|
||||
if (temps.ugpr == simple[i].dst || temps.ugpr == simple[i].src) {
|
||||
temps.ugpr = NO_REG;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue