[llvm] [CodeGen] MachineLICM: Do not consider "loop liveins" as loop defs (PR #121769)

Jay Foad via llvm-commits llvm-commits at lists.llvm.org
Mon Jan 6 06:31:00 PST 2025


================
@@ -171,10 +171,10 @@ define amdgpu_kernel void @f2(i32 %arg, i32 %arg1, i32 %arg2, i1 %arg3, i32 %arg
 ; GFX11-NEXT:    s_cbranch_vccz .LBB2_12
 ; GFX11-NEXT:  ; %bb.9:
 ; GFX11-NEXT:    s_xor_b32 s0, s8, -1
-; GFX11-NEXT:  .LBB2_10: ; %bb17
-; GFX11-NEXT:    ; =>This Inner Loop Header: Depth=1
 ; GFX11-NEXT:    s_delay_alu instid0(SALU_CYCLE_1)
 ; GFX11-NEXT:    s_and_b32 vcc_lo, exec_lo, s0
----------------
jayfoad wrote:

This is surprizing, since in general we should not move instructions into different basic blocks if they use `$exec`. But it looks safe in this case.

https://github.com/llvm/llvm-project/pull/121769


More information about the llvm-commits mailing list