[Mlir-commits] [mlir] [MLIR][CAPI][Python] Add support for querying memory effect instances (PR #213459)

Maksim Levental llvmlistbot at llvm.org
Sat Aug 1 12:15:40 PDT 2026


================
@@ -231,9 +272,12 @@ typedef struct {
   void (*construct)(void *userData);
   /// Optional destructor for user data. Set to nullptr to disable it.
   void (*destruct)(void *userData);
-  /// Get memory effects callback.
-  void (*getEffects)(MlirOperation op, MlirMemoryEffectInstancesList effects,
-                     void *userData);
+  /// Get memory effects callback. Implementations return effects by invoking
+  /// `callback` with an array of memory effect instances. The callback copies
+  /// the instances synchronously, so implementations retain ownership of them.
----------------
makslevental wrote:

```suggestion
  /// Get memory effects callback. Implementations return effects by invoking
  /// `callback` with an array of memory effect instances. The callback copies
  /// the instances so implementations retain ownership.
```

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


More information about the Mlir-commits mailing list