mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-08 15:38:09 +02:00
aco/ra: use get_reg_specified() for p_extract_vector
On GFX6/7, it might violate validation rules, otherwise. Fixes:51f4b22fee('aco: don't allow unaligned subdword accesses on GFX6/7') Reviewed-by: Rhys Perry <pendingchaos02@gmail.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8047> (cherry picked from commitfd49ba59a3)
This commit is contained in:
parent
07562fcf66
commit
69dd154c27
2 changed files with 4 additions and 8 deletions
|
|
@ -40,7 +40,7 @@
|
|||
"description": "aco/ra: use get_reg_specified() for p_extract_vector",
|
||||
"nominated": true,
|
||||
"nomination_type": 1,
|
||||
"resolution": 0,
|
||||
"resolution": 1,
|
||||
"master_sha": null,
|
||||
"because_sha": "51f4b22feec3720c89458094a3245efc984115ee"
|
||||
},
|
||||
|
|
|
|||
|
|
@ -2201,14 +2201,10 @@ void register_allocation(Program *program, std::vector<TempSet>& live_out_per_bl
|
|||
!register_file.test(reg, definition->bytes()))
|
||||
definition->setFixed(reg);
|
||||
} else if (instr->opcode == aco_opcode::p_extract_vector) {
|
||||
PhysReg reg;
|
||||
if (instr->operands[0].isKillBeforeDef() &&
|
||||
instr->operands[0].getTemp().type() == definition->getTemp().type()) {
|
||||
reg = instr->operands[0].physReg();
|
||||
reg.reg_b += definition->bytes() * instr->operands[1].constantValue();
|
||||
assert(!register_file.test(reg, definition->bytes()));
|
||||
PhysReg reg = instr->operands[0].physReg();
|
||||
reg.reg_b += definition->bytes() * instr->operands[1].constantValue();
|
||||
if (get_reg_specified(ctx, register_file, definition->regClass(), parallelcopy, instr, reg))
|
||||
definition->setFixed(reg);
|
||||
}
|
||||
} else if (instr->opcode == aco_opcode::p_create_vector) {
|
||||
PhysReg reg = get_reg_create_vector(ctx, register_file, definition->getTemp(),
|
||||
parallelcopy, instr);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue