[llvm] AMDGPU/GFX12: Insert waitcnts before stores with scope_sys (PR #82996)

Petar Avramovic via llvm-commits llvm-commits at lists.llvm.org
Mon Feb 26 06:11:02 PST 2024


================
@@ -0,0 +1,16 @@
+; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py UTC_ARGS: --version 4
+; RUN: llc -march=amdgcn -mcpu=gfx1200 -verify-machineinstrs < %s | FileCheck -check-prefix=GFX12 %s
+; RUN: llc -global-isel -march=amdgcn -mcpu=gfx1200 -verify-machineinstrs < %s | FileCheck -check-prefix=GFX12 %s
+
+define amdgpu_ps void @intrinsic_store_system_scope(i32 %val, <4 x i32> inreg %rsrc, i32 %vindex, i32 %voffset, i32 inreg %soffset) {
----------------
petar-avramovic wrote:

Maybe that is default scope for atomics?
This is about gfx12 scope instruction field, default is 0 (SCOPE_CU) and generic `store i32 42, ptr %ptr` gets selected with SCOPE_CU (not printed in asm string). There is currently no way to set different "gfx12 scope" on generic stores.

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


More information about the llvm-commits mailing list