[clang] [AMDGPU][SPIRV] Use SPIR-V syncscopes for some AMDGCN BIs (PR #154867)
Yaxun Liu via cfe-commits
cfe-commits at lists.llvm.org
Thu Sep 11 09:27:37 PDT 2025
================
@@ -238,13 +248,19 @@ void CodeGenFunction::ProcessOrderScopeAMDGCN(Value *Order, Value *Scope,
SSID = llvm::SyncScope::System;
break;
case 1: // __MEMORY_SCOPE_DEVICE
- SSID = getLLVMContext().getOrInsertSyncScopeID("agent");
+ if (getTarget().getTriple().isSPIRV())
+ SSID = getLLVMContext().getOrInsertSyncScopeID("device");
----------------
yxsamliu wrote:
Will they be translate back to agent when we convert SPIRV to bitcode for amdgcn?
Do we have lit tests to cover that?
https://github.com/llvm/llvm-project/pull/154867
More information about the cfe-commits
mailing list