mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-06 11:38:05 +02:00
broadcom/compiler: don't favor/select accum registers for hw not supporting it
Note that what we do is to just return false on the favor/select accum methods. We could just avoid to call them, but as the select is called more than once, it is just easier this way. Reviewed-by: Iago Toral Quiroga <itoral@igalia.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/25450>
This commit is contained in:
parent
1260b202be
commit
d00f7ef23e
1 changed files with 6 additions and 0 deletions
|
|
@ -797,6 +797,9 @@ v3d_ra_favor_accum(struct v3d_ra_select_callback_data *v3d_ra,
|
||||||
BITSET_WORD *regs,
|
BITSET_WORD *regs,
|
||||||
int priority)
|
int priority)
|
||||||
{
|
{
|
||||||
|
if (!v3d_ra->devinfo->has_accumulators)
|
||||||
|
return false;
|
||||||
|
|
||||||
/* Favor accumulators if we have less that this number of physical
|
/* Favor accumulators if we have less that this number of physical
|
||||||
* registers. Accumulators have more restrictions (like being
|
* registers. Accumulators have more restrictions (like being
|
||||||
* invalidated through thrsw), so running out of physical registers
|
* invalidated through thrsw), so running out of physical registers
|
||||||
|
|
@ -832,6 +835,9 @@ v3d_ra_select_accum(struct v3d_ra_select_callback_data *v3d_ra,
|
||||||
BITSET_WORD *regs,
|
BITSET_WORD *regs,
|
||||||
unsigned int *out)
|
unsigned int *out)
|
||||||
{
|
{
|
||||||
|
if (!v3d_ra->devinfo->has_accumulators)
|
||||||
|
return false;
|
||||||
|
|
||||||
/* Choose r5 for our ldunifs if possible (nobody else can load to that
|
/* Choose r5 for our ldunifs if possible (nobody else can load to that
|
||||||
* reg, and it keeps the QPU cond field free from being occupied by
|
* reg, and it keeps the QPU cond field free from being occupied by
|
||||||
* ldunifrf).
|
* ldunifrf).
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue