A Guide on the Translation from MLIR Syntax to Mojo Syntax
The Mojo documentation states that all MLIR operations and types can be interfaced through Mojo.
However, is there a guide to translate the syntaxes of MLIR dialects into Mojo syntaxes so that engineers can take more direct control on how to use MLIR operations within Mojo?
6 Replies
This is interesting to me as well. Is there also some documentation (planned) about the MLIR designs w.r.t Mojo and how it fits into the whole MLIR pipeline.
@jmky, if you check the ray tracing notebook, you can see how MLIR can be used within your Mojo code:
https://docs.modular.com/mojo/notebooks/RayTracing.html
Modular Docs - Ray tracing in Mojo
Learn how to draw 3D graphics with ray-traced lighting using Mojo.
Another piece that would be nice to know is when and how will we be able to pull in a user custom MLIR dialect into the mojo complier (and the IR lowering stack). I would be interested in seeing how one could have Mojo act as a EDSL for a couple of the CIRCT LLVM MLIR dialects.
They recommend against using their undocumented dialects, and the roadmap is a bit vague about adding arbitrary dialects. I'm curious to know more about it.
The Mojo compiler dialects are likely to evolve quickly as they continue to develop the Mojo programming language. I want to play with dialects that use Mojo like an EDSL engine. Getting the compile time support during lowering w/o having the final steps of lowering being the LLVM IR.
Same. I'm curious what the timeline for that might be.