mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-04-22 05:20:37 +02:00
mesa: Fix remove_instructions to successfully remove when removeFlags[0].
This fixes the dead code elimination to work on the particular code mentioned in the previous commit.
This commit is contained in:
parent
e4e312d493
commit
f3cacfe216
1 changed files with 6 additions and 0 deletions
|
|
@ -73,6 +73,12 @@ remove_instructions(struct gl_program *prog, const GLboolean *removeFlags)
|
|||
}
|
||||
}
|
||||
}
|
||||
/* Finish removing if the first instruction was to be removed. */
|
||||
if (removeCount > 0) {
|
||||
GLint removeStart = removeEnd - removeCount + 1;
|
||||
_mesa_delete_instructions(prog, removeStart, removeCount);
|
||||
removeStart = removeCount = 0; /* reset removal info */
|
||||
}
|
||||
return totalRemoved;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue