[Mlir-commits] [mlir] [mlir][python] automatically bundle builtin dialect with core sources (PR #72338)

Maksim Levental llvmlistbot at llvm.org
Tue Nov 14 19:56:02 PST 2023


makslevental wrote:

> Why can't they just depend on the built-in dialect? That's what iree does: 

They could but it's not really optional anymore (at least in so far as getting access to the type casters on builtin types). Although I believe nothing actually breaks (you just don't get type and attribute casting).

> I will point out that something else I tried was just patching loadDialectModule to immediately return true for the builtin dialect, and this works. IMHO that would be fine too.

This was intentionally done away with - the previous caching system had negative caches which effectively accomplished the same thing (a miss was "registered" as a `py::none()`) but then there needed to be checks and extra complexity in all of the lookups.

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


More information about the Mlir-commits mailing list