mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-04 20:38:06 +02:00
i965: Fix ENDLOOP to only patch up this loop's BREAK and CONT.
Corresponds to d225a25e21a24508aea3b877c78beb35502e942d and fixes
piglit glsl-fs-loop-nested. Bug #25173.
(cherry picked from commit a81836ee2f)
This commit is contained in:
parent
42e0e86866
commit
a29c7948d9
1 changed files with 4 additions and 2 deletions
|
|
@ -2015,11 +2015,13 @@ static void brw_wm_emit_glsl(struct brw_context *brw, struct brw_wm_compile *c)
|
|||
/* patch all the BREAK/CONT instructions from last BGNLOOP */
|
||||
while (inst0 > loop_inst[loop_depth]) {
|
||||
inst0--;
|
||||
if (inst0->header.opcode == BRW_OPCODE_BREAK) {
|
||||
if (inst0->header.opcode == BRW_OPCODE_BREAK &&
|
||||
inst0->bits3.if_else.jump_count == 0) {
|
||||
inst0->bits3.if_else.jump_count = br * (inst1 - inst0 + 1);
|
||||
inst0->bits3.if_else.pop_count = 0;
|
||||
}
|
||||
else if (inst0->header.opcode == BRW_OPCODE_CONTINUE) {
|
||||
else if (inst0->header.opcode == BRW_OPCODE_CONTINUE &&
|
||||
inst0->bits3.if_else.jump_count == 0) {
|
||||
inst0->bits3.if_else.jump_count = br * (inst1 - inst0);
|
||||
inst0->bits3.if_else.pop_count = 0;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue