Welcome to the 50th issue of the MLIR Newsletter covering developments in MLIR, and related projects in the ecosystem. We welcome your contributions (contact: javed.absar@gmail.com). Click here to see previous editions.
Highlights
-
I saw lots of fixes and new feature commits landed on MLIR past two weeks (see section below). Question sessions on discord (see section below) suggest lots of folks using MLIR basic and advanced features. Thank you to all
experts/fast-responders
for patiently answering and helping out. -
[RFC] MLIR Pattern Matching for library and acceleration instruction rewriting. Vinicius Couto Espindola will present on 6th July at Open MLIR Meeting 7/6/2023. Summary: Modern ISA extensions and hardware accelerators created the demand for raising program idioms to acceleration instructions or optimized library calls. Although recent works have proposed different ways of raising code abstraction, they rely on specialized languages, compiler recompilation, or in-depth dialect knowledge. With this in mind, Source-based Matching and Rewriting (SMR), an MLIR based user-oriented tool for pattern matching and rewriting that relies on source code to simplify pattern and replacement specifications.
-
Andrzej Warzynski and Frank Gao will present at Open MLIR Meeting 6/22/2023: RFC on ArmSME Dialect - MLIR . Summary: an introduction into Arm’s Scalable Matrix Extension, including the MLIR codegen perspective, the work done so far to target SME from MLIR, and discuss what’s the best way to target “CPU accelerators” from MLIR.
-
MLIR C/C++ Front-end had their meeting MLIR C/C++ Frontend Working Group [Mon, Jun 26th] - MLIR / Announcements - LLVM Discussion Forums
MLIR Commits
-
LICM
op was added to transform dialect. D154327 [mlir][transform] Addtransform.apply_licm
op (llvm.org) -
Cleanup of Linalg padding transform D153853 [mlir][linalg][NFC] Cleanup padding transform (llvm.org)
-
Linalg softmax added partly D153422 [mlir][Linalg] Add a softmax op (llvm.org). AND tiling interface added - D153421 [mlir][Linalg] Implement the tiling interface for softmax (llvm.org)
-
Fix: When an operation is removed/replaced, the TrackingListener updates the internal transform state mapping between handles and payload IR. All handles must be updated, even the ones that are defined in a region that is beyond the most recent region that is isolated from above. D153767 [mlir][transform] Fix TrackingListener in regions that are isolated from above (llvm.org)
-
Introduced some constant folding features to the LLVM dialect to allow the elimination of logic generated by mem2reg with memset in the common case of memsets of constant values. D153135 [mlir][llvm] Introduce some constant folding.
-
Fix: Don’t wrap a warning into silenceable failure D153546 [mlir][transform] don’t wrap a warning into silenceable failure (llvm.org)
-
Introduced nvgpu transform extensions as a direct mapping step from a matmul on memrefs to distributed NVGPU vector abstractions. D153420 [mlir][Transform] Introduce nvgpu transform extensions (llvm.org)
-
Fixed a bug in the way we compute the vector type for vector
transfer writes when the value to store needs to be transposed. D153687 [mlir][Vector] Fix vectorization of generic ops with transposed outputs (llvm.org)
MLIR RFC Discussions
-
Alex Z. has some advice on dialect conversion, type conversion debug process
-
Questions on bare-pointer and llvm conversion Discord. Takeaways -
you can run with -debug-only=dialect-conversion to see what fails specifically
. From within codellvm::setCurrentDebugType("dialect-conversion"); llvm::DebugFlag = true
-
is there a reason we can’t just treat a memret<?xi8> as a pointer? memrefs need to be ranked now to be lowered with bare pointer convention. Maybe
memref<?xTy, strided<[1]>>
could be accepted in the future? Discussion. -
Looking for some good documentation/videos on materializations in TypeConverters ? Discussion
-
Folks pointed to [RFC] Memref of custom types - MLIR - LLVM Discussion Forums
Useful Links