mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-08 11:18:08 +02:00
nir/loop_unroll: Update the comments for loop_prepare_for_unroll
The comments say that we should remove continue if it is the last intruction in a loop however we remove any kind of jump. Signed-off-by: Danylo Piliaiev <danylo.piliaiev@globallogic.com> Reviewed-by: Timothy Arceri <tarceri@itsqueeze.com>
This commit is contained in:
parent
e04761d0f9
commit
8869f44e9a
1 changed files with 2 additions and 2 deletions
|
|
@ -42,7 +42,7 @@
|
|||
* to keep track of and update phis along the way which gets tricky and
|
||||
* doesn't add much value over converting to regs.
|
||||
*
|
||||
* The loop may have a continue instruction at the end of the loop which does
|
||||
* The loop may have a jump instruction at the end of the loop which does
|
||||
* nothing. Once we're out of SSA, we can safely delete it so we don't have
|
||||
* to deal with it later.
|
||||
*/
|
||||
|
|
@ -67,7 +67,7 @@ loop_prepare_for_unroll(nir_loop *loop)
|
|||
|
||||
nir_lower_phis_to_regs_block(block_after_loop);
|
||||
|
||||
/* Remove continue if its the last instruction in the loop */
|
||||
/* Remove jump if it's the last instruction in the loop */
|
||||
nir_instr *last_instr = nir_block_last_instr(nir_loop_last_block(loop));
|
||||
if (last_instr && last_instr->type == nir_instr_type_jump) {
|
||||
nir_instr_remove(last_instr);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue