[Mlir-commits] [mlir] [mlir][gpu] Add address space modifier to Barrier (PR #110527)

Jakub Kuderski llvmlistbot at llvm.org
Mon Sep 30 11:08:02 PDT 2024


kuhar wrote:

> > That's why I think a memfence operation might be better, as it makes clear that barrier and memfence have different semantics.
> 
> This would be a useful primitive to have IMO. I'd expect these to not wait for all threads to reach the same program point, right? The usecase I have in mind is to have more fine-grained control on the number of outstanding memory accesses within a subgroup (IE 'please flush this fifo for me).

IE ideally, I'd like to have separate ops for waiting for all threads to reach the execution point (say, `gpu.synchronize`) and for specifying fences (say, `gpu.memfence`). Then I'd imagine for `gpu.barrier` to be defined as doing both (with the maximal memory fence scope).

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


More information about the Mlir-commits mailing list