[llvm] [AMDGPU] Lazily emit waitcnts on function entry (PR #73122)

Diana Picus via llvm-commits llvm-commits at lists.llvm.org
Wed Dec 6 04:18:18 PST 2023


================
@@ -171,15 +171,15 @@ define <2 x i16> @v_add_v2i16_neg_inline_imm_splat(<2 x i16> %a) {
 ;
 ; GFX9-LABEL: v_add_v2i16_neg_inline_imm_splat:
 ; GFX9:       ; %bb.0:
-; GFX9-NEXT:    s_waitcnt vmcnt(0) expcnt(0) lgkmcnt(0)
 ; GFX9-NEXT:    v_mov_b32_e32 v1, 0xffc0ffc0
----------------
rovka wrote:

Do we need to wait for expcnt before the v_mov? IIUC if there's an export or GDS instruction that reads the VGPRs in the caller, we're supposed to wait for EXPcnt before we write the VGPRs. 

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


More information about the llvm-commits mailing list