The documentation of MLIR pass infrastructure is impressive with a lot of helpful examples. But for beginners, it seems quite difficult to have a structured intro based on the current state of the documentations.
For reference let’s take a look at the llvm equivalent in this link: Writing an LLVM Pass — LLVM 18.0.0git documentation
The biggest difference is the end-to-end nature of the introduction. It identifies the different components of the pass, writes down explanation along with the code blocks. Additionally, at the end, the entire pass and registration is summarized in a single file which shows the entirety. Then they move on to compile it, show the shared library that contains the pass and then they execute the pass using opt. The completeness of the pass gives a nice introduction to what passes are for and how they can be leveraged.
Again, MLIR’s current documentation for pass infrastructure is great. There is no doubt about that. But it lacks the end-to-end nature and completeness of the LLVM equivalent. For beginners, it would be more helpful if the intro follows the same format as the LLVM tutorial.
Again, this is just a basic suggestion from the perspective of a beginner. I have discussed this before with some of my labmates who suggested me to raise the issue with the MLIR developers (Which is why I am writing this post ).
Thanks in advance.