[Mlir-commits] [mlir] [MLIR][Python] Make the TypeID allocator globally defined in `PassManager.add` (PR #162594)
llvmlistbot at llvm.org
llvmlistbot at llvm.org
Thu Oct 9 00:54:13 PDT 2025
================
@@ -151,6 +151,25 @@ class PyGlobals {
TracebackLoc &getTracebackLoc() { return tracebackLoc; }
+ class TypeIDAllocator {
+ public:
+ TypeIDAllocator() : allocator(mlirTypeIDAllocatorCreate()) {}
+ ~TypeIDAllocator() {
+ if (!allocator.ptr)
----------------
PragmaTwice wrote:
Ahh good catch! That was a silly mistake. 🤣
https://github.com/llvm/llvm-project/pull/162594
More information about the Mlir-commits
mailing list