nir/sink: Rewrite loop handling logic
Previously, for code like: loop { loop { a = load_ubo() } use(a) } adjust_block_for_loops() would return the block before the first loop. Now we compute the range of allowed blocks and then walk the dominance tree directly, guaranteeing directly that we always choose a block that dominates all the uses and is dominated by the definition. Reviewed-by:Daniel Schürmann <daniel@schuermann.dev> (cherry picked from commit af9296b8)
Loading
Please register or sign in to comment