[llvm] [DXIL] Add GroupMemoryBarrierWithGroupSync intrinsic (PR #111884)

Finn Plummer via llvm-commits llvm-commits at lists.llvm.org
Wed Oct 23 16:56:28 PDT 2024


================
@@ -293,6 +293,43 @@ class Attributes<Version ver = DXIL1_0, list<DXILAttribute> attrs> {
   list<DXILAttribute> op_attrs = attrs;
 }
 
+class DXILConstant<int value_> {
+  int value = value_;
+}
+
+defset list<DXILConstant> BarrierModes = {
----------------
inbelic wrote:

Is `DXILConstant` added out of necessity? Or can you do `defset list<int> BarrierModes ...`?
Was it added for better documentation/extensibility?

Otherwise, we could remove `index` from the `Arg` class and replace the the `is...` bits with a type enum to match the `ArgSelect` struct directly and I think it would allow for more concise code in `DXILEmitter.cpp`

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


More information about the llvm-commits mailing list