intel/compiler: Handle split-sends in EOT high-register pinning case
SEND messages with EOT need to use g112-g127 for their sources so that the hardware is able to launch new threads while old ones are finishing without worrying about register overlap when pushing payloads. For the newer split-send messages, this applies to both source registers. Our special case for this in the register allocator was only considering the first source. This wasn't a problem because we hadn't ever tried to use split-sends with EOT before. However, my new optimization pass is going to introduce some shortly, so we'll need to handle them properly. Reviewed-by: Francisco Jerez <currojerez@riseup.net> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17018>
This commit is contained in:
parent
68642e2c26
commit
a8b93e628a
|
@ -614,8 +614,7 @@ fs_reg_alloc::setup_inst_interference(const fs_inst *inst)
|
|||
if (inst->eot) {
|
||||
const int vgrf = inst->opcode == SHADER_OPCODE_SEND ?
|
||||
inst->src[2].nr : inst->src[0].nr;
|
||||
int size = fs->alloc.sizes[vgrf];
|
||||
int reg = BRW_MAX_GRF - size;
|
||||
int reg = BRW_MAX_GRF - fs->alloc.sizes[vgrf];
|
||||
|
||||
if (first_mrf_hack_node >= 0) {
|
||||
/* If something happened to spill, we want to push the EOT send
|
||||
|
@ -631,6 +630,12 @@ fs_reg_alloc::setup_inst_interference(const fs_inst *inst)
|
|||
}
|
||||
|
||||
ra_set_node_reg(g, first_vgrf_node + vgrf, reg);
|
||||
|
||||
if (inst->ex_mlen > 0) {
|
||||
const int vgrf = inst->src[3].nr;
|
||||
reg -= fs->alloc.sizes[vgrf];
|
||||
ra_set_node_reg(g, first_vgrf_node + vgrf, reg);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue