aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorRhys Perry <[email protected]>2020-04-27 20:28:41 +0100
committerMarge Bot <[email protected]>2020-04-28 23:16:55 +0000
commit99ca96fbf58975d49e4ad131f907c5b01e12db85 (patch)
treee9771f457669073615f34cc6e372b049fcc41a7d /src
parent24116a8a561ffce9d55ab3b930d9c7648eda9cbb (diff)
aco: improve RA for uneven p_split_vector
Signed-off-by: Rhys Perry <[email protected]> Reviewed-by: Daniel Schürmann <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4772>
Diffstat (limited to 'src')
-rw-r--r--src/amd/compiler/aco_register_allocation.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/amd/compiler/aco_register_allocation.cpp b/src/amd/compiler/aco_register_allocation.cpp
index 42a4dcbcebf..e702e09059d 100644
--- a/src/amd/compiler/aco_register_allocation.cpp
+++ b/src/amd/compiler/aco_register_allocation.cpp
@@ -1832,7 +1832,8 @@ void register_allocation(Program *program, std::vector<TempSet>& live_out_per_bl
definition.setFixed(definition.physReg());
else if (instr->opcode == aco_opcode::p_split_vector) {
PhysReg reg = instr->operands[0].physReg();
- reg.reg_b += i * definition.bytes();
+ for (unsigned j = 0; j < i; j++)
+ reg.reg_b += instr->definitions[j].bytes();
if (get_reg_specified(ctx, register_file, definition.regClass(), parallelcopy, instr, reg))
definition.setFixed(reg);
} else if (instr->opcode == aco_opcode::p_wqm) {