mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-05 03:08:05 +02:00
broadcom/compiler: disallow unifa overlap with thread switch/end
Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8980>
This commit is contained in:
parent
24db1a5112
commit
97c078488f
1 changed files with 17 additions and 0 deletions
|
|
@ -1217,6 +1217,23 @@ valid_thrsw_sequence(struct v3d_compile *c, struct choose_scoreboard *scoreboard
|
|||
return false;
|
||||
}
|
||||
|
||||
/* unifa and the following 3 instructions can't overlap a
|
||||
* thread switch/end. The docs further clarify that this means
|
||||
* the cycle at which the actual thread switch/end happens
|
||||
* and not when the thrsw instruction is processed, which would
|
||||
* be after the 2 delay slots following the thrsw instruction.
|
||||
* This means that we can move up a thrsw up to the instruction
|
||||
* right after unifa:
|
||||
*
|
||||
* unifa, r5
|
||||
* thrsw
|
||||
* delay slot 1
|
||||
* delay slot 2
|
||||
* Thread switch happens here, 4 instructions away from unifa
|
||||
*/
|
||||
if (v3d_qpu_writes_unifa(c->devinfo, &qinst->qpu))
|
||||
return false;
|
||||
|
||||
/* Note that the list is circular, so we can only do this up
|
||||
* to instructions_in_sequence.
|
||||
*/
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue